- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
如何在不同的机器上为 CAS 服务器和客户端设置 ssl 证书(自签名)
最佳答案
您能否添加您正在获取的异常以及在哪个节点中?
作为一般建议,请注意:
1) 如果您在服务器端使用 cas 客户端和 CAS 服务器之间的 https 通信,则必须在客户端 JVM 机器上安装证书
2) JVM 将不接受(在运行时)带有 CN(通用名称)中的 ip 的自签名证书。
见 https://wiki.jasig.org/display/CASUM/SSL+Troubleshooting+and+Reference+Guide更多细节
因此,从您发布的异常来看,似乎是以下情况(引自上面的 CAS 故障排除链接):
No subject alternative names present Sample Alt Name Stack Trace javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: No subject alternative names present In most cases this is a hostname/SSL certificate CN mismatch.
This commonly happens when a self-signed certificate issued to localhost is placed on a machine that is accessed by IP address. It should be noted that generating a certificate with an IP address for a common name, e.g. CN=192.168.1.1,OU=Middleware,dc=vt,dc=edu, will not work in most cases where the client making the connection is Java. For example the Java CAS client will throw SSL errors on connecting to a CAS server secured with a certificate containing an IP address in the CN.
关于single-sign-on - 如何为 CAS 和客户端(不同的机器)设置 SSL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9331087/
我是一名优秀的程序员,十分优秀!