用法一 生成自签名数字证书
openssl genpkey -algorithm RSA -out private.key
openssl req -new -key private.key -out certificate.csr
openssl x509 -req -days 365 -in certificate.csr -signkey private.key -out certificate.crt
用法二 生成消息摘要
echo -n "Hello, world!" | openssl dgst -sha256
用法三 加密和解密文件
openssl enc -aes-256-cbc -salt -in plaintext.txt -out encrypted.txt
openssl enc -aes-256-cbc -d -in encrypted.txt -out decrypted.txt
用法四 创建自签名根证书和证书链
openssl genpkey -algorithm RSA -out root.key
openssl req -new -key root.key -out root.csr
openssl x509 -req -days 365 -in root.csr -signkey root.key -out root.crt
cat intermediate.crt >> chain.crt
用法五 生成随机数
https://github.com/pdf2htmlEX/pdf2htmlEX.git