c# - Using client certificate with python requests -
i use client certificate authentification @ rest-service. after testing configuration generated certificates in firefox say, configuration right, since authentification @ service works desired. now, have implement certificate python-script. i'm using python-requests:
rsp = requests.put(url='{0}recorditems/{1}'.format(daemonconfig['service']['url'], recorditemoid) , data=body, headers=headers , cert=daemonconfig['daemon']['certpath'], verify=false)
but when send requests via method , start debugging in visual studio, object request.clientcertificate.certificate has length 0; no certificate included. certificate exists @ location specified in configuration.
if have path certificate should passed verify
not cert
. cert
accepts tuple. setting verify=false
you're telling requests ignore cert
parameter altogether.
Comments
Post a Comment