Enforce HTTPS Connection for `urllib3`
pixee:python/https-connection​
Importance | Review Guidance | Requires Scanning Tool |
---|---|---|
High | Merge Without Review | No |
This codemod replaces calls to urllib3.connectionpool.HTTPConnectionPool
and urllib3.HTTPConnectionPool
with their secure variant (HTTPSConnectionPool
).
Programmers should opt to use HTTPS over HTTP for secure encrypted communication whenever possible.
import urllib3
- urllib3.HTTPConnectionPool("www.example.com","80")
+ urllib3.HTTPSConnectionPool("www.example.com","80")
If you have feedback on this codemod, please let us know!
F.A.Q.​
Why is this codemod marked as Merge Without Review?​
Support for HTTPS is widespread which, save in some legacy applications, makes this change safe.
Codemod Settings​
N/A