[英]How to apply Zip Compression in GnuPG Class of PHP
I would like to compress message using GnuPG PHP extension我想使用GnuPG PHP 扩展压缩消息
putenv("GNUPGHOME=/var/www/.gnupg");
//$gpg = new gnupg();
$res = gnupg_init();
$rtv = gnupg_import($res, $pubkey);
gnupg_addencryptkey($res, $rtv['fingerprint']);
$pgp_str = gnupg_encrypt($res, $str);
I would like to pass compress-algo parameter but haven't found way to pass, can someone suggest?我想传递compress-algo参数但没有找到传递的方法,有人可以建议吗?
Thanks for help!感谢帮助!
Reference to GPG Configuration , create file gpg.conf inside.gnupg folder.参考GPG 配置,在 .gnupg 文件夹中创建文件gpg.conf 。
Then put options in gpg.conf, check this for example然后将选项放在 gpg.conf 中,例如检查这个
check result using gpg --list-packets -vv --show-session-key yourfilename.gpg
使用
gpg --list-packets -vv --show-session-key yourfilename.gpg
检查结果
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.