Encodes this DH
to its PEM encoding. Note that any existing per-session public/private keys will not get encoded, just the Diffie-Hellman parameters will be encoded.
Encodes this DH
to its PEM encoding. Note that any existing per-session public/private keys will not get encoded, just the Diffie-Hellman parameters will be encoded.
Encodes this DSA
to its PEM encoding.
cipher is an OpenSSL::Cipher
.
password is a string containing your password.
DSA.to_pem -> aString DSA.to_pem(cipher, 'mypassword') -> aString
Encodes this DSA
to its PEM encoding.
cipher is an OpenSSL::Cipher
.
password is a string containing your password.
DSA.to_pem -> aString DSA.to_pem(cipher, 'mypassword') -> aString
Outputs the EC
key in PEM encoding. If cipher and pass_phrase are given they will be used to encrypt the key. cipher must be an OpenSSL::Cipher
instance. Note that encryption will only be effective for a private key, public keys will always be encoded in plain text.
Outputs this keypair in PEM encoding. If cipher and pass_phrase are given they will be used to encrypt the key. cipher must be an OpenSSL::Cipher
instance.
Outputs this keypair in PEM encoding. If cipher and pass_phrase are given they will be used to encrypt the key. cipher must be an OpenSSL::Cipher
instance.
This method is called automatically when a new SSLSocket
is created. However, it is not thread-safe and must be called before creating SSLSocket
objects in a multi-threaded program.
Reads length bytes from the SSL
connection. If a pre-allocated buffer is provided the data will be written into it.
A description of the current connection state. This is for diagnostic purposes only.
Sets the server hostname used for SNI. This needs to be set before SSLSocket#connect
.
See TCPServer#listen
for details.
Returns a String
representation of the Distinguished Name
. format is one of:
If format is omitted, the largely broken and traditional OpenSSL
format is used.