Support for 302 - Moved Temporarily

LucasClarkson

New Member
I am trying to use Flashphoner to restream RTSP from a VMS to a browser using WebRTC. Due to the way the VMS is setup, sometimes the response back is a 302, indicating the RTSP stream should be initialized from a different location. This response code is treated as an error in Flashphoner and the stream is aborted. Is there a way around this issue or is there a plan to resolve it? The fix would be pretty easy since the new location is returned in the response.

Example error:
RtspAgent - pool-338-thread-1 Received bad response 302 Moved Temporarily, aborting

Example response:
RTSP/1.0 302 Moved Temporarily
Location: rtsp://10.36.30.20:654/01000000-0001-babe-0046-00166cc23dc7/live?redirected=true
CSeq: 3
Session: 24233300
X-RtspClientVersion: 5.7

I will email the logs associated with this error to support@flashphoner.com
 

Max

Administrator
Staff member
Hello
We raised internal ticket WCS-2006
Will inform once we have any progress on this issue.
 

Max

Administrator
Staff member
Good day.
We released the build 5.2.179 with 302 Moved Temporarily redirect support for RSTP streams. Please update to this build and check.
 

stone

New Member
We are running 5.2.1143 and seeing this same error. Any suggestions to work around this 302 Moved message?

14:42:52,161 INFO RtspAgent - pool-603-thread-1 Set auth header: Digest username="", realm="media@genetec.com", nonce="d3bbe0df34004a14b48eed803a2dd9e0", uri="rtsp://url.net:654/00000001-0000-babe-0000-accc8ebff42c/live", response="425d7a450bfbe0381f70ad4d4b1503a1", algorithm=MD5, qop=auth, cnonce="1234567890", nc=00000001
14:42:52,164 INFO RtspAgent - pool-603-thread-1 Received redirect 302 Moved Temporarily
14:42:52,164 INFO RtspAgent - pool-603-thread-1 Channel closed
14:42:52,164 WARN annelUpstreamHandler - pool-603-thread-1 EXCEPTION, please implement com.flashphoner.F.B.exceptionCaught() for proper handling.
java.net.BindException: Address already in use
at sun.nio.ch.Net.bind0(Native Method)
at sun.nio.ch.Net.bind(Net.java:461)
at sun.nio.ch.Net.bind(Net.java:453)
at sun.nio.ch.SocketChannelImpl.bind(SocketChannelImpl.java:584)
at sun.nio.ch.SocketAdaptor.bind(SocketAdaptor.java:147)
at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink.bind(Unknown Source)
at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink.eventSunk(Unknown Source)
at org.jboss.netty.handler.codec.oneone.OneToOneEncoder.handleDownstream(Unknown Source)
at org.jboss.netty.channel.Channels.bind(Unknown Source)
at org.jboss.netty.channel.AbstractChannel.bind(Unknown Source)
at org.jboss.netty.bootstrap.ClientBootstrap.connect(Unknown Source)
at org.jboss.netty.bootstrap.ClientBootstrap.connect(Unknown Source)
at com.flashphoner.server.remote.E.D.B(Unknown Source)
at com.flashphoner.server.remote.E.D.B(Unknown Source)
at com.flashphoner.server.remote.E.D.A(Unknown Source)
at com.flashphoner.F.B.messageReceived(Unknown Source)
at org.jboss.netty.channel.Channels.fireMessageReceived(Unknown Source)
at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(Unknown Source)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(Unknown Source)
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(Unknown Source)
at org.jboss.netty.channel.Channels.fireMessageReceived(Unknown Source)
at org.jboss.netty.channel.Channels.fireMessageReceived(Unknown Source)
at org.jboss.netty.channel.socket.nio.NioWorker.read(Unknown Source)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.processSelectedKeys(Unknown Source)
at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(Unknown Source)
at org.jboss.netty.channel.socket.nio.NioWorker.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:750)
14:42:52,172 INFO RtspAgent - pool-603-thread-1 build auth header: abc 123 rtsp://10.x.x.x:654/00000001-0000-babe-0000-accc8ebff42c/live?redirected=true OPTIONS
 

Max

Administrator
Staff member
@stone
We tested the sream URL you've sent. Unfortunately, it cannot be played both with WCS and VLC with connection timed out message (see VLC screenshot below):
1691367653495.png

Please check if your stream can be played in VLC. Also the stream must be available 24/7 to test it.
 
Top