当前位置: 首页 > news >正文

高端建网站多少钱网站线框图怎样做

高端建网站多少钱,网站线框图怎样做,楼盘信息在哪里能查到,外贸网站建设不可缺少的灵活性SringBoot 如何使用HTTPS请求及Nginx配置Https SringBoot 如何使用HTTPS请求生成证书导入证书及配制创建配置类将pfx转成.key和.pem Nginx 安装SSL依赖./configure 安装依赖编译安装完openssl后报了新错 Nginx配置 SringBoot 如何使用HTTPS请求 生成证书 由于业务数据在传输过… SringBoot 如何使用HTTPS请求及Nginx配置Https SringBoot 如何使用HTTPS请求生成证书导入证书及配制创建配置类将pfx转成.key和.pem Nginx 安装SSL依赖./configure 安装依赖编译安装完openssl后报了新错 Nginx配置 SringBoot 如何使用HTTPS请求 生成证书 由于业务数据在传输过程中需要保密我们组小同学写了一个HTTPS接口。该接口用到的证书是通过JDK自带的证书生成工具keytool使用keytool来生成证书。打开终端或者命令行输入命令回车,然后输入信息,其中秘钥库口令和秘要口令最好输入同一个,并且记下这个口令。 //keytool -genkey -alias tomcat -storetype PKCS12 -keyalg RSA -keysize 2048 -keystore keystore.p12 -validity 3650 keytool -genkey -alias kshttps -keyalg RSA -keysize 2048 -validity 36524 -keystore kshttps.jks keytool -importkeystore -srckeystore kshttps.jks -destkeystore kshttps.pkcs12 -deststoretype pkcs12 openssl pkcs12 -nodes -in kshttps.pkcs12 -out kshttps.pem openssl pkcs12 -nocerts -nodes -in kshttps.pkcs12 -out kshttps.keykey -genkey 生成-alias 别名-storetype 指定密钥库的类型eg:JKS 、PKCS12通常以.p12或.pfx两种文件形式出现、PKCS11、BCFKS、DKS、Windows-MY、Windows-ROOT、PEM不能直接用Keytool导出但可用OpenSSL工具一起使用-keyalg RSA 代表算法.RSA是非对称加密-keysize 密钥长度-keystore 生成路径文件名-validity有效期 导入证书及配制 证书生成完成后可以导入到到项目中将其复制到Springboot项目的resources目录下 配置yml配置文件即可 server:port: 8080ssl:#开启httpsenabled: true#指定存放证书的密钥库文件的位置key-store: classpath:springboot.keystore#密钥库文件的格式key-store-type: PKCS12#别名需要与创建密钥库时的别名一致key-alias: springboot-httpskey-password: 123456 key-store-password: 123456 http:port: 8090创建配置类 Configuration public class HttpsConfig {Value(${http.port})private Integer httpPort;Beanpublic ServletWebServerFactory servletContainer() {Connector connector new Connector(TomcatServletWebServerFactory.DEFAULT_PROTOCOL);connector.setPort(httpPort);final TomcatServletWebServerFactory tomcat new TomcatServletWebServerFactory();tomcat.addAdditionalTomcatConnectors(connector);return tomcat;} } 将pfx转成.key和.pem 为什么转呢因为Nginx的配置中是要求一个.key和.pem格式的其他可否我没有验证。大家可以自己查询。但我是直接转成两后缀的文件了。转换工具可能过openssl转参考命令如下所示 openssl pkcs12 -in keystore.pfx -out cert.key -nocerts openssl pkcs12 -in keystore.pfx -out cert.pem -nodes 其他转换当了解了也附在本文中,不想学习的可跳过这部分 1pem转换pfxopenssl pkcs12 -export -in test.pem -inkey test.key -out test.p12 -passout pass:1234562pem转换jksopenssl pkcs12 -export -in test.pem -inkey test.key -out test.p12 -passout pass:123456keytool -importkeystore -srckeystore test.p12 -srcstoretype PKCS12 -destkeystore test.jks -srcstorepass 123456 -deststorepass 1234563pfx转换pemopenssl pkcs12 -in test.p12 -passin pass:123456 -out test3.pem -nodes4pfx转换jkskeytool -importkeystore -srckeystore test.p12 -srcstoretype PKCS12 -destkeystore test.jks -srcstorepass 123456 -deststorepass 1234565jks转换pemkeytool -importkeystore -srckeystore test.jks -srcstoretype jks -destkeystore test.p12 -deststoretype PKCS12 -srcstorepass 123456 -deststorepass 123456openssl pkcs12 -in test.p12 -passin pass:123456 -out test3.pem -nodes6jks转化pfxkeytool -importkeystore -srckeystore test.jks -srcstoretype jks -destkeystore test.p12 -deststoretype PKCS12 -srcstorepass 123456 -deststorepass 123456Nginx 安装SSL依赖 Nginx配置HTTPS需要先安装依赖。否用支报如下错误 如上所示我们可以执行以下命令解决 ./configure 安装依赖 ./configure --prefix/usr/local/nginx --usernginx --groupnginx --with-http_ssl_module 如果报以下错误提示请顺序读完如果不报请跳至下一章节 You can either do not enable the modules, or install the OpenSSL library into the system, or build the OpenSSL library statically from the source with nginx by using --with-opensslpath option.解决这个问题首先需要检查是否安装了OpenSSL通过openssl version查看,未安装可以参考以下命令进行安装 yum -y install openssl openssl-devel如果确定已安装可找下安装位置。使用which openssl 命令。但需要注意通过此命令如果找到的是安装后的命令则无效仍不好使需要找到安装源路径如无法找到可以通过https://www.openssl.org/source/ 下载进行安装。安装成功后重新执行以下命令和make  install。 出现了新错误莫慌请看下去 ./configure --with-openssl/usr/openssl --prefix/usr/local/nginx --usernginx --groupnginx --with-http_ssl_module find / -name ssl.h编译 make make install安装完openssl后报了新错 到这步后需要修改下Nginx源路径下的 auto/lib/openssl/conf vi auto/lib/openssl/conf 修改内容如下所示 Nginx配置 server {listen 443 ssl;server_name 127.0.0.1;ssl_certificate cert.pem;ssl_certificate_key cert.key;ssl_session_cache shared:SSL:1m;ssl_session_timeout 5m;# ssl_ciphers HIGH:!aNULL:!MD5;# ssl_prefer_server_ciphers on;location /wscc-interface {# root html;# index index.html index.htm;proxy_pass http://127.0.0.1:443/;}}
http://www.w-s-a.com/news/625073/

相关文章:

  • 郎创网站建设做的网站 v2ex
  • 广东网站建设教程江西城乡住房建设网站
  • 做ppt卖给网站wordpress insert
  • 文化传媒公司网站模板wordpress转typecho
  • 网站建设设计视频郑州 服装网站建设
  • 网站建设什么公司好织梦cms默认密码
  • 大型网站 空间网上商城官网入口
  • 成都全美网站建设江苏专业网站建设
  • 足球网站模板有帮忙做阿里巴巴网站的吗
  • 建设厅报名网站京东网站的建设与发展前景
  • 金寨县住房和城乡建设部网站网页作业怎么做一个网站
  • 做ppt模板网站有哪些内容wap是什么意思卡老师
  • 网站建设一定要域名吗网站后台关键词设置
  • 标书制作公司网站坪山网站建设哪家便宜
  • 防止做网站的人修改数值门户网站架构
  • 电子项目外包网站考二建需要什么学历和专业
  • 做网站推广引流效果好吗电商推广技巧
  • 亦庄网站建设价格广州网站推广服务
  • 十大免费ppt网站下载重庆在线高校平台登录
  • 做环保网站案例百度seo教程
  • 体育用品网站模板网站建设话术
  • 潍坊网站建设服务商做网站多久能盈利
  • 嘉定区做网站房产信息查询官网
  • 网站直播间 是怎么做的唐山论坛建站模板
  • 深圳洲聚网站建设wordpress 泛解析
  • 五金东莞网站建设技术支持wordpress 添加模板
  • 网站申请专利春节网页设计素材
  • 进网站备案md风格的wordpress主题
  • 如何建站网站十大免费建站app
  • 工作号做文案素材的网站晋城网站设计人