php 加密zip文件,php 压缩文件并加密压缩包(压缩包添加密码)
php 把文件打成压缩包 ,可以去搜下 pclzip搜很好多地方没有找到对压缩包进行加密操作的。如果服务器是linux 那么见代码:$filename="test.csv";file_put_contents($filePath,"1\t 2\t 3\n1\t 2\t 3\n1\t 2\t 3\n");//$test = "/bin/bash /usr/local/inonesoft/bin/at
php 把文件打成压缩包 ,可以去搜下 pclzip
搜很好多地方没有找到对压缩包进行加密操作的。
如果服务器是linux 那么见代码:
$filename="test.csv";
file_put_contents($filePath,"1\t 2\t 3\n1\t 2\t 3\n1\t 2\t 3\n");
//$test = "/bin/bash /usr/local/inonesoft/bin/atest.sh 123 /usr/local/inonesoft/nginx/htdocs/watch/test.zip /usr/local/inonesoft/nginx/htdocs/watch/test.csv";
$test = "ln /usr/local/inonesoft/nginx/htdocs/watch/test.csv /test.csv; /usr/local/inonesoft/bin/atest.sh 123 - /test.csv > /usr/local/inonesoft/nginx/htdocs/watch/test.zip";
exec($test,$array);
atest.sh:
#zip -rP a123 text.zip test.txt
zip -rP $1 $2 $3
--------------------------------------------------------------
ln -s /usr/local/inonesoft/nginx/htdocs/card_file/DS00001388.csv /DS00001388.csv; /usr/local/inonesoft/bin/zip_encryption.sh lecake2013 - /DS00001388.csv > /usr/local/inonesoft/nginx/htdocs/card_file/DS00001388-2013-08-19_14:29:23.zip; rm -rf /DS00001388.csv;
魔乐社区(Modelers.cn) 是一个中立、公益的人工智能社区,提供人工智能工具、模型、数据的托管、展示与应用协同服务,为人工智能开发及爱好者搭建开放的学习交流平台。社区通过理事会方式运作,由全产业链共同建设、共同运营、共同享有,推动国产AI生态繁荣发展。
更多推荐


所有评论(0)