申请免费ssl

  • 登录阿里云 https://www.aliyun.com/
  • 搜索ssl证书
  • 购买证书选择 单域名->DV SSL -> 免费版
  • 签发后如下,选择下载证书即可

nginx 配置ssl

  • 下载nginx证书
    listen       443 ssl;
    ssl on;
    server_name  xx;

    root html;
    index index.html;

    ssl_certificate      /usr/local/nginx/ssl/4345092_xx.com.pem;
    ssl_certificate_key  /usr/local/nginx/ssl/4345092_xx.com.key;

    ssl_session_timeout  5m;

    ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
    ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
    ssl_prefer_server_ciphers  on;

springboot 配置ssl

  • 下载tomcat-ssl证书
server: 
  port: 443
  ssl:
    key-store: "4363903_xxx.com.pfx"
    key-store-password: xxxxx
    keyStoreType: PKCS12
  tomcat:
    uri-encoding: UTF-8

其他web服务器配置详情请参见
https://help.aliyun.com/document_detail/98908.html?spm=a2c4g.11186623.6.570.fade20c6erkc2Y

版权声明:本文为pengsn原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://www.cnblogs.com/pengsn/p/13519201.html