登录 用户中心() [退出] 后台管理 注册
   
您的位置: 首页 >> 程序员学前班[不再更新,只读] >> 主题: [shell][linux] zip 命令中怎样使怎样用密码[口令]     [回主站]     [分站链接]
标题
[shell][linux] zip 命令中怎样使怎样用密码[口令]
clq
浏览(0) + 2007-05-02 09:03:12 发表 编辑

关键字:

[shell][linux] zip 命令中怎样使怎样用密码[口令]

-e 参数是不能在 shell 命令行中使用的. 听说是用 -p 参数,结果是用大写的 “-P”,并且格式还很特别 :( 浪费我不少时间。

--------------------------------------------------
http://www.experts-exchange.com/Software/System_Utilities/Compression_Tools/Q_22529478.html?testCookie=true
--------------------------------------------------
Question

Make encrypted zip from perl script
I am trying to find a way to create a password-protected encrypted ZIP archive from an automated script. The script (preferably Perl, but any command line solution I can call FROM a perl script would also be acceptable) must take file(s) which will probably be generated on-the-fly by the perl script (I can take care of that part) and put them in the zip. The archive must be encrypted with strong encryption, AES 256 is my goal.

The encrypted zip should be compatible with windows XP compressed folders or WinZip so non-technical users can open it on windows.

The script that creates this zip is going to run on RedHat Linux, with the newest version of perl.

The unix command `zip` has a -e option that does exaclty what I need, except the password has to be typed in at the terminal prompt, I need to automate this from a script.

Any ideas?
--------------------------------------------------
Accepted Solution [被接受的答案]

Does your version of zip support the -P flag? eg:

system "zip -P mypasswd foo.zip file1 file2";


总数:0 页次:1/0 首页 尾页  
总数:0 页次:1/0 首页 尾页  


所在合集/目录



发表评论:
文本/html模式切换 插入图片 文本/html模式切换


附件:



NEWBT官方QQ群1: 276678893
可求档连环画,漫画;询问文本处理大师等软件使用技巧;求档softhub软件下载及使用技巧.
但不可"开车",严禁国家敏感话题,不可求档涉及版权的文档软件.
验证问题说明申请入群原因即可.

Copyright © 2005-2020 clq, All Rights Reserved
版权所有
桂ICP备15002303号-1