-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Installer does not untar files longer than 32 chars #6133
Comments
For replication and testing purposes it would be very nice if you could attach the package which is causing you troubles. Also please clarify if you are getting any errors. This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/6133. |
the query is about files of longer than 32 characters INSIDE the tar |
@brianteeman Thanks for info. I've deleted my misleading comment. |
Actually, this issue isn't about filenames containing more than 32 characters. According to Wikipedia, the original TAR format allows file paths (not file names!) up to 100 characters. If you look at the issue reporter's example, you'll notice that I haven't been able to find much info on the web regarding this, but it seems that the PAX implementation of tar uses an 'L' typeflag (76) that puts the filename in the contents block and the original contents of the file in the next block: I proposed a commit - but I referenced the wrong issue - apparently I was looking at the Joomla! tracker on one tab and copied the wrong ID :( |
Test archive here, I can't attach .tar.gz in the comments: https://onedrive.live.com/redir?resid=C010BBBF057E905F!21825&authkey=!ABY3mmJ9Kf4MOqc&ithint=file%2cgz |
hello friends, yes, i might have been wrong here and i apologize for not providing the tar gz which was originatelly within this post, but i was asked to remove it. my first tests seems like it was caused by the 32 char limit. the 100 char limit seems to be causing it, which is now pointed at @brianteeman I would really appreciate if you add a short note to your replies with a link (to joomla docs) on how can a beginner dev start with github joomla checkout of specific fixes.I.e. how to checkout a specific fix via a command line. thank you y'all, best regards, stan |
Steps to reproduce the issue
Create an installer package which has file names longer than 32 characters, tar it and gzip it into a normal joomla installation package (com_test.tar.gz)
the installer fails to recognize longer files than 32 characters as defined in:
\libraries\joomla\archive\tar.php
and truncates them and they may cause fatal errors if required by php
the long name seems to be stored only within this format:
././@LongLink000 147 0003740 Ladmin/plugins/vmpayment/amazon/library/OffAmazonPaymentsService/OffAmazonPaymentsService.config.inc.phpadmin/plugins/vmpayment/amazon/library/OffAmazonPaymentsService/OffAmazonPaymentsService.config.inc.0000666000000000000000000000113212471644025031355 0ustar
Expected result
full file names
Actual result
truncated filenames
System information (as much as possible)
PHP Version 5.5.21-1+deb.sury.org~precise+2
on ubuntu 12.04
production server
Additional comments
note - maybe joomla should not try to use php own code to unzip/untar these files, but rather check if functions like PharData exists:
http://stackoverflow.com/questions/9416508/php-untar-gz-without-exec
regards, stan
The text was updated successfully, but these errors were encountered: