Hi,
If I am accessing flex AIR application from Mac or iOS (iPad) using secure rtmp then it gives me error. It is not able to connect to the server. I have a self signed certificate generated using java keytool. I have configured it on tomcat and it works for the ssl in browser with https://localhost:8080, but fails when using rtmps from flex application especially in Mac and iPad. It works in Android tablet and windows machine though.
Here is the configuration in I gave in the server for ssl.
<server id="secure-nio-server" class="flex.messaging.socketserver.SocketServer">
<properties>
<keystore-file>D:/keystore.jks</keystore-file>
<keystore-password>password</keystore-password>
</properties>
</server>
<channel-definition id="mobility-rtmp"
class="mx.messaging.channels.SecureRTMPChannel">
<endpoint url="rtmps://{server.name}:@flex.rtmp.port@"
class="flex.messaging.endpoints.SecureRTMPEndpoint"/>
<server ref="secure-nio-server">
<properties>
<idle-timeout-minutes>20</idle-timeout-minutes>
<!-- for deployment on WebSphere, must be mapped to a WorkManager available in the web application's jndi context.
<websphere-workmanager-jndi-name>java:comp/env/wm/MessagingWorkManager</websphere-workmanager-jndi-name>
-->
</properties>
</server>
</channel-definition>
Here is the exception I am getting on server side.
INFO: [LCDS] 01/21/2012 17:14:44.258 [ERROR] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] failed to read Connection '521330370' or process the data; Connection is in the 'Handshaking' state and will be forced closed.
javax.net.ssl.SSLException: Inbound closed before receiving peer's close_notify: possible truncation attack?
at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLEngineImpl.fatal(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLEngineImpl.fatal(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLEngineImpl.closeInbound(Unknown Source)
at flex.messaging.socketserver.SSLConnection.handshake(SSLConnection.java:298)
at flex.messaging.socketserver.Connection$ConnectionReader.run(Connection.java:845)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Jan 21, 2012 5:14:44 PM org.apache.catalina.core.ApplicationContext log
INFO: [LCDS] 01/21/2012 17:14:44.258 [DEBUG] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] Connection '521330370' has changed state to: Closing
Jan 21, 2012 5:14:44 PM org.apache.catalina.core.ApplicationContext log
INFO: [LCDS] 01/21/2012 17:14:44.258 [DEBUG] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] closing Connection '521330370'.
Jan 21, 2012 5:14:44 PM org.apache.catalina.core.ApplicationContext log
INFO: [LCDS] 01/21/2012 17:14:44.258 [DEBUG] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] Connection '521330370' has changed state to: Closed
Jan 21, 2012 5:14:44 PM org.apache.catalina.core.ApplicationContext log
INFO: [LCDS] 01/21/2012 17:14:44.258 [DEBUG] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] closed Connection '521330370'.
Jan 21, 2012 5:14:44 PM org.apache.catalina.core.ApplicationContext log
INFO: [LCDS] 01/21/2012 17:14:44.258 [DEBUG] [SocketServer.General] Thread[secure-nio-server-WorkerThread-2,5,main] Connection '521330370' finished a read. -1 bytes were read.
Please help.
Thanks,
Swathi.
Views
Replies
Total Likes
I would suggest taking up this question on the AIR for iOS forums, since Data Services uses the RTMP Channel and connection capability provided by AIR. I believe adding the certificate to your login keychain might be of assistance on Mac.
Views
Replies
Total Likes
Thank you for the response. I will try the suggestion and also post in AIR forums.
Thanks,
Swathi.
Views
Replies
Total Likes
Did you get anywhere with this, I'm having a similar issue?
I have an Air app that works fine using rtmp in iOS but not rtmps (it works fine in Android for both). The release notes for 3.1 (http://kb2.adobe.com/cps/923/cpsid_92350.html) suggest there was a problem for rtmps on iOS, but I'm using the latest 3.1 SDK version.
I'm suspecting an SSL certificate issue as in Android I get prompted as to whether I trust the certificate, but not on the iPhone. I have installed the certificate manually but to no avail.
Views
Replies
Total Likes
We had to use trusted certificate instead of self signed certificate for iOS.
Thanks,
Swathi.
Views
Replies
Total Likes
@ MrCodeghost
Hi,
As you have mentioned in the post that "I have an Air app that works fine using rtmp in iOS".
Does your Air app have audio/video publish or recieving capabilitites?
If yes then I want to ask that did you face any abrupt stopping of the audio/video stream after 18-20 mins?
Views
Replies
Total Likes
Yes we publish video and audio from the handset, but I'm afraid I've never had anything publish for that long so haven't seen any issue at the length of time.
Views
Replies
Total Likes
Thanks
Views
Replies
Total Likes
Hi,
I am working on an AIR app that works using rtmps on ios (iPAD). the rtmps connection with audio stream works fine until it timesout after 18 - 20 mins. The timeout time is random, but on an average most time outs occur at 20 mins. My problem seems to be close to your question. If so, do you any explanation / solution to it.
Thanks
kalyan
Views
Replies
Total Likes
Hi Kalyan,
What value of the renderMode you are using for the app?
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies