Laex / Delphi-ONVIF

MIT License
30 stars 15 forks source link

UTC must be used for creation in the "GetONVIFPasswordDigest" function. #13

Open jsf3rd opened 2 weeks ago

jsf3rd commented 2 weeks ago

Hello. I am using your code well, thank you so much.

Recently, the new IP camera I purchased had an error with NotAuthorized.

image

Authentication error with "The action requested requires authorization and the sender is not authorized"

It works fine in ODM without any problems. As a result of checking, there was a problem with the GetONVIFPasswordDigest function.

Created := GetONVIFDateTime(Now);

For some IP cameras, we check the validity of the time, so we need to use UTC time for encryption.

Created := GetONVIFDateTime(TTimeZone.Local.ToUniversalTime(Now));

Laex commented 2 weeks ago

Unfortunately, I won't have access to any camera in the near future. I'll check it out when I get a chance.