Build the HTTPS site using OpenSSL generation self-signed certificate (IIS)

Source: Internet
Author: User
Tags install openssl openssl pfx file

First, install OpenSSL open OpenSSL.exe require Administrator privileges


Second, input genrsa-out Myself.key 1024,myself.key The name of the key at random, 1024 for the key length

Generates Myself.key files.

Third, input Req-new-x509-key myself.key-out myself.cer-days 365-subj/cn=www.mysite.com

Myself.key is the name of the key that was generated before, Myself.cer is the generated certificate, 365 is the certificate expiration days, and the CN parameter www.mysite.com is your host name.

The certificate file Myself.cer was generated.

Four, the private key file for a PFX is required in IIS.

Enter Pkcs12-export-out Myself.pfx-inkey myself.key-in myself.cer

You need to enter a password and use the private key to use it.

The private key file myself.pfx was generated.

V. Open IIS Manager click Server Certificate


Click Import ...

Select myself.pfx File Enter the password entered at build time

Add Web site

Select HTTPS, use 443 port, and select the server certificate that you just imported.

This allows the HTTPS site to be completed, and the client with the Myself.cer certificate installed can be securely accessed.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.