GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
OpenXPKI::Crypt::DN(3) User Contributed Perl Documentation OpenXPKI::Crypt::DN(3)

OpenXPKI::Crypt::DN

Helper class to read, build, convert DNs between array/hash and string representations.

The internal representation of the DN, must be set at the time of constructionand can not be updated later.

The expected format is the DN structure as returned from Convert::ASN1 which is a list holding the DN components starting with the least significant element (usual the country). Each element of the list must be an array itself holding the RDNs as a hash:

  [
    [
      {
        'value' => { 'utf8String' => 'DE' },
        'type' => '2.5.4.6'
      }
    ],
    [
       {
         'value' => { 'utf8String' => 'OpenXPKI' },
         'type' => '2.5.4.10'
       },
    ],
    [
      {
          'type' => '2.5.4.3',
          'value' => { 'utf8String' => 'Foobar' }
      },
      {
          'type' => '0.9.2342.19200300.100.1.1',
          'value' => { 'utf8String' => 'foobar' }
      }
    ]
  ];

Returns the subject as string according to RFC2253 (starting with CN)

Returns the subject as string in OpenSSL format (starting with /C=XX)

Returns a hashref with the RDN types as keys, known OIDs are translated to their textual representation (see OpenXPKI::Role::SubjectOID). The values are lists holding the textual representation of the RNS components.

To provide backwards compatibility with OpenXPKI::DN all keys are in uppercase letters and the value elements are listed with the "most significant" item first.

All builder methods are static methods to the class and return a fresh instance of this class or undef in case the input can not be parsed.

Expecting the DN as string in RFC2253 or OpenSSL format.

Uses OpenXPKI::DN internally which has very limited support for special chars and will likely choke on values using plus signs or commas.

2025-07-15 perl v5.40.2

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.