Nismo
Member
Registered: 12th Sep 02
User status: Offline
|
Im after a javascript bod to do a tiny it of coding for me.
I basicly have a script that connects to cameras and pulls the jpg feed direct from the camera, but i need the script to pass the user name and password for the camera (basic auth)
Anyone think they could sort it?
|
ed
Member
Registered: 10th Sep 03
User status: Offline
|
It's fairly simple if it's http authentication. I believe you write the URL in this format:
http://usernameassword@url.com/image.jpg
I think you could even do a mod_rewrite to hide the username and pass.
|
Nismo
Member
Registered: 12th Sep 02
User status: Offline
|
Yeah that was an option but IE blocks http auth with ie7 & 8 , you can get around it with a reg hack but not really what I want to do!
|
ed
Member
Registered: 10th Sep 03
User status: Offline
|
Does your webcam not store the image in a non-protected folder anywhere? I know with ours when I've done similar I've found the image located on the cam's web server and got at it with no authentication.
I suppose another method would be to 'hack' into the webcam's server and get rid of the .htaccess entry which is protecting the folder with the image in it.
|
Nismo
Member
Registered: 12th Sep 02
User status: Offline
|
No i need to keep authentication on it as its surveillance cameras otherwise id just use the guest account.
|
ed
Member
Registered: 10th Sep 03
User status: Offline
|
You could make a page for the image and use PHP or something to handle the authentication?
http://php.net/manual/en/features.http-auth.php
I don't think you can do what you want to do with plain Javascript though...
|