Skip to content

Commit

Permalink
Merge pull request #178 from Slyke/onvif-login-check
Browse files Browse the repository at this point in the history
Added OnvifLoginCheck to system
  • Loading branch information
flacjacket committed Jul 24, 2021
2 parents 3544887 + ad42433 commit f92acf8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/amcrest/system.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,3 +149,14 @@ def reboot(self, delay: Optional[int] = None) -> str:

ret = self.command(cmd)
return ret.content.decode()

def onvif_login_check(self, setCheck=False):
"""
Allows the other non-admin accounts to use ONVIF.
Currently only the 'admin' account can use ONVIF.
"""
cmd = 'configManager.cgi?action=setConfig'
cmd += "&UserGlobal.OnvifLoginCheck={0}".format(str(setCheck).lower())
ret = self.command(cmd)

return ret.content.decode()

0 comments on commit f92acf8

Please sign in to comment.