[PHP] controling mjpg streams

2004-06-09 Thread Tom Playford
Dear list,

I need to restrict access to a mjpeg stream coming from Axis camera. 
My site uses sessions to authenmticate users throughout it's pages.

Is there a way (using phps stream support?) to somhow proxy this video stream from the 
camera (internal network) to an user on the web providing they have a valid session? 

Thanks,

Tom

pgptPriJJtwbp.pgp
Description: PGP signature


Re: [PHP] Re: php and java applets

2004-05-24 Thread Tom Playford
Am I? I thought that applets were allowed to connect to the same host they were loaded 
from. Which is what I'm trying to do.

Nice site BTW, useful for a few other things I'm working on, thanks.

Tom

On Sat, May 22, 2004 at 07:46:21AM +0600, raditha dissanayake wrote:
> Tom Playford wrote:
> 
> >That was my original plan. The problem is that if someone works out 
> >the commands needed to
> >communicate with the php control page, they will be able to bypass the 
> >Java access control systems.
> >I suppose I could use https, but does that encrypt the url and post data?
> >
> I think you have found yourself trapped in the java applet sandbox. You 
> need to create a signed applet. see 
> http://www.radinks.com/java/sandbox/  for a brief guide.
> 
> all the best
> 
> -- 
> Raditha Dissanayake.
> -
> http://www.raditha.com/megaupload/upload.php
> Sneak past the PHP file upload limits.
> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php and java appletsf

2004-05-24 Thread Tom Playford
On Fri, May 21, 2004 at 08:16:30AM -0700, jon wrote:
> Nah... Maybe we're both confused. Is this a java app you wrote or one 
> that you found somewhere? If you know how to control the camera from 
> java and you know how to work in java, you could build yourself a quick 
> and dirty command-line java application, then feed it commands from php 
> using exec or something similar.

Well the whole point of the java applet was to provide a nice, drag and drop interface 
to move the camera around. I already have a pure php version, it just doesn't look 
that nice and you can't drag things around.

I don't think I explained myself very well.

You can see the applet here:
http://tom.playford.net/control/control.html
It does very little at the moment.

Tom



> Tom Playford wrote:
> 
> >jon wrote:
> >
> >>Can you just send a command line java app commands from php?
> >
> >
> >I'm not sure what you're getting at.
> >
> >Do you mean writing the Java code in the php page? I didn't know php 
> >could compile the code on the fly, can it? Or do you mean something else?
> >
> >
> >Tom
> >
> >>
> >>-- jon
> >>
> >>Tom Playford wrote:
> >>
> >>>Dear all knowing list,
> >>>
> >>>I am trying to control the movement of a camera in real time from the 
> >>>web. But I also need to make sure that only the user I specify can 
> >>>have control.
> >>>
> >>>What I though I could do was this: launch a java applet from a php 
> >>>page parsing the session id. Then when the user adjusts the controls 
> >>>on the applet, a php page is loaded by the applet, sets the user 
> >>>session with the session id, then sends the control details back to 
> >>>the server and on to the camera.
> >>>
> >>>I've given this a go with no luck. When I try to set the session id 
> >>>on the php script that the Java applet loads I get a permissions 
> >>>error (the perms on /tmp are fine). I'm not 100% sure I understand 
> >>>sessions, is my method utterly implausible? Does anyone have any 
> >>>better suggestions?
> >>>
> >>>
> >>>Thanks,
> >>>
> >>>Tom Playford
> >>>
> >
> >
> >.
> >

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] php and java applets

2004-05-21 Thread Tom Playford
jon wrote:
Can you just send a command line java app commands from php?
I'm not sure what you're getting at.
Do you mean writing the Java code in the php page? I didn't know php could compile the code on the 
fly, can it? Or do you mean something else?

Tom
-- jon
Tom Playford wrote:
Dear all knowing list,
I am trying to control the movement of a camera in real time from the 
web. But I also need to make sure that only the user I specify can 
have control.

What I though I could do was this: launch a java applet from a php 
page parsing the session id. Then when the user adjusts the controls 
on the applet, a php page is loaded by the applet, sets the user 
session with the session id, then sends the control details back to 
the server and on to the camera.

I've given this a go with no luck. When I try to set the session id on 
the php script that the Java applet loads I get a permissions error 
(the perms on /tmp are fine). I'm not 100% sure I understand sessions, 
is my method utterly implausible? Does anyone have any better 
suggestions?

Thanks,
Tom Playford
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Re: php and java applets

2004-05-21 Thread Tom Playford
That was my original plan. The problem is that if someone works out the commands 
needed to
communicate with the php control page, they will be able to bypass the Java access 
control systems.
I suppose I could use https, but does that encrypt the url and post data?
Tom
Aidan Lister wrote:
> I'd implement access control in the java object if possible, sounds easier.
>
> "Tom Playford" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>
>>Dear all knowing list,
>>
>>I am trying to control the movement of a camera in real time from the web.
>
> But I also need to make sure that only the user I specify can have control.
>
>>What I though I could do was this: launch a java applet from a php page
>
> parsing the session id. Then when the user adjusts the controls on the
> applet, a php page is loaded by the applet, sets the user session with the
> session id, then sends the control details back to the server and on to the
> camera.
>
>>I've given this a go with no luck. When I try to set the session id on the
>
> php script that the Java applet loads I get a permissions error (the perms
> on /tmp are fine). I'm not 100% sure I understand sessions, is my method
> utterly implausible? Does anyone have any better suggestions?
>
>>
>>Thanks,
>>
>>Tom Playford
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] php and java applets

2004-05-21 Thread Tom Playford
Dear all knowing list,

I am trying to control the movement of a camera in real time from the web. But I also 
need to make sure that only the user I specify can have control.

What I though I could do was this: launch a java applet from a php page parsing the 
session id. Then when the user adjusts the controls on the applet, a php page is 
loaded by the applet, sets the user session with the session id, then sends the 
control details back to the server and on to the camera.

I've given this a go with no luck. When I try to set the session id on the php script 
that the Java applet loads I get a permissions error (the perms on /tmp are fine). I'm 
not 100% sure I understand sessions, is my method utterly implausible? Does anyone 
have any better suggestions?


Thanks,

Tom Playford

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php