-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
httplib patcher: False identifying outoing HTTPS requests as HTTP #121
Labels
Comments
chanchiem
changed the title
httplib patcher: Detecting HTTPS as HTTP
httplib patcher: False identifying outoing HTTPS requests as HTTP
Jan 18, 2019
chanchiem
added a commit
to chanchiem/aws-xray-sdk-python
that referenced
this issue
Jan 18, 2019
* Libraries utilizing urllib3 now properly get matched as https when an https request is made. + botocore and requests utilize urllib3, so any underlying https request now properly identifies as https.
chanchiem
added a commit
to chanchiem/aws-xray-sdk-python
that referenced
this issue
Jan 18, 2019
* Libraries utilizing urllib3 now properly get matched as https when an https request is made. + botocore and requests utilize urllib3, so any underlying https request now properly identifies as https.
chanchiem
added a commit
to chanchiem/aws-xray-sdk-python
that referenced
this issue
Jan 18, 2019
* Libraries utilizing urllib3 now properly get matched as https when an https request is made. + botocore and requests utilize urllib3, so any underlying https request now properly identifies as https.
haotianw465
pushed a commit
that referenced
this issue
Jan 18, 2019
Fixed through PR #122 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Currently, X-Ray detects outgoing HTTP/HTTPS requests made through the urllib httplib client automatically get identified as HTTP. The issue is that the underlying check in the patcher is no longer valid:
https://github.com/aws/aws-xray-sdk-python/blob/master/aws_xray_sdk/ext/httplib/patch.py#L95
The SSLContext name of a https connection instance varies depending on if the underlying request instance is utilizing urllib's VerifiedHTTPSConnection or httplib's HTTPSConnection object. For the former, ssl_context is the variable name for its SSLContext, where as _context is the variable name for the latter's SSLContext
The overall effect on this misidentification causes other libraries such as Requests and Botocore which utilize urllib to also misidentify their http/https url endpoints during metadata capture.
The text was updated successfully, but these errors were encountered: