NOTE TO SELF ABOUT CERTS
##########################
This is githubs cert. Saving the entire thing as a cert file makes it valid
It looks for the
—–BEGIN CERTIFICATE—–
—–END CERTIFICATE—–
—–BEGIN CERTIFICATE—–
—–END CERTIFICATE—–
So the rest you can save as note, I mean you literally can save all of the below output as a file as .crt and it will be a valid cert. It can have CR or CR+LF line endings it doesnt matter.
The TOP one is githubs cert
The BOTTOM one is the CA / root cert (if you look @ it through windows by double clicking on this cert you can see the 2 parts – either save it as a whole cert contain both the github and the root cert or just save em seperately and open the root cert you will see that the issuer and subject are the same entity but because of the character differences @ the end it makes them seperate:
 1 s:/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV CA-1
   i:/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV Root CA
   However the should still be though of as a single root cert – its almost like an intermediate cert where you have GITHUB cert some INTERMEDIATE cert auth group and the ROOT AUTH but in this case the INTERMEDIATE and the ROOT are the same entity so just think of it as I said in the beginning where you have GITHUB cert and the ROOT AUTH cert)
# openssl s_client -showcerts -connect github.com:443
CONNECTED(00000003)
depth=1 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert High Assurance EV CA-1
verify error:num=20:unable to get local issuer certificate
verify return:0
Certificate chain
 0 s:/businessCategory=Private Organization/1.3.6.1.4.1.311.60.2.1.3=US/1.3.6.1.4.1.311.60.2.1.2=Delaware/serialNumber=5157550/street=548 4th Street/postalCode=94107/C=US/ST=California/L=San Francisco/O=GitHub, Inc./CN=github.com
   i:/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV CA-1
—–BEGIN CERTIFICATE—–
MIIHOjCCBiKgAwIBAgIQBH++LkveAITSyvjj7P5wWDANBgkqhkiG9w0BAQUFADBp
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSgwJgYDVQQDEx9EaWdpQ2VydCBIaWdoIE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YLEQViSo+nlOSUQ8YAVqu6KcsP/e612UiqS
+UMBmgdx9KPDDzZy4MJZC2hbfUoXj9A54mJN8cuEOPyw3c3yKOcq/h48KzVguQXi
SdJbwfqNIbQ9oJM+YzDjzS62+TCtNSNWzWbwABZCmuQxK0oEOSbTmbhxUF7rND3/
+mx9u8cY//7uAxLWYS5gIZlCbxcf0lkiKSHJB319
—–END CERTIFICATE—–
 1 s:/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV CA-1
   i:/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV Root CA
—–BEGIN CERTIFICATE—–
MIIG5jCCBc6gAwIBAgIQAze5KDR8YKauxa2xIX84YDANBgkqhkiG9w0BAQUFADBs
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSswKQYDVQQDEyJEaWdpQ2VydCBIaWdoIEFzc3VyYW5j
ZSBFViBSb290IENBMB4XDTA3MTEwOTEyMDAwMFoXDTIxMTExMDAwMDAwMFowaTEL
MAkGA1UEBhMCVVMxFTATBgNVBAoTDERpZ2lDZXJ0IEluYzEZMBcGA1UECxMQd3d3
LmRpZ2ljZXJ0LmNvbTEoMCYGA1UEAxMfRGlnaUNlcnQgSGlnaCBBc3N1cmFuY2Ug
RVYgQ0EtMTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAPOWYth1bhn/
PzR8SU8xfg0ETpmB4rOFVZEwscCvcLssqOcYqj9495BoUoYBiJfiOwZlkKq9ZXbC
7L4QWzd4g2B1Rca9dKq2n6Q6AVAXxDlpufFP74LByvNK28yeUE9NQKM6kOeGZrzw
PnYoTNF1gJ5qNRQ1A57bDIzCKK1Qss72kaPDpQpYSfZ1RGy6+c7pqzoC4E3zrOJ6
4GAiBTyC01Li85xH+DvYskuTVkq/cKs+6WjIHY9YHSpNXic9rQpZL1oRIEDZaARo
LfTAhA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pZ2ljZXJ0LmNvbS9EaWdpQ2VydEhpZ2hB
c3N1cmFuY2VFVlJvb3RDQS5jcmwwQKA+oDyGOmh0dHA6Ly9jcmw0LmRpZ2ljZXJ0
LmNvbS9EaWdpQ2VydEhpZ2hBc3N1cmFuY2VFVlJvb3RDQS5jcmwwHQYDVR0OBBYE
FExYyyXwQU9S9CjIgUObpqig5pLlMB8GA1UdIwQYMBaAFLE+w2kD+L9HAdSYJhoI
Au9jZCvDMA0GCSqGSIb3DQEBBQUAA4IBAQBMeheHKF0XvLIyc7/NLvVYMR3wsXFU
nNabZ5PbLwM+Fm8eA8lThKNWYB54lBuiqG+jpItSkdfdXJW777UWSemlQk808kf/
roF/E1S3IMRwFcuBCoHLdFfcnN8kpCkMGPAc5K4HM+zxST5Vz25PDVR708noFUjU
xbvcNRx3RQdIRYW9135TuMAW2ZXNi419yWBP0aKb49Aw1rRzNubS+QOy46T15bg+
BEkAui6mSnKDcp33C4ypieez12Qf1uNgywPE3IjpnSUBAHHLA7QpYCWP+UbRe3Gu
zVMSW4SOwg/H7ZMZ2cn6j1g0djIvruFQFGHUqFijyDATI+/GJYw2jxyA
—–END CERTIFICATE—–
Server certificate
subject=/businessCategory=Private Organization/1.3.6.1.4.1.311.60.2.1.3=US/1.3.6.1.4.1.311.60.2.1.2=Delaware/serialNumber=5157550/street=548 4th Street/postalCode=94107/C=US/ST=California/L=San Francisco/O=GitHub, Inc./CN=github.com
issuer=/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert High Assurance EV CA-1
No client certificate CA names sent
SSL handshake has read 3931 bytes and written 634 bytes
New, TLSv1/SSLv3, Cipher is RC4-SHA
Server public key is 2048 bit
Secure Renegotiation IS supported
Compression: NONE
Expansion: NONE
SSL-Session:
    Protocol  : TLSv1
    Cipher    : RC4-SHA
    Session-ID: D79623C0B963A091F14C207F0F159A3E6D3A9195BB480EC33B5C072904FAEFB8
    Session-ID-ctx:
    Master-Key: 3FA5D90B332C0D8043AEDA9C78AAA5DCA86C4D782F3FDD6646068CE7FB5F210603157BF41FBAFA460D18FEA4096E243B
    Key-Arg   : None
    PSK identity: None
    PSK identity hint: None
    SRP username: None
    TLS session ticket:
    0000 – f7 1e ac 2e a9 5b e3 1d-29 64 e1 92 7c 61 a8 2f   …..[..)d..|a./
    0010 – 61 7f 2f 22 9f 5f af 4c-65 26 10 40 a8 79 fc 46   a./”._.Le&.@.y.F
    0020 – 53 6d d3 1f 2c 6e 90 35-db 38 a7 c5 31 31 23 60   Sm..,n.5.8..11#`
    0030 – 9c 1b 08 99 d2 45 32 76-83 f3 bf a7 94 42 5c fb   …..E2v…..B\.
    0040 – 5c cd 21 b4 74 00 9b 9c-70 28 0f 92 10 01 91 25   \.!.t…p(…..%
    0050 – 58 8f e4 45 98 d0 31 9e-dd 3e a4 dd 7c 41 8d 82   X..E..1..>..|A..
    0060 – 11 88 c5 8c a3 96 3c ea-df 77 5a 32 d6 8c 3e 1c   ……<..wZ2..>.
    0070 – f7 0b 54 08 05 c0 5f 11-e5 c8 b8 e0 26 77 e6 1c   ..T…_…..&w..
    0080 – 32 f7 ab a9 da 57 bf da-24 2f 22 04 c8 aa 3b 0b   2….W..$/”…;.
    0090 – c3 d7 27 c5 39 81 7b 00-2f 62 4c 33 ef 47 4e 0e   ..’.9.{./bL3.GN.
    Start Time: 1376622532
    Timeout   : 300 (sec)
    Verify return code: 20 (unable to get local issuer certificate)
read:errno=0

Leave a Reply

Your email address will not be published. Required fields are marked *