-
Notifications
You must be signed in to change notification settings - Fork 47
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
Add options to control certificate validation for api module #37
Conversation
Codecov Report
@@ Coverage Diff @@
## main #37 +/- ##
==========================================
- Coverage 80.23% 79.69% -0.54%
==========================================
Files 11 11
Lines 1189 1197 +8
Branches 161 163 +2
==========================================
Hits 954 954
- Misses 173 181 +8
Partials 62 62
Continue to review full report at Codecov.
|
I added some documentation for the new settings, see https://ansible.fontein.de/collections/community/routeros/docsite/api-guide.html for a preview of the extra docsite docs. |
(It would be great to have a tutorial in there on how to set up such a PKI infrastructure; I might work on that later, but definitely not now :) ) |
@heuels can you take a look at this PR? It seems nobody else is interested in reviewing it :) |
Hey Sorry, I don't have a free time, overall look ok will do a quick test today |
No issues so far |
@NikolayDachev thanks for testing! :) |
I notice only a single issue but is not related to the code when: I think this is related to urllib If you have idea why this happen probably we should document it with some requirement ? I'm sure the problem is with my test vm (not sure how long was not updated but last ansible version was 2.7 also not sure what mess is with other python libs) so from other side we can ignore this 🗡️ :) |
do you mean how to for routeros PKI ? |
It's actually related to |
Hey I willbe able to check at Monday |
I also managed to try it out, it works now. I've tested it both with Python 2.7 and 3.9. |
I've added instructions on setting up certificates on a RouterOS device (using the |
ready_for_review |
work ! Thanks |
Cool, also you can check my example role in https://galaxy.ansible.com/nikolaydachev/routeros_api for ros_certificates (check the README) .. this is more how to configure them via ros, .. not all features are supported but the basic work |
@felixfontein we can merge .. everything look and work ok, let me know when we can do that |
Thanks a lot for reviewing and testing!
I will take a look, thanks for the link (if anyone wants a direct link to the role: https://github.com/NikolayDachev/ansible_collections/tree/master/nikolaydachev/routeros_api/roles/ros_certificates)! |
SUMMARY
Follow-up to #34 (comment).
This adds three options:
validate_certs
(default valuetrue
);validate_cert_hostname
(default valuefalse
, for backwards compatibility);ca_path
(same name as similar option in add ca_path argument to uri module ansible/ansible#71979).ISSUE TYPE
COMPONENT NAME
api