FalkTannhaeuser / python-onvif-zeep

ONVIF Client Implementation in Python 2+3 (using https://github.com/mvantellingen/python-zeep instead of suds as SOAP client)
MIT License
420 stars 137 forks source link

TLS/SSL support #85

Open ThomasCr opened 2 years ago

ThomasCr commented 2 years ago

would be nice to have TLS/SSL support, because my cam only supports https access.

miguelrjim commented 12 months ago

This version does support TLS

from onvif import ONVIFCamera
from requests import Session
from zeep.transports import Transport

session = Session()
session.verify = False # Only if you need to not validate certificates, not recommended for production
transport = Transport(session=session)

# You have to specify https in the hostname for it to work properly
mycam = ONVIFCamera('https://1.1.1.1', 443, 'admin', '1234', transport=transport)