From fde9147075fc39ca5849e50b95b7879c4c8d2c93 Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Wed, 1 Jun 2016 10:23:30 +0200 Subject: Add mailAddress OID for future use --- crypto.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crypto.go b/crypto.go index f2ce1d1..917149d 100644 --- a/crypto.go +++ b/crypto.go @@ -8,6 +8,7 @@ import ( "crypto/rsa" "crypto/x509" "crypto/x509/pkix" + "encoding/asn1" "encoding/base64" "encoding/pem" "errors" @@ -95,6 +96,8 @@ func NewKey(size int) (crypto.PrivateKey, error) { } } +var oidMailAddress = asn1.ObjectIdentifier{1, 2, 840, 113549, 1, 9, 1} + func NewCSR(key crypto.PrivateKey, altnames, emails []string) (string, error) { tmpl := x509.CertificateRequest{ Subject: pkix.Name{CommonName: altnames[0]}, -- cgit v1.2.3