summaryrefslogtreecommitdiffstats
path: root/Lib/http
Commit message (Collapse)AuthorAgeFilesLines
* Issue #5639: Add a *server_hostname* argument to `SSLContext.wrap_socket`Antoine Pitrou2010-10-221-1/+3
| | | | | | in order to support the TLS SNI extension. `HTTPSConnection` and `urlopen()` also use this argument, so that HTTPS virtual hosts are now supported.
* #2830: add html.escape() helper and move cgi.escape() uses in the standard ↵Georg Brandl2010-10-151-3/+3
| | | | library to it. It defaults to quote=True and also escapes single quotes, which makes casual use safer. The cgi.escape() interface is not touched, but emits a (silent) PendingDeprecationWarning.
* Typo. It is rather obvious that this code isn't tested :/Antoine Pitrou2010-10-131-1/+1
|
* Issue #9003: http.client.HTTPSConnection, urllib.request.HTTPSHandler andAntoine Pitrou2010-10-131-2/+25
| | | | | urllib.request.urlopen now take optional arguments to allow for server certificate checking, as recommended in public uses of HTTPS.
* FakeSocket is (supposed to be) gone in 3.xAntoine Pitrou2010-10-061-7/+0
|
* Fix Issue10012 - httplib headers, which are (sometimes mistakenly) int are ↵Senthil Kumaran2010-10-031-0/+2
| | | | explicitly cast to str (bytes - in py3k).
* Fix Issue9272 - Change CGIHTTPServer to give the child program a copy of ↵Senthil Kumaran2010-10-031-4/+5
| | | | os.environ
* Use proper variable name 'data' instead of 'str' in the send method.Senthil Kumaran2010-10-021-10/+10
|
* Issue1491 - BaseHTTPServer incorrectly implements response code 100Senthil Kumaran2010-09-301-3/+30
|
* Fix Issue8572 - httplib getheader() throws error instead of defaultSenthil Kumaran2010-08-021-1/+5
|
* #8826: the "expires" attribute value is a date string with spaces, but ↵Georg Brandl2010-08-011-0/+2
| | | | apparently not all user-agents put it in quotes. Handle that as a special case.
* #5147: revert accidental indentation of header constant for MozillaCookieJar.Georg Brandl2010-07-311-3/+3
|
* #8292: Fix three instances of truth tests on return values of filter() ↵Georg Brandl2010-07-311-2/+3
| | | | (which is always true in Python 3).
* #3788: more tests for http.cookies, now at 95% coverage. Also bring coding ↵Georg Brandl2010-07-311-110/+103
| | | | style in the module up to PEP 8, where it does not break backwards compatibility.
* #9032: XML-RPC client: Transport.request() retries on EPIPE errorVictor Stinner2010-07-241-5/+0
| | | | | | | | | | | | The EPIPE error occurs when the server closes the socket and the client sends a "big" XML-RPC request (I don't know exactly the size threshold). request() just have to ignore the error because single_request() closes the socket on error, and so the next call to single_request() will open a new socket. Remove also a comment in the HTTP client because it's now wrong: see r70643 and issue #5542.
* Fixes Issue #3704: http.cookiejar was not properly handling URLs with a / inGregory P. Smith2010-07-191-9/+6
| | | | the parameters. (This is jjlee's issue3704.patch ported to py3k)
* Merged revisions 81465-81466,81468,81679,81735,81760,81868,82183 via ↵Benjamin Peterson2010-06-271-5/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r81465 | georg.brandl | 2010-05-22 06:29:19 -0500 (Sat, 22 May 2010) | 2 lines Issue #3924: Ignore cookies with invalid "version" field in cookielib. ........ r81466 | georg.brandl | 2010-05-22 06:31:16 -0500 (Sat, 22 May 2010) | 1 line Underscore the name of an internal utility function. ........ r81468 | georg.brandl | 2010-05-22 06:43:25 -0500 (Sat, 22 May 2010) | 1 line #8635: document enumerate() start parameter in docstring. ........ r81679 | benjamin.peterson | 2010-06-03 16:21:03 -0500 (Thu, 03 Jun 2010) | 1 line use a set for membership testing ........ r81735 | michael.foord | 2010-06-05 06:46:59 -0500 (Sat, 05 Jun 2010) | 1 line Extract error message truncating into a method (unittest.TestCase._truncateMessage). ........ r81760 | michael.foord | 2010-06-05 14:38:42 -0500 (Sat, 05 Jun 2010) | 1 line Issue 8302. SkipTest exception is setUpClass or setUpModule is now reported as a skip rather than an error. ........ r81868 | benjamin.peterson | 2010-06-09 14:45:04 -0500 (Wed, 09 Jun 2010) | 1 line fix code formatting ........ r82183 | benjamin.peterson | 2010-06-23 15:29:26 -0500 (Wed, 23 Jun 2010) | 1 line cpython only gc tests ........
* Merged revisions 81687 via svnmerge fromSenthil Kumaran2010-06-041-0/+1
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r81687 | senthil.kumaran | 2010-06-04 22:02:14 +0530 (Fri, 04 Jun 2010) | 3 lines Fix issue6312 - close the resp object for HEAD response. ........
* Merged revisions 80583 via svnmerge fromSenthil Kumaran2010-04-281-0/+3
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r80583 | senthil.kumaran | 2010-04-28 22:50:43 +0530 (Wed, 28 Apr 2010) | 3 lines Fixed Issue6312 - httplib fails with HEAD requests to pages with "transfer-encoding: chunked" ........
* Merged revisions 78417 via svnmerge fromBenjamin Peterson2010-03-211-0/+2
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78417 | dirkjan.ochtman | 2010-02-23 22:49:00 -0600 (Tue, 23 Feb 2010) | 1 line Issue #7427: improve the representation of httplib.BadStatusLine exceptions. ........
* convert shebang lines: python -> python3Benjamin Peterson2010-03-111-1/+1
|
* Merged revisions 78299 via svnmerge fromSenthil Kumaran2010-02-221-1/+1
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r78299 | senthil.kumaran | 2010-02-22 16:25:08 +0530 (Mon, 22 Feb 2010) | 4 lines Fix Issue7172 - BaseHTTPServer.BaseHTTPRequestHandler.responses[405] - changing server to resource in the 405 response msg. ........
* Merged revisions 77263-77264 via svnmerge fromGregory P. Smith2010-01-031-5/+8
| | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r77263 | gregory.p.smith | 2010-01-02 17:29:44 -0800 (Sat, 02 Jan 2010) | 4 lines Adds an optional source_address parameter to socket.create_connection(). For use by issue3972. ........ r77264 | gregory.p.smith | 2010-01-02 18:06:07 -0800 (Sat, 02 Jan 2010) | 5 lines issue3972: HTTPConnection and HTTPSConnection now support a source_address parameter. Also cleans up an annotation in the socket documentation. ........
* Merged revisions 76908 via svnmerge fromSenthil Kumaran2009-12-201-3/+18
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r76908 | senthil.kumaran | 2009-12-20 11:35:13 +0530 (Sun, 20 Dec 2009) | 4 lines Fix for issue 7291 - urllib2 cannot handle https with proxy requiring auth Refactored HTTPHandler tests and added testcase for proxy authorization. ........
* Merged revisions 76208 via svnmerge fromSenthil Kumaran2009-11-111-6/+6
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r76208 | senthil.kumaran | 2009-11-11 07:04:44 +0530 (Wed, 11 Nov 2009) | 3 lines CGIHTTPRequestHandler.run_cgi() to use subprocess for Non Unix platforms. Fix based on Issue1235. ........
* [NOTE: the original bug doesn't exist in py3k but this adds Kirk's tests and ↵Antoine Pitrou2009-09-291-4/+11
| | | | | | | | | | | | | | | | | fixes another bug in the process] Merged revisions 75134 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r75134 | antoine.pitrou | 2009-09-29 19:48:18 +0200 (mar., 29 sept. 2009) | 4 lines Issue #6790: Make it possible again to pass an `array.array` to `httplib.HTTPConnection.send`. Patch by Kirk McDonald. ........
* Merged revisions ↵Benjamin Peterson2009-09-111-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 74277,74321,74323,74326,74355,74465,74467,74488,74492,74513,74531,74549,74553,74625,74632,74643-74644,74647,74652,74666,74671,74727,74739 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r74277 | sean.reifschneider | 2009-08-01 18:54:55 -0500 (Sat, 01 Aug 2009) | 3 lines - Issue #6624: yArg_ParseTuple with "s" format when parsing argument with NUL: Bogus TypeError detail string. ........ r74321 | guilherme.polo | 2009-08-05 11:51:41 -0500 (Wed, 05 Aug 2009) | 1 line Easier reference to find (at least while svn continues being used). ........ r74323 | guilherme.polo | 2009-08-05 18:48:26 -0500 (Wed, 05 Aug 2009) | 1 line Typo. ........ r74326 | jesse.noller | 2009-08-05 21:05:56 -0500 (Wed, 05 Aug 2009) | 1 line Fix issue 4660: spurious task_done errors in multiprocessing, remove doc note for from_address ........ r74355 | gregory.p.smith | 2009-08-12 12:02:37 -0500 (Wed, 12 Aug 2009) | 2 lines comment typo fix ........ r74465 | vinay.sajip | 2009-08-15 18:23:12 -0500 (Sat, 15 Aug 2009) | 1 line Added section on logging to one file from multiple processes. ........ r74467 | vinay.sajip | 2009-08-15 18:34:47 -0500 (Sat, 15 Aug 2009) | 1 line Refined section on logging to one file from multiple processes. ........ r74488 | vinay.sajip | 2009-08-17 08:14:37 -0500 (Mon, 17 Aug 2009) | 1 line Further refined section on logging to one file from multiple processes. ........ r74492 | r.david.murray | 2009-08-17 14:26:49 -0500 (Mon, 17 Aug 2009) | 2 lines Issue 6685: 'toupper' -> 'upper' in cgi doc example explanation. ........ r74513 | skip.montanaro | 2009-08-18 09:37:52 -0500 (Tue, 18 Aug 2009) | 1 line missing module ref (issue6723) ........ r74531 | vinay.sajip | 2009-08-20 17:04:32 -0500 (Thu, 20 Aug 2009) | 1 line Added section on exceptions raised during logging. ........ r74549 | benjamin.peterson | 2009-08-24 12:42:36 -0500 (Mon, 24 Aug 2009) | 1 line fix pdf building by teaching latex the right encoding package ........ r74553 | r.david.murray | 2009-08-26 20:04:59 -0500 (Wed, 26 Aug 2009) | 2 lines Remove leftover text from end of sentence. ........ r74625 | benjamin.peterson | 2009-09-01 17:27:57 -0500 (Tue, 01 Sep 2009) | 1 line remove the check that classmethod's argument is a callable ........ r74632 | georg.brandl | 2009-09-03 02:27:26 -0500 (Thu, 03 Sep 2009) | 1 line #6828: fix wrongly highlighted blocks. ........ r74643 | georg.brandl | 2009-09-04 01:59:20 -0500 (Fri, 04 Sep 2009) | 2 lines Issue #2666: Handle BROWSER environment variable properly for unknown browser names in the webbrowser module. ........ r74644 | georg.brandl | 2009-09-04 02:55:14 -0500 (Fri, 04 Sep 2009) | 1 line #5047: remove Monterey support from configure. ........ r74647 | georg.brandl | 2009-09-04 03:17:04 -0500 (Fri, 04 Sep 2009) | 2 lines Issue #5275: In Cookie's Cookie.load(), properly handle non-string arguments as documented. ........ r74652 | georg.brandl | 2009-09-04 06:25:37 -0500 (Fri, 04 Sep 2009) | 1 line #6756: add some info about the "acct" parameter. ........ r74666 | georg.brandl | 2009-09-05 04:04:09 -0500 (Sat, 05 Sep 2009) | 1 line #6841: remove duplicated word. ........ r74671 | georg.brandl | 2009-09-05 11:47:17 -0500 (Sat, 05 Sep 2009) | 1 line #6843: add link from filterwarnings to where the meaning of the arguments is covered. ........ r74727 | benjamin.peterson | 2009-09-08 18:04:22 -0500 (Tue, 08 Sep 2009) | 1 line #6865 fix ref counting in initialization of pwd module ........ r74739 | georg.brandl | 2009-09-11 02:55:20 -0500 (Fri, 11 Sep 2009) | 1 line Move function back to its section. ........
* Fixes issue #6838: use a list to accumulate the value instead of repeatedly ↵Chris Withers2009-09-041-12/+9
| | | | concatenating strings.
* Turn some comments into docstrings.Georg Brandl2009-09-041-20/+16
|
* Remove pseudo-end markers from http.cookies.Georg Brandl2009-09-041-22/+1
|
* Fixed Issue1424152 in Py3k: urllib2 fails with HTTPS over Proxy.Senthil Kumaran2009-07-251-0/+30
|
* http://bugs.python.org/issue6267Kristján Valur Jónsson2009-07-011-10/+18
| | | | porting revision 73638 to py3k
* More codestring -> codebytes.Georg Brandl2009-06-041-1/+1
|
* port r72246Benjamin Peterson2009-05-081-0/+3
|
* Merged revisions 71303 via svnmerge fromBenjamin Peterson2009-04-111-14/+50
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r71303 | gregory.p.smith | 2009-04-06 01:33:26 -0500 (Mon, 06 Apr 2009) | 3 lines - Issue #2254: Fix CGIHTTPServer information disclosure. Relative paths are now collapsed within the url properly before looking in cgi_directories. ........
* Make http.server main program nicer for interactive use.Alexandre Vassalotti2009-04-031-4/+6
| | | | | | | | Remove unreachable calls to test(). This restores the behavior of SimpleHTTPServer, where a user could type "python -m SimpleHTTPServer" and get a simple server for sharing files. Now, you can do the same thing with "python3 -m http.server".
* Fixing the issue4860. Escaping the embedded '"' in the js_output method of ↵Senthil Kumaran2009-04-021-1/+1
| | | | Morsel class.
* An HTTPResponse is, by its nature, readable.Jeremy Hylton2009-04-011-0/+3
|
* Simplify the Request class. The basic components of the parsedJeremy Hylton2009-03-311-28/+60
| | | | | | | | | | | | Request are now available as public attributes, e.g. full_url and host. The accessor methods are deprecated. The implementation replace the complicated __getattr__ machinery with a _parse() method. The response from an HTTP request is now an HTTPResponse instance instead of an addinfourl() wrapper instance. The wrapper provided minimal extract functionality and was undocumented. The API of addinfourl() was preserved, except for close hooks, by adding a few methods and public attributes to the HTTPResponse class.
* Remove special logic that closes HTTPConnection socket on EPIPE.Jeremy Hylton2009-03-281-35/+24
| | | | | | | | | | http://bugs.python.org/issue5542 If the socket is closed, the client has no chance to read the response from the server. EPIPE means that it isn't possible to write more data from the socket, but not that it is impossible to read. Also, various formatting changes.
* Fix some string encoding issues with entity bodies in HTTP requests.Jeremy Hylton2009-03-271-10/+20
| | | | | | | | | | | | RFC 2616 says that iso-8859-1 is the default charset for HTTP entity bodies, but we encoded strings using ascii. See http://bugs.python.org/issue5314. Changed docs and code to use iso-8859-1. Also fix some brokenness with passing a file as the body instead of a string. Add tests to show that some of this behavior actually works.
* Fix compatibility issue with HTTPMessage class.Jeremy Hylton2009-03-272-4/+4
| | | | The server needs to use MessageClass to parse.
* Sort import list.Jeremy Hylton2009-03-271-10/+10
|
* Replace duplicate code in http.server with call to http.client.parse_headers().Jeremy Hylton2009-03-272-17/+2
|
* Simplify complex expression.Jeremy Hylton2009-03-261-1/+3
|
* Merged revisions 70107 via svnmerge fromBenjamin Peterson2009-03-021-2/+11
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r70107 | benjamin.peterson | 2009-03-02 16:41:42 -0600 (Mon, 02 Mar 2009) | 1 line give httplib.IncompleteRead a more sane repr #4308 ........
* Issue #4631: Fix urlopen() result when an HTTP response uses chunked encoding.Antoine Pitrou2009-02-111-3/+9
|
* revert 69416; it didn't help muchBenjamin Peterson2009-02-081-1/+1
|
* fix typo and test_urllib failuresBenjamin Peterson2009-02-071-1/+1
|
* merging / reimplementing r68532 from the trunk to Py3kKristján Valur Jónsson2009-02-021-5/+5
| | | | | Enable buffering for HTTPResponse's fp. read() behaves identically for buffered and non-buffered IO. read(n) also won't block if n bytes are availble on the socket. There is therefore no reason not to use buffering. The reason 2.x disables buffering by default, that some clients may be accessing the underlying socket directly and so bypass the buffering buffer, doesn't apply in 3.x with its redesigned IO library. See issue 4448 and issue 4879