On 02/03/16 14:43, Josh Grosse wrote:
On Wed, Feb 03, 2016 at 09:42:55AM +0300, Andre S wrote:
p7zip-15.09p3
Core dumped when used "l" command to list contents of password protected
archive.
Core dumped when used "t" command to test integrity of password protected
archive.
$ 7z a -p test.7z test.txt
Success.
$ 7z l test.7z
Enter password (will not be echoed):Abort trap (core dumped)
$ 7z t test.7z
Enter password (will not be echoed):Abort trap (core dumped)
Ouch. Thanks for the report. And for the fix, which broadens
the applicable secondary pledges to include tty.
In testing on amd64, I do get different results. The list command
does not prompt for a password.
However the pledge() for list is also the pledge for stdout extractions, so
your recommendation to expand that pledge is fine. If you would be kind
enough to post your architecture, that may be helpful in trying to recreate
the same results which occurred for you.
My architecture is amd64.
Sorry. I sent incomplete example.
I forgot to specify option -mhe=on (enables archive header encryption)
Correct example:
$ 7z a -p -mhe=on test.7z test.txt
Success.
$ 7z l test.7z
Enter password (will not be echoed):Abort trap (core dumped)
$ 7z t test.7z
Enter password (will not be echoed):Abort trap (core dumped)
I was unable to apply your patch directly due to white space
alignment. I applied your recommendations and have posted the
equivalent patch below, using mutt, which is less likely to chew
on unified diffs than some other Email applications.
Thanks. Thunderbird wrap long lines.