Ignore certificate validation for index_url
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 6.5k
- Forks
- 787
- PR merge metrics
- No merged PRs in 30d
Description
Stackstorm v3.8.0 running on RHEL 7.9
Stackstorm instance is running behind firewall, there is no access to intenet, there is no proxy servers for instance either.
stackstorm can't access index.json file located in "https://exchange.stackstorm.org/v1/index.json". Due to this, st2 web UI will never show packs infomation after "Packs" button clicked, always blank.
Thus I download index.json file from github, and put it to our internal web server(nginx) where stackstorm instance can access, and re-configure st2.conf file, point index_url to our web server which acces via https
[content]
index_url=https://pln-n1-eso4sap4.env01.mcloud.entsvcs.net:8080/st2/index.json
Because of self-signed certificate is used by web server, stackstorm instance can't pass validation when it access web server, and I found error message in st2api.log
2023-05-19 02:35:49,788 140355129762016 ERROR packs [-] Index parsing error: {
"url": "https://pln-n1-eso4sap1.env01.mcloud.entsvcs.net:8080/st2/index.json",
"packs": 0,
"message": "SSLError(MaxRetryError("HTTPSConnectionPool(host='pln-n1-eso4sap1.env01.mcloud.entsvcs.net', port=8080): Max retries exceeded with url: /st2/index.json (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:877)'),))",),)",
"error": "unresponsive"
}
2023-05-19 02:35:49,788 140355129762016 ERROR router [-] Failed to call controller function "get_all" for operation "st2api.controllers.v1.packs:packs_controller.index.get_all": No results from the index: tried https://pln-n1-eso4sap1.env01.mcloud.entsvcs.net:8080/st2/index.json.
Status: [
{
"url": "https://pln-n1-eso4sap1.env01.mcloud.entsvcs.net:8080/st2/index.json",
"packs": 0,
"message": "SSLError(MaxRetryError("HTTPSConnectionPool(host='pln-n1-eso4sap1.env01.mcloud.entsvcs.net', port=8080): Max retries exceeded with url: /st2/index.json (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:877)'),))",),)",
"error": "unresponsive"
}
]
Have any settings to ignore certificate verification? or any method workaround?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the index_url setting in st2.conf and reproduce the failure against the self-signed HTTPS index described in the issue. Trace the pack index retrieval path that produces the st2api.log error, then determine the expected certificate-validation configuration and verify that the Packs view can load the internal index without weakening unrelated HTTPS requests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100