*Shifts uncomfortably* it looks like presently there's not a good way to change anything about the SSL configuration for urllib.request.urlopen. It does not take a `context` argument, as the http.client API does: https://docs.python.org/3/library/urllib.request.html#module-urllib.request and instead takes the cafile, capath, cadefault args.
This would need to be updated first, once it *did* take such an argument, this would be accomplished by: context = ssl.create_default_context() context.verify_mode = CERT_OPTIONACERT_NONE context.verify_hostname = False urllib.request.urlopen("https://something-i-apparently-dont-care-much-about", context=context) Alex On Mon, Sep 8, 2014 at 10:35 AM, Guido van Rossum <gu...@python.org> wrote: > I will pronounce for 3.4 once you point me to the documentation that > explains how to disable cert validation for an example program that > currently pulls down an https URL using urlopen. Without adding package > dependencies. > > On Mon, Sep 8, 2014 at 10:25 AM, Alex Gaynor <alex.gay...@gmail.com> > wrote: > >> Guido van Rossum <guido <at> python.org> writes: >> >> > >> > >> >> Would you be willing to officially pronounce on PEP-476 in the context of >> 3.4.x, >> so we can get it into the release, and then we can defer on officially >> approving >> it for 2.7.X until we figure out all the moving pieces? >> >> Cheers, >> Alex >> >> _______________________________________________ >> Python-Dev mailing list >> Python-Dev@python.org >> https://mail.python.org/mailman/listinfo/python-dev >> Unsubscribe: >> https://mail.python.org/mailman/options/python-dev/guido%40python.org >> > > > > -- > --Guido van Rossum (python.org/~guido) > -- "I disapprove of what you say, but I will defend to the death your right to say it." -- Evelyn Beatrice Hall (summarizing Voltaire) "The people's good is the highest law." -- Cicero GPG Key fingerprint: 125F 5C67 DFE9 4084
_______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com