You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jspwiki.apache.org by Dirk Frederickx <di...@gmail.com> on 2007/12/06 19:54:20 UTC
question on username
Ref. xss vulnerability
Which characters are allowed in the jspwiki username ? <wiki:Username/>
>From what I can see, there are only checks on isBlank, all other
characters seem to be allowed.
Also the single quote, which is dangerous in the common-header.jsp,
where the username is inserted as javascript string.
dirk
Re: question on username
Posted by Andrew Jaquith <an...@mac.com>.
Yeah, the backslash is something we need to preserve. My general
paranoid urge says that it's best to remove quotes and other special
characters upon input to eliminate XSS. But an equally valid strategy
is simple to make sure the *output* is properly escaped using
TextUtil. That is probably more compatible.
Lemme check out the code and think about this a bit more...
On Dec 8, 2007, at 7:44, Janne Jalkanen <Ja...@ecyrd.com>
wrote:
>
> I think it's okay to remove all the quotes, but I think some people
> are using some weird windows names, which include a backslash. And
> some systems also offer brackets.
>
> So I don't really know what the allowed set of characters should
> be. Maybe some people are using quotes as well.
>
> /Janne
>
> On 6 Dec 2007, at 20:54, Dirk Frederickx wrote:
>
>> Ref. xss vulnerability
>>
>> Which characters are allowed in the jspwiki username ?
>> <wiki:Username/>
>>
>>> From what I can see, there are only checks on isBlank, all other
>> characters seem to be allowed.
>> Also the single quote, which is dangerous in the common-header.jsp,
>> where the username is inserted as javascript string.
>>
>>
>>
>> dirk
>
Re: question on username
Posted by Janne Jalkanen <Ja...@ecyrd.com>.
I think it's okay to remove all the quotes, but I think some people
are using some weird windows names, which include a backslash. And
some systems also offer brackets.
So I don't really know what the allowed set of characters should be.
Maybe some people are using quotes as well.
/Janne
On 6 Dec 2007, at 20:54, Dirk Frederickx wrote:
> Ref. xss vulnerability
>
> Which characters are allowed in the jspwiki username ?
> <wiki:Username/>
>
>> From what I can see, there are only checks on isBlank, all other
> characters seem to be allowed.
> Also the single quote, which is dangerous in the common-header.jsp,
> where the username is inserted as javascript string.
>
>
>
> dirk