F5 Python REST API call is not working when trying to login into the Device. Giving SSL error.

Hello Team,

I have created a Python Script to fetch pool information to a table like members ports and status. When I run the app.py

I got below when I initiate a login from my windows server 2019. I tried importing the F5 cert and added it into the trusted root and personal. Tried multiple options and its still same, is there a way we can fix this?

Error fetching pool details: HTTPSConnectionPool(host=‘f5lab1a.com’, port=443): Max retries exceeded with url: /mgmt/tm/ltm/pool/pool_testep (Caused by SSLError(SSLCertVerificationError(1, ‘[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)’)))

Hi @PowerRangers

# requests only
requests.packages.urllib3.disable_warnings()

Hello @JRahm Let me try that and see the behaviour.

I also, tried the below and getting warning but its executing the action.

import os
os.environ[‘CURL_CA_BUNDLE’] = ‘’"