I'm having some problems:
First of all i use cupertinostreaming to stream to iOs devices. I also wrote an Module which parses the QueryString to get the login data and connect aswell to a database.
This is working great. Now I want to kickout a viewer if he is logging in again so that the old session gets killed.
I'm doing something like this:
After the User/Password is successfully authenticated i get the cookie value i set before.
if i use rejectSession() the session is simply dropped. But i want that the old (but ACTIVE!!!) connection reset itself and redirect to a vod/livestream which displays that he was logged out.
List<IHTTPStreamerSession> clients = applicationInstance.getHTTPStreamerSessions();
Iterator<IHTTPStreamerSession> iter = clients.iterator();
IHTTPStreamerSession client = iter.next();
String vergleich = client.getCookieStr();
if(!client.isAcceptSession()|| vergleich == null)
/* DO IT HERE */
getLogger().info((new StringBuilder()).append("Kicke ").append(username).toString());
Is that even possible? I tried a sessionRedirect but that just end in a stopped stream on the client (which makes sense if the cupertino-proto is not capable of recieving a redirect while playing an stream.)
I cant kick the user just like that, he needs to know that the session was dropped because of using his credentials twice.
Or is it maybe possible to inject another ts file and closing the connection after playing that?.
I'm kind of desperated.
Thanks in advance!