Android Ant media webrtc连接到服务器时出现java.security.cert.CertPathValidator异常
我正在尝试连接到Ant media webrtc服务器Android Ant media webrtc连接到服务器时出现java.security.cert.CertPathValidator异常,android,webrtc,ant-media-server,webrtc-android,Android,Webrtc,Ant Media Server,Webrtc Android,我正在尝试连接到Ant media webrtc服务器wss://abcd.com:1234/demoApp/websocket。不管它怎么扔 de.tavendo.autobahn.WebSocketReader: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found. de.tavendo.autobahn.WebSocketWriter: Socket is
wss://abcd.com:1234/demoApp/websocket
。不管它怎么扔
de.tavendo.autobahn.WebSocketReader: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
de.tavendo.autobahn.WebSocketWriter: Socket is closed
我正在使用ant media webrtc框架示例android示例并更改URL。它在antmedia的测试服务器上运行良好
wss://test.antmedia.io:5443/demo1234/websocket(URL changed for security purposes)
但是,我始终无法连接到主服务器。这是我在android上用来连接服务器的代码
webRTCClient = WebRTCClient(this@LiveSessionActivity, this)
webRTCClient.setVideoRenderers(mLiveSessionBinding?.pipViewRenderer, mLiveSessionBinding?.localGLSurfaceView)
webRTCClient.init(ANT_MEDIA_URL, mLiveSessionViewModel?.streamKey, IWebRTCClient.MODE_PUBLISH, "null", intent)
非常感谢您的帮助。谢谢 这是v2.2.1中的已知问题。您需要将chain.pem文件设置为Ant Media Server。以下是说明: 将chain.pem复制到conf
sudo cp /etc/letsencrypt/live/your_domain/chain.pem /usr/local/antmedia/conf
PS:请将您的_域更改为您的域地址
1-添加此行
http.ssl_certificate_chain_file=conf/chain.pem
<entry key="SSLCertificateChainFile" value="${http.ssl_certificate_chain_file}" />
之后
在/usr/local/antmedia/conf/red5.properties
文件中
2-添加此行
http.ssl_certificate_chain_file=conf/chain.pem
<entry key="SSLCertificateChainFile" value="${http.ssl_certificate_chain_file}" />
之后
在/usr/local/antmedia/conf/jee container.xml
文件中