[jira] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212607#comment-13212607 ] Sebb commented on COMPRESS-177: --- The tar file appears to be corrupt. The file contains the following: 0060:00 00 00 00 30 30 30 30 37 35 35 00 30 30 30 31755.0001 0070:30 34 30 00 80 00 00 00 ff ff ff ff 30 30 30 30040.€... 0080:30 30 30 36 35 34 33 00 31 31 36 35 37 34 37 340006543.11657474 0090:32 36 35 00 30 32 31 32 30 36 00 20 30 00 00 265.021206. 0.. Note the strange entry starting at offset 74 - this should be the groupId. There seem to be quite a few other entries with the same problem. The header entries are supposed to use ASCII for portability. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- This
[jira] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212622#comment-13212622 ] Christian Schlichtherle commented on COMPRESS-177: -- I thought so. However, in this case the code should throw an IOException from TarInputStream.getArchiveEntry(), not an IllegalArgumentException. This comes completely unexpected and is misleading because it's not an illegal argument to this method, but an invalid file content. I an IOException were thrown as documented by the Javadoc, then the TrueZIP Kernel would have identified it as a false positive archive file, which it is. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA
[jira] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212628#comment-13212628 ] Gili commented on COMPRESS-177: --- Sebb, How do WinRar and Ubuntu Archiver handle this TAR file? They don't report any errors and extract it just fine... TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212631#comment-13212631 ] Sebb commented on COMPRESS-177: --- Looks like the archive might be using the Joerg Schilling STAR format [1] for numeric fields: Star implements a vendor specific (and thus non-POSIX) extension to put bigger numbers into the numeric fields. This is done by using a base 256 coding. The top bit of the first character in the appropriate 8 character or 12 charac- ter field is set to flag non octal coding. The value certainly makes sense in that context. As to the exception that is thrown, IAE makes sense in the context of the TarUtils.parseOctal() method. Maybe that should be converted to IOE by one of the higher level methods. [1] http://cdrecord.berlios.de/private/man/star/star.4.html TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can
[jira] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212633#comment-13212633 ] Christian Schlichtherle commented on COMPRESS-177: -- Yes, please wrap it in an IOE because in the context of TarInputStream.getArchiveEntry() it's not an illegal argument, but an invalid file content, which is a side effect. In comparison, java.util.zip uses ZipException, which extends IOException, to flag invalid file contents. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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:
[jira] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212637#comment-13212637 ] Sebb commented on COMPRESS-177: --- Please raise a separate JIRA issue for changing the exception type. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212648#comment-13212648 ] Christian Schlichtherle commented on COMPRESS-177: -- What's wrong with this issue? The subject says it all, I think. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13212657#comment-13212657 ] Gili commented on COMPRESS-177: --- I filed a second issue: https://issues.apache.org/jira/browse/COMPRESS-178 TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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] [Commented] (COMPRESS-177) TarArchiveInputStream throws IllegalArgumentException on valid TAR file
[ https://issues.apache.org/jira/browse/COMPRESS-177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13211969#comment-13211969 ] Christian Schlichtherle commented on COMPRESS-177: -- Well, not quite correct. If the archive file is indeed intact, then I expect NO exception upon the call to TarArchiveInputStream.getNextEntry(). In case it would be corrupt, then I expect an IOException, just as documented in the Javadoc. Other than calling the TarArchiveInputStream, TrueZIP is not involved in this bug. TarArchiveInputStream throws IllegalArgumentException on valid TAR file --- Key: COMPRESS-177 URL: https://issues.apache.org/jira/browse/COMPRESS-177 Project: Commons Compress Issue Type: Bug Components: Archivers Affects Versions: 1.3 Reporter: Gili Issue originally reported at http://java.net/jira/browse/TRUEZIP-219 # Download http://sourceforge.net/projects/boost/files/boost/1.48.0/boost_1_48_0.tar.gz?use_mirror=autoselect # I invoke Files.newDirectoryStream() on a TPath pointing to the resulting .tar.gz file # The following exception is thrown: {code} java.lang.IllegalArgumentException: Invalid byte -1 at offset 7 in 'some bytes' len=8 at org.apache.commons.compress.archivers.tar.TarUtils.parseOctal(TarUtils.java:86) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.parseTarHeader(TarArchiveEntry.java:790) at org.apache.commons.compress.archivers.tar.TarArchiveEntry.init(TarArchiveEntry.java:308) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:198) at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextEntry(TarArchiveInputStream.java:380) at de.schlichtherle.truezip.fs.archive.tar.TarInputShop.init(TarInputShop.java:91) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newTarInputShop(TarDriver.java:159) at de.schlichtherle.truezip.fs.archive.tar.TarGZipDriver.newTarInputShop(TarGZipDriver.java:82) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:151) at de.schlichtherle.truezip.fs.archive.tar.TarDriver.newInputShop(TarDriver.java:47) at de.schlichtherle.truezip.fs.archive.FsDefaultArchiveController.mount(FsDefaultArchiveController.java:170) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController$ResetFileSystem.autoMount(FsFileSystemArchiveController.java:98) at de.schlichtherle.truezip.fs.archive.FsFileSystemArchiveController.autoMount(FsFileSystemArchiveController.java:47) at de.schlichtherle.truezip.fs.archive.FsArchiveController.autoMount(FsArchiveController.java:129) at de.schlichtherle.truezip.fs.archive.FsArchiveController.getEntry(FsArchiveController.java:160) at de.schlichtherle.truezip.fs.archive.FsContextController.getEntry(FsContextController.java:117) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsDecoratingController.getEntry(FsDecoratingController.java:76) at de.schlichtherle.truezip.fs.FsConcurrentController.getEntry(FsConcurrentController.java:164) at de.schlichtherle.truezip.fs.FsSyncController.getEntry(FsSyncController.java:108) at de.schlichtherle.truezip.fs.FsFederatingController.getEntry(FsFederatingController.java:156) at de.schlichtherle.truezip.nio.file.TFileSystem.newDirectoryStream(TFileSystem.java:348) at de.schlichtherle.truezip.nio.file.TPath.newDirectoryStream(TPath.java:963) at de.schlichtherle.truezip.nio.file.TFileSystemProvider.newDirectoryStream(TFileSystemProvider.java:344) at java.nio.file.Files.newDirectoryStream(Files.java:400) at com.googlecode.boostmavenproject.GetSourcesMojo.convertToJar(GetSourcesMojo.java:248) at com.googlecode.boostmavenproject.GetSourcesMojo.download(GetSourcesMojo.java:221) at com.googlecode.boostmavenproject.GetSourcesMojo.execute(GetSourcesMojo.java:111) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) ... 20 more {code} Christian Schlichtherle (the TrueZip author) is expecting the Commons Compress to throw IOException instead of IllegalArgumentException. I am expecting no exception to be thrown because as far as I can tell the TAR file is valid (opens up in WinRar and Ubuntu's built-in Archiver). -- 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