diff options
author | Jack Lloyd <[email protected]> | 2018-03-19 23:27:49 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2018-03-19 23:27:49 -0400 |
commit | a260a4f36ccaa1620455c976da55810bff77d5d7 (patch) | |
tree | 8f76a064a08f4f859661b9e3f7a7f8854c3f75c1 /src/lib | |
parent | 06b2ba179f548e830e673a0b2d749e6207f70ca9 (diff) |
Support multiple DNS names through the command line interface
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/x509/x509self.cpp | 3 | ||||
-rw-r--r-- | src/lib/x509/x509self.h | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/lib/x509/x509self.cpp b/src/lib/x509/x509self.cpp index 418fd85a4..78bbe8615 100644 --- a/src/lib/x509/x509self.cpp +++ b/src/lib/x509/x509self.cpp @@ -33,6 +33,9 @@ void load_info(const X509_Cert_Options& opts, X509_DN& subject_dn, subject_alt = AlternativeName(opts.email, opts.uri, opts.dns, opts.ip); subject_alt.add_othername(OIDS::lookup("PKIX.XMPPAddr"), opts.xmpp, UTF8_STRING); + + for(auto dns : opts.more_dns) + subject_alt.add_attribute("DNS", dns); } } diff --git a/src/lib/x509/x509self.h b/src/lib/x509/x509self.h index 0cc12e98e..7d061acbb 100644 --- a/src/lib/x509/x509self.h +++ b/src/lib/x509/x509self.h @@ -79,6 +79,8 @@ class BOTAN_PUBLIC_API(2,0) X509_Cert_Options final */ std::string dns; + std::vector<std::string> more_dns; + /** * the subject XMPP */ |