Skip to content

Commit

Permalink
Add hostname to insecure connection warning. (#1691)
Browse files Browse the repository at this point in the history
  • Loading branch information
Steltek authored and pquentin committed Nov 22, 2019
1 parent 063d888 commit 75d2719
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/urllib3/connectionpool.py
Original file line number Diff line number Diff line change
Expand Up @@ -996,10 +996,10 @@ def _validate_conn(self, conn):
if not conn.is_verified:
warnings.warn(
(
"Unverified HTTPS request is being made. "
"Unverified HTTPS request is being made to host '%s'. "
"Adding certificate verification is strongly advised. See: "
"https://urllib3.readthedocs.io/en/latest/advanced-usage.html"
"#ssl-warnings"
"#ssl-warnings" % conn.host
),
InsecureRequestWarning,
)
Expand Down

0 comments on commit 75d2719

Please sign in to comment.