[ 
https://issues.apache.org/jira/browse/COMPRESS-335?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15134884#comment-15134884
 ] 

Stefan Bodewig commented on COMPRESS-335:
-----------------------------------------

We could probably use {{parseOctal}} for reading the checksum, I'll give it a 
try.


> TAR checksum fails when checksum is right aligned
> -------------------------------------------------
>
>                 Key: COMPRESS-335
>                 URL: https://issues.apache.org/jira/browse/COMPRESS-335
>             Project: Commons Compress
>          Issue Type: Bug
>          Components: Archivers
>    Affects Versions: 1.10
>            Reporter: Jeremy Gustie
>
> The linked TAR has a checksum with zero padding on the left instead of the 
> expected {{NULL-SPACE}} terminator on the right. As a result the last two 
> digits of the stored checksum are lost and the otherwise valid checksum is 
> treated as invalid.
> Given that the code already checks for digits being in range before adding 
> them to the stored sum, is it necessary to only look at the first 6 octal 
> digits instead of the whole field?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to