OPENSSL-FORMAT-OPTIONS(1ossl)
π OPENSSL-FORMAT-OPTIONS(1ossl) π
okay bestie, so this is the openssl-format-options page from the OpenSSL 3.5.9 fam β it's literally the group chat where all the other openssl subcommands come to agree on what shape their input and output should be in. it's short, it's sweet, it's giving "reference card that saves your whole afternoon" energy. let's get into it π
β¨ SYNOPSIS β¨
openssl command [ options ... ] [ parameters ... ]
that's it. that's the whole vibe. every openssl command can take options and parameters, and some of those options are the format ones we're about to spill about π«Ά
πΈ DESCRIPTION πΈ
so, several OpenSSL commands can take input or generate output in a whole variety of formats. like, a lot of them. and they're not gonna make you memorize which one is which, because β plot twist β they got smarter.
since OpenSSL 3.0, keys, single certificates, and CRLs can be read from files in any of the DER, PEM or P12 formats. ngl, that means specifying their input format is no more needed β the openssl commands will automatically try all the possible formats for you. main character energy, honestly. π
but bestie, read this part twice: if the DER or PEM input format is specified, it will be enforced. no autodetect, no take-backs, no vibes. you said DER, you get DER, and if the file isn't DER it's gonna be a whole thing π
and in order to access a key via an engine, the input format ENGINE may be used. alternatively β and this is the sneaky cute way β the key identifier in the <uri> argument of the respective key option may be preceded by "org.openssl.engine:". see "Engine Options" in openssl(1) for an example usage of the latter. iykyk β¨
π OPTIONS π
π¦ Format Options π¦
these are the options that specify the format. refer to the individual man page to see which options are accepted β like, don't assume your fave command takes all of them, check its own page first, ok?? π
-inform format,-outform formatβ the format of the input or output streams. the classic duet, the bruno mars and lady gaga of format flags π«-keyform formatβ format of a private key input source. private key gets its own dedicated flag, as it should π-CRLform formatβ format of a CRL input source. yes the capital letters are real, that's just how it's written, do not @ me π
β Format Option Arguments β
the possible format arguments are described below. both uppercase and lowercase are accepted β so DER, der, whatever, live your truth π
the list of acceptable format arguments, and the default, is described in each command documentation. (yes, every command has its own opinion on defaults. go read them. it's fine. it's fine.)
DERβ a binary format, encoded or parsed according to Distinguished Encoding Rules (DER) of the ASN.1 data language. crunchy bytes, no line breaks, she's compact and she knows it π₯ENGINEβ used to specify that the cryptographic material is in an OpenSSL engine. an engine must be configured or specified using the-engineoption. a password or PIN may be supplied to the engine using the-passinoption. very "secret handshake" of her π§P12β a DER-encoded file containing a PKCS#12 object. it might be necessary to provide a decryption password to retrieve the private key or certificate. so likeβ¦ bring your password. don't be the person who forgets the password πPEMβ a text format defined in IETF RFC 1421 and IETF RFC 7468. briefly, this is a block of base-64 encoding (defined in IETF RFC 4648), with specific lines used to mark the start and end:
Text before the BEGIN line is ignored.
-----BEGIN object-type-----
OT43gQKBgQC/2OHZoko6iRlNOAQ/tMVFNq7fL81GivoQ9F1U0Qr+DH3ZfaH8eIkX
xT0ToMPJUzWAn8pZv0snA0um6SIgvkCuxO84OkANCVbttzXImIsL7pFzfcwV/ERK
UM6j0ZuSMFOCr/lGPAoOQU0fskidGEHi1/kW+suSr28TqsyYZpwBDQ==
-----END object-type-----
Text after the END line is also ignored
the object-type must match the type of object that is expected. for example, a "BEGIN X509 CERTIFICATE" will not match if the command is trying to read a private key. the types supported include:
ANY PRIVATE KEY
CERTIFICATE
CERTIFICATE REQUEST
CMS
DH PARAMETERS
DSA PARAMETERS
DSA PUBLIC KEY
EC PARAMETERS
EC PRIVATE KEY
ECDSA PUBLIC KEY
ENCRYPTED PRIVATE KEY
PARAMETERS
PKCS #7 SIGNED DATA
PKCS7
PRIVATE KEY
PUBLIC KEY
RSA PRIVATE KEY
SSL SESSION PARAMETERS
TRUSTED CERTIFICATE
X509 CRL
X9.42 DH PARAMETERS
and the following legacy object-type's are also supported for compatibility with earlier releases β she's nostalgic, she remembers her exes π°οΈ:
DSA PRIVATE KEY
NEW CERTIFICATE REQUEST
RSA PUBLIC KEY
X509 CERTIFICATE
SMIMEβ an S/MIME object as described in IETF RFC 8551. earlier versions were known as CMS and are compatible β same girl, different era π
β οΈ heads up: note that the parsing is simple and might fail to parse some legal data. so if it chokes on something that's technically valid, that's not you, that's just how she is. don't take it personally π
π COPYRIGHT π
copyright 2000-2026 The OpenSSL Project Authors. All Rights Reserved.
licensed under the Apache License 2.0 (the "License"). you may not use this file except in compliance with the License. you can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
okay that's the whole page, you ate that, go format something πβ¨
signed, sealed, delivered by the OpenSSL fam β version 3.5.9, dated 2026-09-29, page OPENSSL-FORMAT-OPTIONS(1ossl) β mwah π
π¦ where this page comes from
- alpine 3.23: openssl-doc 3.5.9-r0 Β· Apache-2.0
- alpine 3.24: openssl-doc 3.5.9-r0 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms