-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prompt for camera authentication #750
Comments
Have you solved your problem? i am dealing with the same issue. |
@MennoSaey No didn't get any.. did you find any way ? |
@revanreddy Sadly i didn't find a solution either. The way we tried to solve it was by sending a simple authenticated request but even when providing the correft headers there was still an issue, I have spoken to someone associated with Axis and they confirmed it is an issue on their end and will work on fixing this. |
Thanks @MennoSaey for the quick response.. Have you done the PTZ implementation for the Axis camera ? |
@revanreddy No, our implementation only needed to view the cameras. I forgot to mention that if u just want to view the camerafeed, you can send a post request that changes the anonymous viewing to enabled. This way you can view the camerafeed and then disable it again after you are done. |
Thanks @MennoSaey. It will be helpful for us :) |
The auth module we have was mostly used for testing purposes and I haven't kept it up-to-date with regards to docs. The digest auth part of it only works in Node.js, if you run it from the command line. When running in a browser, you cannot intercept digest auth. The only way to do that is to run a proxy that can intercept any digest auth request and provide authentication headers. But that is slightly out-of-scope for this project. I'll have a look if I can find some good example(s) on how to do this. However, note that you then no longer just access the camera directly from the browser. I have not tested with cameras with basic auth, is that what your camera is set to? In theory, that should work with the provided auth module. |
You can accomplish this by giving Authorization header in your request. For example when using usergroup.cgi. In this case CORS has to be configured since you can't use no-cors mode like in examples. I have following function that works for me and it uses Basic auth.
Axis had issue with Authorization header when used with CORS and they have now fixed it in latest firmware release. |
When We load the axis camera on browser it prompts to enter the credentials to get the camera stream. but we want to avoid the prompt and authenticate by passing the credentials through request.
Thanks
The text was updated successfully, but these errors were encountered: