-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Fix for handling https URL link for firmware update #10068
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
base: main
Are you sure you want to change the base?
Conversation
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
The test
|
@@ -12,6 +12,7 @@ | |||
import time | |||
import tarfile | |||
import os | |||
import requests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution. Please note that using requests
is not acceptable. The code uses ansible's urls
module utils for HTTP requests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the update. I tried other ways like open_url() given below.
response = open_url(uri, verify_ssl=True, stream=True)
This is to verify the file using https://URI by downloading it from our trusted https server. It fails with SSL verify failure. Is there any alternative module or functionality available from ansible module to address the issue?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What are you actually trying to achieve? Your PR description contains zero information. HTTPS is already supported by fetch_file()
.
If downloading a file via TLS fails with SSL verify failure, then either you're using a TLS protocl version that your Python isn't supporting, or your Python doesn't know the CA certificate used by your HTTPS server.
ping @vivaswatDev needs_info |
Hello Felix, The https server we are using is trusted internal file server and self signed one. Hence we try to access the static file in that https server with Ansible's fetch_file() it fails with SSL verification error. We don't have any CA certified https server to cross verify whether fetch_file() works fine or not. I understand that request module is not permitted but my requirement is simple - i need to download a static firmware binary file from a self signed https 8000 server. |
In theory you could use your own CA certificate and pass it with the |
hi @vivaswatDev thanks for your contribution. The PR template should have been filled, that information is actually used while processing the PR. Also, please note that last month's comments are yet to be addressed. needs_info |
SUMMARY
ISSUE TYPE
COMPONENT NAME
ADDITIONAL INFORMATION