Skip to content
On this page

End of Life Ruby 3.1 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →

class · Ruby 3.1

OpenSSL::X509::Name

< Object include Comparable include OpenSSL::Marshal 12 instance methods 4 class methods

An X.509 name represents a hostname, email address or other entity associated with a public key.

You can create a Name by parsing a distinguished name String or by supplying the distinguished name as an Array.

Example
name = OpenSSL::X509::Name.parse_rfc2253 'DC=example,CN=nobody'

name = OpenSSL::X509::Name.new [['CN', 'nobody'], ['DC', 'example']]

Class methods 4

Instance methods 12

Constants

A flag for to_s.

Breaks the name returned into multiple lines if longer than 80 characters.

The default object type for name entries.

A flag for to_s.

Returns a multiline format.

The default object type template for name entries.

A flag for to_s.

Returns a more readable format than RFC2253.

A flag for to_s.

Returns an RFC2253 format name.