[jira] [Updated] (COMPRESS-16) unable to extract a TAR file that contains an entry which is 10 GB in size
[ https://issues.apache.org/jira/browse/COMPRESS-16?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] John Kodis updated COMPRESS-16: --- Attachment: 0004-Prefer-octal-over-binary-size-representation.patch This one-character patch corrects an error in patch 0002. The expression representing the largest value that an eleven-digit octal number can contain must be forced to a long integer value, as otherwise it overflows the limits of an int and evaluates to zero. unable to extract a TAR file that contains an entry which is 10 GB in size -- Key: COMPRESS-16 URL: https://issues.apache.org/jira/browse/COMPRESS-16 Project: Commons Compress Issue Type: Bug Components: Archivers Environment: I am using win xp sp3, but this should be platform independent. Reporter: Sam Smith Attachments: 0001-Accept-GNU-tar-files-with-entries-over-8GB-in-size.patch, 0002-Allow-creating-tar-archives-with-files-over-8GB.patch, 0004-Prefer-octal-over-binary-size-representation.patch, ant-8GB-tar.patch, patch-for-compress.txt I made a TAR file which contains a file entry where the file is 10 GB in size. When I attempt to extract the file using TarInputStream, it fails with the following stack trace: java.io.IOException: unexpected EOF with 24064 bytes unread at org.apache.commons.compress.archivers.tar.TarInputStream.read(TarInputStream.java:348) at org.apache.commons.compress.archivers.tar.TarInputStream.copyEntryContents(TarInputStream.java:388) So, TarInputStream does not seem to support large ( 8 GB?) files. Here is something else to note: I created that TAR file using TarOutputStream , which did not complain when asked to write a 10 GB file into the TAR file, so I assume that TarOutputStream has no file size limits? That, or does it silently create corrupted TAR files (which would be the worst situation of all...)? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (COMPRESS-163) Unable to extract a file larger than 8GB from a Posix-format tar archive
[ https://issues.apache.org/jira/browse/COMPRESS-163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] John Kodis updated COMPRESS-163: Attachment: 0003-Allow-reading-large-files-from-Posix-tar-archives.patch An attempt to read a posix-format tar archive containing a file in excess of 8^11 bytes in size will fail with a Size out of range illegal argument exception. We correct this by dropping the test for a too-large value in the TarArchiveEntry.setSize method, and making the corresponding modifications to the testMaxFileSize() junit test. Finally, in the getNextTarEntry method, we set the entrySize instance variable an additional time to pick up any larger size that may have been obtained as a result of processing any Posix Pax headers. Unable to extract a file larger than 8GB from a Posix-format tar archive Key: COMPRESS-163 URL: https://issues.apache.org/jira/browse/COMPRESS-163 Project: Commons Compress Issue Type: Bug Components: Compressors Affects Versions: 1.3 Environment: The tar archive used for testing was created by GNU tar, but the problem will occur with any Posix-formatted tar file containing files over 8GB in size. Reporter: John Kodis Priority: Minor Fix For: 1.3 Attachments: 0003-Allow-reading-large-files-from-Posix-tar-archives.patch Original Estimate: 24h Remaining Estimate: 24h An attempt to read a posix-format tar archive containing a file in excess of 8^11 bytes in size will fail with a Size out of range illegal argument exception. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (COMPRESS-16) unable to extract a TAR file that contains an entry which is 10 GB in size
[ https://issues.apache.org/jira/browse/COMPRESS-16?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] John Kodis updated COMPRESS-16: --- Attachment: 0002-Allow-creating-tar-archives-with-files-over-8GB.patch 0001-Accept-GNU-tar-files-with-entries-over-8GB-in-size.patch [PATCH 1/2] Accept GNU tar files with entries over 8GB in size. The tar file format originally stored the size of a file in a 12 byte null-terminated field, which allowed a maximum file size of 8^11, or 8,589,934,592 bytes. To accomodate larger files, later versions of GNU tar will use this same 12 byte field to hold a binary representation of the file size, denoting this as a binary value by setting the most-significant bit of the first byte of the field. [PATCH 2/2] Allow creating tar archives with files over 8GB. Use the same binary encoding scheme above to allow the creation of tar archives containing files over 8GB in size. unable to extract a TAR file that contains an entry which is 10 GB in size -- Key: COMPRESS-16 URL: https://issues.apache.org/jira/browse/COMPRESS-16 Project: Commons Compress Issue Type: Bug Components: Archivers Environment: I am using win xp sp3, but this should be platform independent. Reporter: Sam Smith Attachments: 0001-Accept-GNU-tar-files-with-entries-over-8GB-in-size.patch, 0002-Allow-creating-tar-archives-with-files-over-8GB.patch, ant-8GB-tar.patch, patch-for-compress.txt I made a TAR file which contains a file entry where the file is 10 GB in size. When I attempt to extract the file using TarInputStream, it fails with the following stack trace: java.io.IOException: unexpected EOF with 24064 bytes unread at org.apache.commons.compress.archivers.tar.TarInputStream.read(TarInputStream.java:348) at org.apache.commons.compress.archivers.tar.TarInputStream.copyEntryContents(TarInputStream.java:388) So, TarInputStream does not seem to support large ( 8 GB?) files. Here is something else to note: I created that TAR file using TarOutputStream , which did not complain when asked to write a 10 GB file into the TAR file, so I assume that TarOutputStream has no file size limits? That, or does it silently create corrupted TAR files (which would be the worst situation of all...)? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (COMPRESS-16) unable to extract a TAR file that contains an entry which is 10 GB in size
[ https://issues.apache.org/jira/browse/COMPRESS-16?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] John Kodis updated COMPRESS-16: --- Comment: was deleted (was: I've attached two patch files against commons-compress-1.3-src which add support for reading (patch 0001) and writing (patch 0002) tar archives which contain files larger than the 8GB limit imposed by the use of a 12 character octal size field in the tar header. I've followed the approach taken by the GNU tar utility: for files larger than the 8GB limit, continue to use the same size field, but switch to a binary size representation, noting this change by detecting (on read) or setting (on write) the most significant bit of the first byte of the size field. ) unable to extract a TAR file that contains an entry which is 10 GB in size -- Key: COMPRESS-16 URL: https://issues.apache.org/jira/browse/COMPRESS-16 Project: Commons Compress Issue Type: Bug Components: Archivers Environment: I am using win xp sp3, but this should be platform independent. Reporter: Sam Smith Attachments: 0001-Accept-GNU-tar-files-with-entries-over-8GB-in-size.patch, 0002-Allow-creating-tar-archives-with-files-over-8GB.patch, ant-8GB-tar.patch, patch-for-compress.txt I made a TAR file which contains a file entry where the file is 10 GB in size. When I attempt to extract the file using TarInputStream, it fails with the following stack trace: java.io.IOException: unexpected EOF with 24064 bytes unread at org.apache.commons.compress.archivers.tar.TarInputStream.read(TarInputStream.java:348) at org.apache.commons.compress.archivers.tar.TarInputStream.copyEntryContents(TarInputStream.java:388) So, TarInputStream does not seem to support large ( 8 GB?) files. Here is something else to note: I created that TAR file using TarOutputStream , which did not complain when asked to write a 10 GB file into the TAR file, so I assume that TarOutputStream has no file size limits? That, or does it silently create corrupted TAR files (which would be the worst situation of all...)? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (COMPRESS-16) unable to extract a TAR file that contains an entry which is 10 GB in size
[ https://issues.apache.org/jira/browse/COMPRESS-16?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] John Kodis updated COMPRESS-16: --- Comment: was deleted (was: [PATCH 1/2] Accept GNU tar files with entries over 8GB in size. The tar file format originally stored the size of a file in a 12 byte null-terminated field, which allowed a maximum file size of 8^11, or 8,589,934,592 bytes. To accomodate larger files, later versions of GNU tar will use this same 12 byte field to hold a binary representation of the file size, denoting this as a binary value by setting the most-significant bit of the first byte of the field. [PATCH 2/2] Allow creating tar archives with files over 8GB. Use the same binary encoding scheme above to allow the creation of tar archives containing files over 8GB in size.) unable to extract a TAR file that contains an entry which is 10 GB in size -- Key: COMPRESS-16 URL: https://issues.apache.org/jira/browse/COMPRESS-16 Project: Commons Compress Issue Type: Bug Components: Archivers Environment: I am using win xp sp3, but this should be platform independent. Reporter: Sam Smith Attachments: 0001-Accept-GNU-tar-files-with-entries-over-8GB-in-size.patch, 0002-Allow-creating-tar-archives-with-files-over-8GB.patch, ant-8GB-tar.patch, patch-for-compress.txt I made a TAR file which contains a file entry where the file is 10 GB in size. When I attempt to extract the file using TarInputStream, it fails with the following stack trace: java.io.IOException: unexpected EOF with 24064 bytes unread at org.apache.commons.compress.archivers.tar.TarInputStream.read(TarInputStream.java:348) at org.apache.commons.compress.archivers.tar.TarInputStream.copyEntryContents(TarInputStream.java:388) So, TarInputStream does not seem to support large ( 8 GB?) files. Here is something else to note: I created that TAR file using TarOutputStream , which did not complain when asked to write a 10 GB file into the TAR file, so I assume that TarOutputStream has no file size limits? That, or does it silently create corrupted TAR files (which would be the worst situation of all...)? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira