PKCS #X (Public Key Cryptography Standards) are a group of public-key cryptography standards devised and published by RSA Security Inc, starting in the early 1990s.
They defined the file format of key material (keystore)
The file extensions are:
PKCS are binary format. They may be wrapped into a PEM format being transformed as human text with a base64 encoding (transformation .
Therefore, you have a PEM with a content that is encoded as base64 PKCS format.
PKCS#7 does not include the private key, it is commonly used for certificate dissemination (e.g. as the response to a PKCS#10 certificate request, as a means to distribute S/MIME certs used to encrypt messages, or to validate signed messages etc).
It is important to remember that it is only for certificates which are by definition public items.
You cannot convert from PKCS#7 to PKCS#12 without additional data (the private key part) because PKCS#7 doesn't have all of the data.
From old PKCS12 base64 pem (from dkim for instance) to new Pkcs8 format
openssl pkcs8 \
-topk8 \ # Output PKCS8 file
-inform PEM \
-outform PEM \
-nocrypt \
-in pkcs12.pem \
-out pkcs8.pem
Cryptography - PKCS12 (PFX files)
Pkcs#10 is a file format for a What is a Certificate Signing Request (CSR)?.
rfc2986 - PKCS #10: Certification Request Syntax Specification Version 1.7
It's a format based on the pem format
see wiki/PKCS