tomcat安装ssl证书Connector attribute SSLCertificateFile must be defined when using SSL with APR

news/2024/7/12 3:21:06 标签: tomcat, ssl, https, 证书

其实网上有很多安装的教程,这里简单放一些参考链接:
https://cloud.tencent.com/document/product/400/35224

但应该有很多人和我一样,按照教程改了 tomcat 的 server.xml 后,启动是报错 Connector attribute SSLCertificateFile must be defined when using SSL with APR
https://img-blog.csdnimg.cn/20191203201625852.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L0RvYmlsaXR5,size_16,color_FFFFFF,t_70" alt="Connector attribute SSLCertificateFile must be defined when using SSL with APR" />
以下是我成功的配置:

<Connector port="443" protocol="org.apache.coyote.http11.Http11Protocol" SSLEnabled="true"
               maxThreads="150" scheme="https" secure="true"
               sslProtocol="TLS"
               keystoreFile="${your jks file path}" 
               keystorePass="${your password}"
               clientAuth="false"/>

关键点:把 protocol=“HTTP/1.1” 改成 protocol=“org.apache.coyote.http11.Http11Protocol”,然后增加一个 sslProtocol=“TLS”


http://www.niftyadmin.cn/n/1436942.html

相关文章

mysql中条件限制语句(一)where in and

1.between语句: mysql> select * from 4a where score between 76 and 89; +--------+------+--------+------+--------+------+------+-------+ | sname | sage | tname | t | cname | s | c | score | +--------+------+--------+------+--------+------+---…

mysql中条件限制语句(二)like 全匹配 全模糊 distinct limit

5.limit语句: 语法:select 字段名 from 标明 limit 起始行,查询几行; mysql> select * from 4a limit 0,3; +--------+------+--------+------+--------+------+------+-------+ | sname | sage | tname | t | cname | s | c | score | +--------+------+---…

Warning: no saslprep library specified. Passwords will not be sanitized

在 nodejs 中使用密码连接 mongodb 时&#xff0c;会报 warning&#xff1a; Warning: no saslprep library specified. Passwords will not be sanitized在 mongodb 的依赖里 node_modules/mongodb/lib/core/auth/scram.js 发现有以下代码&#xff1a; 12&#xff1a; let s…

mysql七表查询实例(一)

开始之前先说点有趣的事&#xff1a;经常听说没有主键就无法进行多表查询&#xff0c;其实这太过于片面了。实际上有些情况没有主键也是可以进行多表查询的&#xff08;例一&#xff0c;所用到的表格也都是下面的表格&#xff0c;先来个4表查询热热身&#xff09;。 mysql>…

微信小程序 msg_sec_check 正确调用方式

在服务端使用微信小程序的内容安全检查等接口时&#xff0c;尽管按文档 https://developers.weixin.qq.com/miniprogram/dev/api-backend/open-api/sec-check/security.msgSecCheck.html 的要求传了参数&#xff0c;但是还是会出错&#xff0c;而用 postman 等工具却正常&#…

项目中统一换行符CRLF/LF还需增加的git配置

背景 我们在合作开发中&#xff0c;对于 git 的配置往往是只有 .git 文件夹&#xff0c;或者再多一个 .gitignore 文件&#xff0c;常常忽略了一个非常重要的内容&#xff1a;换行符。 换行符是个很重要的东西&#xff0c;特别是当你的项目或者团队使用了不同的操作系统时&am…

mysql七表查询实例(二)

上一章的内容大家觉得怎么样&#xff1f; 接下来&#xff0c;让我们来一点一点继续深入。 1.查询成绩大于60分的所有信息&#xff1a; mysql> select * from(select student.s,sname,cadd,sage,sc.class,teacher.t,cname,score,tname,tadd,ssex,cphone from student,teac…

JSON.stringify的使用和一些思维拓展

平时在对一个数据进行凑合用的 json化&#xff0c;我们会直接 JSON.stringify(obj) 输出一个一行的字符串&#xff0c;并且会自动过滤掉 undefined、Function、Symbol等内容&#xff0c;对于递出现循环引用则会直接报错。 但它实际上能够接3个参数&#xff0c;而且&#xff0c…