Can someone tell me how can I extract a password protected .7z file in Ubuntu server?
(I know the password, I just need a program to do so and an example of how to use said program...)
Can someone tell me how can I extract a password protected .7z file in Ubuntu server?
(I know the password, I just need a program to do so and an example of how to use said program...)
Install p7zip-full on the server first and then run this to extract a z7 archive called test.7z, encrypted with the password password:
7z x test.7z -ppassword
As JanC adds below, you can omit the whole -ppassword flag and it will just ask you for the password on extraction:
oli@bert:~/Desktop$ 7z x test.7z
7-Zip 9.04 beta Copyright (c) 1999-2009 Igor Pavlov 2009-05-30
p7zip Version 9.04 (locale=en_GB.UTF-8,Utf16=on,HugeFiles=on,8 CPUs)
Processing archive: test.7z
Enter password (will not be echoed) : <<I typed the password here>>
Extracting botch2
Everything is Ok
Folders: 1
Files: 0
Size: 0
Compressed: 118
there is a rarcrack to do this task. It can handle .rar, .zip and .7z files. Check out this article:
http://mediakey.dk/~cc/howto-crack-rar-7z-and-zip-files-in-linux/
Hope this will help
rarcrack is also pretty awful with its false positives. I tested it on my test.7z from above and it kept exiting with wrong passwords.
– Oli
Nov 16 '10 at 09:05
file-roller,lzmaandp7zip-fullpackages installed. Install some of them and try again. – Oli Nov 16 '10 at 15:57-p='my passphrase'is not the right argument format. Fileroller didn't want to compress it, hanging itself after gathering a list of files, so had to use the command line. Can't figure out what the pwd is. It's notmy passphrase,'my passphrase',='my,='my passphrase'or='my passphrase. Great. Starting compressing again, this time with argument-pmy\ passphrase, that seemed to work (tested it this time around)... Edit: Also-mhe=onmight be worth mentioning. – Luc Aug 02 '13 at 07:34-oflag! Assuming I want my output files to all be extracted to outputdir, for instance, I'd do:7z x -ooutputdir myfile.7z. Ahhhh, much better! – Gabriel Staples Jul 28 '19 at 05:41