I’m trying to put together a module that authenticates users against our database instead of the the publish.password file.
I’m using Adobe Flash Media Encoder to do streaming.
It looks like I need to implement ModuleRTMPAuthenticate.onConnect, but onConnect doesn’t seem to like people playing with it.
FME connects, but when I try to Publish, I always get:
Status: NetStream.Publish.Failed
No other info is provided, even in the logs.
Also, I’ve tried it with and without the rtmpEncoderAuthenticatorFile property in Application.xml. It doesnt seem to make a difference.
Here’s some test code I was running:
public class testAuthentication extends ModuleRTMPAuthenticate{
public void onConnect(IClient client, RequestFunction function,AMFDataList params) {
getLogger().info("testAuthentication.onConnect");
client.acceptConnection();
}
}
On a side note, I can accomplish what I want to do using the publish() method from ModuleBase, but it doesn’t fail as gracefully…there’s no pop-up box that appears for user/pass (has to be passed in then URL), and it FME hangs for a couple seconds when it receives client.rejectConnection() from publish().
So I’d really like it to behave like a “regular” FME session…password pop-up on connect, etc.
Any insight would be greatly appreciated.
thanks,
altimage