You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Alex <al...@partners.netfocus.es> on 2005/12/12 16:17:28 UTC

[COMMONS-CODEC]

Hello, i think i have found a bug in class Base64, the method
(isBase64(byte octet)). I say because i have passed a X509Certificate in
DEREncoded (so none Base64 byte[]). This method returns an
IndexOutOfBoundsException: -128. I think that the problem is in line
(base64Alphabet[octect] == -1) because it is the line where it crash and
also because it is the only place where an array is referenced. Im so
sure that the byte octet is the -128 value, so index out of bounds are
throwed. I have modified that class, i suppose that i would have to
upload some place, but i don't know where. Can anybody told me if im
correct and where i could send the class?

Re: [COMMONS-CODEC]

Posted by Stephen Colebourne <sc...@btopenworld.com>.
Are you able to supply a small test case to demonstrate the bug? That is 
the most useful item. If so, can you create a bugzilla bug call, thanks.

Stephen


Alex wrote:
> Hello, i think i have found a bug in class Base64, the method
> (isBase64(byte octet)). I say because i have passed a X509Certificate in
> DEREncoded (so none Base64 byte[]). This method returns an
> IndexOutOfBoundsException: -128. I think that the problem is in line
> (base64Alphabet[octect] == -1) because it is the line where it crash and
> also because it is the only place where an array is referenced. Im so
> sure that the byte octet is the -128 value, so index out of bounds are
> throwed. I have modified that class, i suppose that i would have to
> upload some place, but i don't know where. Can anybody told me if im
> correct and where i could send the class?
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org