From 317b64b20bb44c37f6aef0008e65b18ab806cd51 Mon Sep 17 00:00:00 2001 From: Rasmus Dahlberg Date: Mon, 30 Nov 2020 17:39:26 +0100 Subject: added and moved test data --- server/testdata/x509/.rand | 0 server/testdata/x509/README.md | 35 -------------------- server/testdata/x509/ca.conf | 59 ---------------------------------- server/testdata/x509/chain.pem | 23 ------------- server/testdata/x509/end-entity.key | 3 -- server/testdata/x509/end-entity.pem | 10 ------ server/testdata/x509/end-entity2.key | 3 -- server/testdata/x509/end-entity2.pem | 10 ------ server/testdata/x509/intermediate.key | 3 -- server/testdata/x509/intermediate.pem | 13 -------- server/testdata/x509/intermediate2.key | 3 -- server/testdata/x509/intermediate2.pem | 13 -------- server/testdata/x509/root.key | 3 -- server/testdata/x509/root.pem | 13 -------- server/testdata/x509/root2.key | 3 -- server/testdata/x509/root2.pem | 13 -------- 16 files changed, 207 deletions(-) delete mode 100644 server/testdata/x509/.rand delete mode 100644 server/testdata/x509/README.md delete mode 100644 server/testdata/x509/ca.conf delete mode 100644 server/testdata/x509/chain.pem delete mode 100644 server/testdata/x509/end-entity.key delete mode 100644 server/testdata/x509/end-entity.pem delete mode 100644 server/testdata/x509/end-entity2.key delete mode 100644 server/testdata/x509/end-entity2.pem delete mode 100644 server/testdata/x509/intermediate.key delete mode 100644 server/testdata/x509/intermediate.pem delete mode 100644 server/testdata/x509/intermediate2.key delete mode 100644 server/testdata/x509/intermediate2.pem delete mode 100644 server/testdata/x509/root.key delete mode 100644 server/testdata/x509/root.pem delete mode 100644 server/testdata/x509/root2.key delete mode 100644 server/testdata/x509/root2.pem (limited to 'server/testdata/x509') diff --git a/server/testdata/x509/.rand b/server/testdata/x509/.rand deleted file mode 100644 index e69de29..0000000 diff --git a/server/testdata/x509/README.md b/server/testdata/x509/README.md deleted file mode 100644 index c9f03de..0000000 --- a/server/testdata/x509/README.md +++ /dev/null @@ -1,35 +0,0 @@ -# Create new certificate chains -## Initial setup -``` -$ touch index -$ echo 1000 > serial -``` - -## Root certificate -``` -$ openssl genpkey -algorithm ed25519 -out root.key -$ openssl req -new -x509 -config ca.conf -extensions v3_ca -days 4096 -key root.key -out root.pem -$ openssl x509 -in root.pem -text -noout -``` - -## Intermediate certificate -``` -$ openssl genpkey -algorithm ed25519 -out intermediate.key -$ openssl req -new -config ca.conf -extensions v3_intermediate_ca -key intermediate.key -out intermediate.csr -$ openssl ca -config ca.conf -extensions v3_intermediate_ca -days 4096 -in intermediate.csr -notext -out intermediate.pem -$ openssl x509 -in intermediate.pem -text -noout -``` - -## End-entity certificate -``` -$ openssl genpkey -algorithm ed25519 -out end-entity.key -$ openssl req -new -key end-entity.key -out end-entity.csr -$ openssl x509 -req -days 4096 -CA intermediate.pem -CAkey intermediate.key -CAcreateserial -in end-entity.csr -out end-entity.pem -$ openssl x509 -in end-entity.pem -text -noout -``` - -## Make chain -``` -$ cat end-entity.pem > chain.pem -$ cat intermediate.pem >> chain.pem -``` diff --git a/server/testdata/x509/ca.conf b/server/testdata/x509/ca.conf deleted file mode 100644 index 7889331..0000000 --- a/server/testdata/x509/ca.conf +++ /dev/null @@ -1,59 +0,0 @@ -[ca] -default_ca = ca_settings - -[ ca_settings ] -dir = . -certs = $dir -crl_dir = $dir -new_certs_dir = $dir -database = $dir/index -serial = $dir/serial - -private_key = $dir/root.key -certificate = $dir/root.pem - -policy = ca_policy - -[ ca_policy ] -countryName = optional -stateOrProvinceName = optional -localityName = optional -organizationName = optional -organizationalUnitName = optional -commonName = supplied -emailAddress = optional - -# Options for the `req` tool, `man req` -[ req ] -distinguished_name = req_distinguished_name - -# Extensions for a typical CA, see `man x509v3_config` -[ v3_ca ] -subjectKeyIdentifier = hash -authorityKeyIdentifier = keyid:always,issuer -basicConstraints = critical, CA:true -keyUsage = critical, digitalSignature, keyCertSign - -# Extensions for a typical intermediate CA, see `man x509v3_config` -[ v3_intermediate_ca ] -subjectKeyIdentifier = hash -authorityKeyIdentifier = keyid:always,issuer -basicConstraints = critical, CA:true, pathlen:0 -keyUsage = critical, digitalSignature, keyCertSign - -[ req_distinguished_name ] -countryName = Country Name (2 letter code) -stateOrProvinceName = State or Province Name -localityName = Locality Name -0.organizationName = Organization Name -organizationalUnitName = Organizational Unit Name -commonName = Common Name -emailAddress = Email Address - -countryName_default = NA -stateOrProvinceName_default = NA -localityName_default = NA -0.organizationName_default = NA -organizationalUnitName_default = NA -emailAddress_default = NA -commonName_default = stfe testdata diff --git a/server/testdata/x509/chain.pem b/server/testdata/x509/chain.pem deleted file mode 100644 index 0ac66a0..0000000 --- a/server/testdata/x509/chain.pem +++ /dev/null @@ -1,23 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIBbDCCAR4CFDfeuu6XURfn7AE4WShuwZBHEaLIMAUGAytlcDBsMQswCQYDVQQG -EwJOQTELMAkGA1UECAwCTkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkG -A1UECwwCTkExFjAUBgNVBAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEW -Ak5BMB4XDTIwMTEwMzE4MzI0MFoXDTMyMDEyMTE4MzI0MFowRTELMAkGA1UEBhMC -QVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMGEludGVybmV0IFdpZGdp -dHMgUHR5IEx0ZDAqMAUGAytlcAMhAJvk390ZvwULplBri03Od4LLz+Sf/OUHu+20 -wik+T9y5MAUGAytlcANBANekliXq4ttoClBJDZoktIQxyHHNcWyXFrj1HlOaT5bC -I3GIqqZ60Ua3jKytnEsKsD2rLMPItDwmG6wYSecy2ws= ------END CERTIFICATE----- ------BEGIN CERTIFICATE----- -MIIB7jCCAaCgAwIBAgICEAAwBQYDK2VwMGwxCzAJBgNVBAYTAk5BMQswCQYDVQQI -DAJOQTELMAkGA1UEBwwCTkExCzAJBgNVBAoMAk5BMQswCQYDVQQLDAJOQTEWMBQG -A1UEAwwNc3RmZSB0ZXN0ZGF0YTERMA8GCSqGSIb3DQEJARYCTkEwHhcNMjAxMTAz -MTgzMjE4WhcNMzIwMTIxMTgzMjE4WjBsMQswCQYDVQQGEwJOQTELMAkGA1UECAwC -TkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkGA1UECwwCTkExFjAUBgNV -BAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEWAk5BMCowBQYDK2VwAyEA -F1yPPpjHKDAKN73pBFGXzAvIjdkLLimydu2y1HLMOiKjZjBkMB0GA1UdDgQWBBQ6 -P7JQ7yXtrTh7YkVU0I78P9A+nDAfBgNVHSMEGDAWgBQBvsxROtKU6zmr/SxcfTMD -sAQcMTASBgNVHRMBAf8ECDAGAQH/AgEAMA4GA1UdDwEB/wQEAwIChDAFBgMrZXAD -QQBm1GMV0ADPnXRWnelCW9tcyTh0p9hKefuSy/MNx7/XLHKnM5fX+yHqD84QOxES -Vc510vi4dM8I+e/vcoBsmMQP ------END CERTIFICATE----- diff --git a/server/testdata/x509/end-entity.key b/server/testdata/x509/end-entity.key deleted file mode 100644 index da83f09..0000000 --- a/server/testdata/x509/end-entity.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIDme3WaCwW2/FX095yh02yIIsn0D3vbvN5NsJzcdUwq1 ------END PRIVATE KEY----- diff --git a/server/testdata/x509/end-entity.pem b/server/testdata/x509/end-entity.pem deleted file mode 100644 index 52b99f6..0000000 --- a/server/testdata/x509/end-entity.pem +++ /dev/null @@ -1,10 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIBbDCCAR4CFDfeuu6XURfn7AE4WShuwZBHEaLIMAUGAytlcDBsMQswCQYDVQQG -EwJOQTELMAkGA1UECAwCTkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkG -A1UECwwCTkExFjAUBgNVBAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEW -Ak5BMB4XDTIwMTEwMzE4MzI0MFoXDTMyMDEyMTE4MzI0MFowRTELMAkGA1UEBhMC -QVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMGEludGVybmV0IFdpZGdp -dHMgUHR5IEx0ZDAqMAUGAytlcAMhAJvk390ZvwULplBri03Od4LLz+Sf/OUHu+20 -wik+T9y5MAUGAytlcANBANekliXq4ttoClBJDZoktIQxyHHNcWyXFrj1HlOaT5bC -I3GIqqZ60Ua3jKytnEsKsD2rLMPItDwmG6wYSecy2ws= ------END CERTIFICATE----- diff --git a/server/testdata/x509/end-entity2.key b/server/testdata/x509/end-entity2.key deleted file mode 100644 index 4758b40..0000000 --- a/server/testdata/x509/end-entity2.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIH65lXoCT4N9q4mPmDcsmAqIqG9CrqrB4KV2nqBC9JlZ ------END PRIVATE KEY----- diff --git a/server/testdata/x509/end-entity2.pem b/server/testdata/x509/end-entity2.pem deleted file mode 100644 index f1d41fc..0000000 --- a/server/testdata/x509/end-entity2.pem +++ /dev/null @@ -1,10 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIBbDCCAR4CFC4G5ep2NoHAmvFkmFID7y4U/BryMAUGAytlcDBsMQswCQYDVQQG -EwJOQTELMAkGA1UECAwCTkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkG -A1UECwwCTkExFjAUBgNVBAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEW -Ak5BMB4XDTIwMTEyNTIxNTkwM1oXDTMyMDIxMjIxNTkwM1owRTELMAkGA1UEBhMC -QVUxEzARBgNVBAgMClNvbWUtU3RhdGUxITAfBgNVBAoMGEludGVybmV0IFdpZGdp -dHMgUHR5IEx0ZDAqMAUGAytlcAMhAKwG0O/Ql+L6O8aq8BZ+KOdJmVLdcnOmMENR -H7O84kVFMAUGAytlcANBAJIUg3wQ5AvhOaITYB/9rT5cm5dcklOdEIwAqvmSOEXf -vgCpSAz29bnKYJmjwp6mkXx3f31h39G41zr2wRjKnw8= ------END CERTIFICATE----- diff --git a/server/testdata/x509/intermediate.key b/server/testdata/x509/intermediate.key deleted file mode 100644 index 26721e4..0000000 --- a/server/testdata/x509/intermediate.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIEiZEO5PnjkbN4A+5r9LVTIZeVdPq/on5AzwnetZjszE ------END PRIVATE KEY----- diff --git a/server/testdata/x509/intermediate.pem b/server/testdata/x509/intermediate.pem deleted file mode 100644 index 0f893b8..0000000 --- a/server/testdata/x509/intermediate.pem +++ /dev/null @@ -1,13 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIB7jCCAaCgAwIBAgICEAAwBQYDK2VwMGwxCzAJBgNVBAYTAk5BMQswCQYDVQQI -DAJOQTELMAkGA1UEBwwCTkExCzAJBgNVBAoMAk5BMQswCQYDVQQLDAJOQTEWMBQG -A1UEAwwNc3RmZSB0ZXN0ZGF0YTERMA8GCSqGSIb3DQEJARYCTkEwHhcNMjAxMTAz -MTgzMjE4WhcNMzIwMTIxMTgzMjE4WjBsMQswCQYDVQQGEwJOQTELMAkGA1UECAwC -TkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkGA1UECwwCTkExFjAUBgNV -BAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEWAk5BMCowBQYDK2VwAyEA -F1yPPpjHKDAKN73pBFGXzAvIjdkLLimydu2y1HLMOiKjZjBkMB0GA1UdDgQWBBQ6 -P7JQ7yXtrTh7YkVU0I78P9A+nDAfBgNVHSMEGDAWgBQBvsxROtKU6zmr/SxcfTMD -sAQcMTASBgNVHRMBAf8ECDAGAQH/AgEAMA4GA1UdDwEB/wQEAwIChDAFBgMrZXAD -QQBm1GMV0ADPnXRWnelCW9tcyTh0p9hKefuSy/MNx7/XLHKnM5fX+yHqD84QOxES -Vc510vi4dM8I+e/vcoBsmMQP ------END CERTIFICATE----- diff --git a/server/testdata/x509/intermediate2.key b/server/testdata/x509/intermediate2.key deleted file mode 100644 index 487627e..0000000 --- a/server/testdata/x509/intermediate2.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIOo+qcT2GoWoAp0079ecz/ZyrCZ78Zqznv1xEoN96vT7 ------END PRIVATE KEY----- diff --git a/server/testdata/x509/intermediate2.pem b/server/testdata/x509/intermediate2.pem deleted file mode 100644 index 854785c..0000000 --- a/server/testdata/x509/intermediate2.pem +++ /dev/null @@ -1,13 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIB7jCCAaCgAwIBAgICEAAwBQYDK2VwMGwxCzAJBgNVBAYTAk5BMQswCQYDVQQI -DAJOQTELMAkGA1UEBwwCTkExCzAJBgNVBAoMAk5BMQswCQYDVQQLDAJOQTEWMBQG -A1UEAwwNc3RmZSB0ZXN0ZGF0YTERMA8GCSqGSIb3DQEJARYCTkEwHhcNMjAxMTI1 -MjE1NzU1WhcNMzIwMjEyMjE1NzU1WjBsMQswCQYDVQQGEwJOQTELMAkGA1UECAwC -TkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTELMAkGA1UECwwCTkExFjAUBgNV -BAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0BCQEWAk5BMCowBQYDK2VwAyEA -DD23ESkuIKaCkU6xCncIwvD12w4ETBgAiHAubr/wDwujZjBkMB0GA1UdDgQWBBSy -uua2yvX+VM9JBc19GQisnLnH5zAfBgNVHSMEGDAWgBQeeImH1qUrWk+pq3YOkwI8 -bWdEuTASBgNVHRMBAf8ECDAGAQH/AgEAMA4GA1UdDwEB/wQEAwIChDAFBgMrZXAD -QQCoQvs8gPHZOH6VIuUGCcXVzf8D5+F6GZSoxMF880yYbdbUBVwwbJLFazwEn0uC -PwMBM9nZj3g1ZSH8uP2sEo0F ------END CERTIFICATE----- diff --git a/server/testdata/x509/root.key b/server/testdata/x509/root.key deleted file mode 100644 index c2dd558..0000000 --- a/server/testdata/x509/root.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIPJGy4Tf9SwDv44lLCmVyEjsbUmwfTg+j/Xoyaunf1rx ------END PRIVATE KEY----- diff --git a/server/testdata/x509/root.pem b/server/testdata/x509/root.pem deleted file mode 100644 index 1fc802b..0000000 --- a/server/testdata/x509/root.pem +++ /dev/null @@ -1,13 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIB/TCCAa+gAwIBAgIUDYJzaC5VSkKwiLVAxO5MyphAkN8wBQYDK2VwMGwxCzAJ -BgNVBAYTAk5BMQswCQYDVQQIDAJOQTELMAkGA1UEBwwCTkExCzAJBgNVBAoMAk5B -MQswCQYDVQQLDAJOQTEWMBQGA1UEAwwNc3RmZSB0ZXN0ZGF0YTERMA8GCSqGSIb3 -DQEJARYCTkEwHhcNMjAxMTAzMTgzMTMxWhcNMzIwMTIxMTgzMTMxWjBsMQswCQYD -VQQGEwJOQTELMAkGA1UECAwCTkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTEL -MAkGA1UECwwCTkExFjAUBgNVBAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0B -CQEWAk5BMCowBQYDK2VwAyEAJ1IiXCB4YHwdWka9MM0bc7LvKAtksmtIo8IhkuEB -uzGjYzBhMB0GA1UdDgQWBBQBvsxROtKU6zmr/SxcfTMDsAQcMTAfBgNVHSMEGDAW -gBQBvsxROtKU6zmr/SxcfTMDsAQcMTAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB -/wQEAwIChDAFBgMrZXADQQCXh6kDnE5giTjcLET2S94qTwnHVAj57DJcR/rf9Jy8 -NMGbtzTL0/V0B8DHuJFA/islbZJbN7rSvqddEKL8N2gI ------END CERTIFICATE----- diff --git a/server/testdata/x509/root2.key b/server/testdata/x509/root2.key deleted file mode 100644 index df8b7af..0000000 --- a/server/testdata/x509/root2.key +++ /dev/null @@ -1,3 +0,0 @@ ------BEGIN PRIVATE KEY----- -MC4CAQAwBQYDK2VwBCIEIKQd3B84w9pB6zJLGljuDyGKfz9uPP6QBeLiFcw0EME4 ------END PRIVATE KEY----- diff --git a/server/testdata/x509/root2.pem b/server/testdata/x509/root2.pem deleted file mode 100644 index d0b131c..0000000 --- a/server/testdata/x509/root2.pem +++ /dev/null @@ -1,13 +0,0 @@ ------BEGIN CERTIFICATE----- -MIIB/TCCAa+gAwIBAgIUCFGFq5zAkH03LQ2fpAamPhGd8FgwBQYDK2VwMGwxCzAJ -BgNVBAYTAk5BMQswCQYDVQQIDAJOQTELMAkGA1UEBwwCTkExCzAJBgNVBAoMAk5B -MQswCQYDVQQLDAJOQTEWMBQGA1UEAwwNc3RmZSB0ZXN0ZGF0YTERMA8GCSqGSIb3 -DQEJARYCTkEwHhcNMjAxMTE3MTgxNTQyWhcNMzIwMjA0MTgxNTQyWjBsMQswCQYD -VQQGEwJOQTELMAkGA1UECAwCTkExCzAJBgNVBAcMAk5BMQswCQYDVQQKDAJOQTEL -MAkGA1UECwwCTkExFjAUBgNVBAMMDXN0ZmUgdGVzdGRhdGExETAPBgkqhkiG9w0B -CQEWAk5BMCowBQYDK2VwAyEAFOG1Lof1UiV2mYsM17EopyVCR87qRrNW9YHP0biu -pOyjYzBhMB0GA1UdDgQWBBQeeImH1qUrWk+pq3YOkwI8bWdEuTAfBgNVHSMEGDAW -gBQeeImH1qUrWk+pq3YOkwI8bWdEuTAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB -/wQEAwIChDAFBgMrZXADQQDP4IQePN5Krr7jn+RM8AbF+c4fXgamA1XDHVIfXy/n -MexxZMsuSCSDq5XM5GMImffmBXA1dNJ6ytfJi668C+kF ------END CERTIFICATE----- -- cgit v1.2.3