[
https://issues.apache.org/jira/browse/CODEC-288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17090416#comment-17090416
]
Alex Herbert commented on CODEC-288:
------------------------------------
You will have to use 1.14 which is the current release. If you do see a problem
then we will need a repeatable test to show the failure.
An intermittent failure indicates to me that perhaps it is data dependent or
you have thread concurrency issues.
Things to watch out for:
Ensure you are not using the same instance of Base64 with concurrent threads.
Decoding using the static method will ensure you have a thread-safe instance
for decoding.
Ensure the input uses valid base 64 characters. If there are characters not in
the base 64 alphabet then the Base64 decoder will ignore them. It does not
throw an exception. The result is a shorter than expected byte array output.
> during Base64 decode for 24 byte length string ,the function returns byte
> array which is less than 18 bytes
> -----------------------------------------------------------------------------------------------------------
>
> Key: CODEC-288
> URL: https://issues.apache.org/jira/browse/CODEC-288
> Project: Commons Codec
> Issue Type: Bug
> Affects Versions: 1.5
> Environment: effected all the stacks
> Reporter: sagarika
> Priority: Major
>
> string of byte length 24 AQAAAAFxB7VyAgAAAAEPEMdg
> returned byte array length :6 ideally it should be of length 18.
>
> public byte[] decode(String pArray) {
> return this.decode(StringUtils.getBytesUtf8(pArray));
> }
--
This message was sent by Atlassian Jira
(v8.3.4#803005)