Create Self Signed Certificate

            

Scenario: Scan your website for SSL vulnerabilities

Solution:

Create Self Signed Certificate

Below are the steps:

  1. mmc -> Add/Remove Snap-ins -> Certificates -> Computer Account -> Finish -> Ok
  2. Certificates -> Personal -> Certificates -> Request New Certificate -> Active Directory Enrollment Policy -> Web Server 2010 -> Certificate Properties
  3. Name - {cert_name}
  4. Subject name:
    1.   Common name - *.subdomain.domain.com
    2.   Email - test@test.com
    3.   Organzation - Test
  5. Alternative name: 
    1. DNS - my.site1.test.com
    2. DNS - my.site2.test.com
    3. DNS - my.site.test.com
    4. ipv 6: - ip address
  6. Certificate is now available.
  7. IIS -> Web Site -> Bindings -> 443 -> SSL certificate
Use Open SSL to create certificate:
    >openssl req -new -newkey rsa:2048 -nodes -keyout server.key -out server.csr -config ssl.conf
    
    >openssl x509 -req -in server.csr -signkey server.key -out server.crt
    
    >openssl pkcs12 -export -out gfcclocal.pfx -inkey server.key -in server.crt
    [req]
    distinguished_name = req_distinguished_name
    x509_extensions = v3_req
    prompt = no
    [req_distinguished_name]
    C = US
    ST = NY
    L = New York
    O = Test, Inc.
    OU = MyDivision
    CN = *.cloud.test.com
    [v3_req]
    keyUsage = critical, digitalSignature, keyAgreement
    extendedKeyUsage = serverAuth
    subjectAltName = @alt_names
    [alt_names]
    DNS.1 = my.site.test.com
    DNS.2 = my.site1.test.com
    DNS.3 = my.site2.test.com
    DNS.4 =  ip address

No comments:

Post a Comment

Move Github Sub Repository back to main repo

 -- delete .gitmodules git rm --cached MyProject/Core git commit -m 'Remove myproject_core submodule' rm -rf MyProject/Core git remo...