No::Worries::DN - Distinguished Names handling without worries
use No::Worries::DN qw(dn_parse dn_string); $dn = dn_parse("/C=US/O=Acme Corporation/CN=John Doe"); $string = dn_string($dn, No::Worries::DN::FORMAT_JAVA);
This module eases Distinguished Names (DNs) handling by providing convenient functions to parse and convert DNs from and to different formats. All the functions die() on error.
This module provides the following functions (none of them being exported by default):
parse a string containing DN information and return an array reference
convert the given parsed DN (an array reference) into a string of the given format, this is somehow the opposite of dn_parse()
Here are the supported formats:
this is the format defined by RFC 2253, for instance: CN=John Doe,O=Acme Corporation,C=US
CN=John Doe,O=Acme Corporation,C=US
this is a variant of RFC 2253, with extra spaces, for instance: CN=John Doe, O=Acme Corporation, C=US
CN=John Doe, O=Acme Corporation, C=US
this is the default format used by OpenSSL, for instance: /C=US/O=Acme Corporation/CN=John Doe
/C=US/O=Acme Corporation/CN=John Doe
No::Worries.
Lionel Cons http://cern.ch/lionel.cons
Copyright (C) CERN 2012-2016
To install No::Worries, copy and paste the appropriate command in to your terminal.
cpanm
cpanm No::Worries
CPAN shell
perl -MCPAN -e shell install No::Worries
For more information on module installation, please visit the detailed CPAN module installation guide.