Certificate-related commands (personal retention)

Source: Internet
Author: User
Tags generate csr openssl rsa openssl x509 pkcs12

OpenSSL genrsa-des3-out ca1.key 2048 Generate user key

OpenSSL rsa-in ca1.key-out ca1.key remove Key's password

OpenSSL req-new-key ca1.key-out ca1.csr-config openssl.cnf generate CSR file

OpenSSL ca-in user1.csr-out user1.crt-cert ca0.crt-keyfile ca0.key-config openssl.cnf signing CSR file

OpenSSL req-new-x509-keyout ca1_0.key-out ca1_0.crt-config openssl.cnf self-generated root certificate


OpenSSL Ca-revoke Ca1_1.crt

OpenSSL ca-gencrl-out ca1_1crl



OpenSSL pkcs12-in root.pfx-nodes-out Root.pem # Generate clear Text all content

OpenSSL rsa-in root.pem-out root.key # Fetch key file

OpenSSL x509-in root.pem-out ROOT.CRT # Fetch Certificate


OpenSSL pkcs12-export-inkey root.key-in root.crt-out root.pfx #合成pfx格式



The. CER/.CRT is used for storing certificates, which are stored in 2 binary form and do not contain private keys.

The difference between a. Pem and a crt/cer is that it is expressed in ASCII.

PFX/P12 is used to store personal certificates/private keys, he usually contains protection password, 2 binary mode

P10 is a certificate request

P7R is the CA's response to a certificate request and is used only for import

P7B the certificate chain (certificate chain) in a tree form, and also supports a single certificate with no private key



Basicconstraints=critical,ca:true, pathlen:20



Mount-t Cifs-o Username=administrator//192.168.0.11/share/mnt


This article from "Ding classmate 1990" blog, reproduced please contact the author!

Certificate-related commands (personal retention)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.