ZIP a file using a password

I am trying to zip a file like below, password : abc
zip -P abc test.zip test.txt
it gives me following error
zip error: Invalid command arguments (encryption not supported)
Any idea !
Nazrul10Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

YiHateuCommented:
Maybe you have a trial version where that feature is disabled.
If you have a full version or are sure this should be working try to reinstall or update to be sure all files are up to date.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
ShadowBlade72Commented:
Try using the -e option instead of the -P option. It should prompt you for the password.
0
Dave BaldwinFixer of ProblemsCommented:
Take a look at this page.  http://www.experts-exchange.com/OS/Unix/Q_23885228.html  Because zip encrytion is weak and has the password in the clear in the file (?), it may not be supported on your system.
0
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

sam_gibsonCommented:
Use the -e option, not -P.  For example:

$ zip -e test.zip file1.txt file2.txt file3.txt
Enter password: <you type the password here>
Verify password: <you type the password here, again>
     adding: ....
     adding: ....
$
0
Nazrul10Author Commented:
Maybe you have a trial version where that feature is disabled. If you have a full version or are sure this should be working try to reinstall or update to be sure all files are up to date.

You are absolutely right. e or P option doesnot matter here. Main issue is my  zip command doesn't have encryption enable. I think my zip command is too old.
Do you know how to check version of zip command ?
   

0
AmolCommented:
P7zip is the port to unix for the program 7-zip, try downloading and running it. It  does support setting zip passwords.

http://p7zip.sourceforge.net/



0
Nazrul10Author Commented:
e or P option doesnot matter here. Main issue is my zip command doesn't have encryption enable. I think my zip command is too old.
Does anybody knows how to check zip version !

0
YiHateuCommented:
Sorry I do not. I'd suggest one of the other zip tools of your preference
0
Nazrul10Author Commented:
ok, Thanks
0
AmolCommented:
zip -v
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Unix OS

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.