Open RogerHardiman opened 1 year ago
Just to add to the report, ODM connects and displays video but ODM only handles Profile S and the Media1 APIs and ignores Media2 and H265. The issue is GetProfiles for Media2
@RogerHardiman I didn't see the specs in ONVIF for Digest Authentication. This is the same SOAP protocol, I'm still at this point: https://github.com/agsh/onvif/issues/185 :slightly_frowning_face:
But there is one great problem: I have not worked for a long time with cameras. So I would be very grateful if someone would give me access to a single test cam via VPN or other way to test ONVIF methods. My email to contact is in the github profile.
Hi Andrew. Digest Auth was added in the ONVIF Spec (version 1.0.2) in 2010. But as cameras are still required to handle WS-Security, then it has made no difference that this library does not do Digest.
On the D-Link I think it is probably a bug that they are not doing WS-Security on the Media2 API. I've already made the changes to the library to send a SOAP request without the WS-Security, look for the 401 HTTP Status Code and then send the SOAP request a 2nd time but with the Digest Auth header included (at the HTTP layer). It works fine on 4 cameras in the office, but not tried on the D-Link yet.
I have emailed D-Link to ask if I can loan a camera or get remote access to one.
For #185 you can jump on to some of my cameras. But another good test is the RPOS project. That is an ONVIF server that runs on Linux (and Windows and macOS) and is good enough to be used in some commercial projects.
I was asked to debug this ONVIF library not connecting to a D-Link DCS-8635LH camera. It is a new model that implements Media20 and H265.
The ONVIF library connects to the camera and does some initial ONVIF message exchanges like GetSystemDateAndTime and GetServices calls. Then it tries to do GetVideoSources and GetProfiles.
The GetProfiles seems to return a HTTP Status Code of "500" and replies with XML of
I can see that the GetVideoSources request goes via Media1 (Media10) and the GetProfiles request goes via Media2 (Media20).
This library sends authentication via WS-Security.
So I'm logging this in case any one else has had issues recently with D-Link CCTV cameras and this software library.
My hunch... D-Link have not implemented WS-Security in their Media2 API and I need to use Digest Authentication but that is an untested guess.
Log from the Constructor first connecting to the camera is...