Take a look at this example:
http://www.wowzamedia.com/forums/sho...Authentication
You can add user to a hashmap. You can also add info the IClient Properties container.
Code:
public void onConnect(IClient client, RequestFunction function,
AMFDataList params) {
getLogger().info("onConnect: " + client.getClientId());
String userName = getParamString(params, PARAM1);
client.getProperties().setProperty("userName", userName);
}
Then you can retrieve in any function with IClient argument:
Code:
public void onConnectAccept(IClient client) {
getLogger().info("onConnectAccept: " + client.getClientId());
String userName = client.getProperties().getPropertyStr("userName");
}
Richard