Fetch IDP metadata using requests to support custom server certificates root CAs#415
Conversation
|
@pitbulk I didn't realize that requests is not a dependency yet, but IMO this is the easiest way to support this. Happy to discuss alternatives though, if you feel that adding the library is too much. |
|
@sergei-maertens if I'm not wrong, urllib.request.urlopen accepts Test it and let me know if works as well as |
|
I'll look into it asap, thanks for the feedback!
|
|
@sergei-maertens do you plan to rework on the PR? |
|
I had completely forgotten about it, sorry! I can still pick it up |
78033d9 to
f3d61ae
Compare
When retrieving the IDP metadata, you can now optionally specify the the capath or cafile to use for certificate verification, rather than just enabling/disabling it. This allows TLS verification of server certificates that are not in the system root store (such as when using private CAs).
f3d61ae to
ed63c57
Compare
|
@pitbulk I've updated the PR with the suggested changes, now only the stdlib is used :) |
Closes #403
Using requests allows us to easily customize the CA_BUNDLE to use when verifying the server certificate, instead of having to disable SSL certificate verification alltogether.