Returns the curve name (sn).
See the OpenSSL
documentation for EC_GROUP_get_curve_name()
Negate the value of a numeric node. This is a special case where you have a negative sign on one line and then a number on the next line. In normal Ruby
, this will always be a method call. The parser gem, however, marks this as a numeric literal. We have to massage the tree here to get it into the correct form.
Visit a numeric node and account for the optional sign.
Apply Ruby
string escaping rules
Deprecated in version 3.0. Consider using PKey::PKey#sign_raw
and PKey::PKey#verify_raw
instead.
Enables use of shared session key material in accordance with RFC 5705.
Returns true
if key is the corresponding private key to the Subject Public Key Information, false
otherwise.
Serializes the private key to DER-encoded PKCS #8 format. If called without arguments, unencrypted PKCS #8 PrivateKeyInfo format is used. If called with a cipher name and a password, PKCS #8 EncryptedPrivateKeyInfo format with PBES2 encryption scheme is used.
Serializes the private key to PEM-encoded PKCS #8 format. See private_to_der
for more details.
An unencrypted PEM-encoded key will look like:
-----BEGIN PRIVATE KEY----- [...] -----END PRIVATE KEY-----
An encrypted PEM-encoded key will look like:
-----BEGIN ENCRYPTED PRIVATE KEY----- [...] -----END ENCRYPTED PRIVATE KEY-----
See the OpenSSL
documentation for EVP_PKEY_get_raw_private_key()
Visit an EnsureNode node.
Visit an individual part of a string-like node.
“foo” ^^^^^
‘foo` ^^^^^
Visit a node that represents a write value. This is used to handle the special case of an implicit array that is generated without brackets.
Pins the gem name
to the given source
. Adding a gem with the same name from a different source
will raise an exception.