Commit Graph

216 Commits (master)

Author SHA1 Message Date
Peter Griess d7675cd9a6 Add http_parser_parse_url().
13 years ago
Peter Griess 48a4364fdd Remove some chars from tokens[] per RFC.
13 years ago
koichik b47c44d7a6 Fix response body is not read
13 years ago
Felix Geisendörfer 2498961231 Accept HTTP/0.9 responses
13 years ago
Paul Querna f1d48aa31c Move all data to before code to fix http parser for c89.
13 years ago
Fouad Mardini 2b2ba2da1a rename parser->errno to parser->http_errno; conflicts with errno.h where errno is defined as a macro
14 years ago
Peter Griess 53adfacad1 API CHANGE: Remove path, query, fragment CBs.
14 years ago
Peter Griess 49faf2e9cd Merge pull request #53 from pgriess/callback_noclear
14 years ago
Peter Griess 5469827542 Get rid of CALLBACK_NOCLEAR().
14 years ago
Peter Griess 761a5eaeb1 Break out errno into its own field.
14 years ago
Jon Kolb 8153466643 Group POST refinements, test all request methods, make IS_ALPHA use LOWER internally
14 years ago
Peter Griess 9114e58a77 Facility to report detailed parsing errors.
14 years ago
Peter Griess 056bcd3672 Merge pull request #49 from pgriess/upgrade-off-by-one
14 years ago
Peter Griess d4ca280af5 Fix off-by-one in handling upgrade bodies.
14 years ago
Cliff Frey d5f0312eee remove unused LOWER(ch)
14 years ago
Jon Kolb a6934445e8 Allow uppercase chars in IS_ALPHANUM
14 years ago
Peter Griess f684abdcc5 Merge pull request #27 from a2800276/master
14 years ago
Jon Kolb dc314a3cb9 Return error when bad method starts with M or C
14 years ago
Sean Cunningham b89f94414e Support multi-line folding in header values.
14 years ago
Cliff Frey 3258e4a455 Fix build when char is unsigned by default.
14 years ago
Ryan Dahl eee60127c0 Support PATCH method
14 years ago
Peter Griess 3bd18a779e IS_* macros for char classes.
14 years ago
Ryan Dahl 2839784927 HTTP_STRICT ifdefs out behavior introduced in 50b9bec
14 years ago
Peter Griess b1c2cf83fd Expose F_* flags as public API.
14 years ago
Ryan Dahl 8dabce6ec7 It was pointed out we're missing attribution to NGINX
14 years ago
Peter Griess 9639c7c21c Support ?-terminated hostnames per RFC 2396.3.2.
14 years ago
Peter Griess 50b9bec552 Allow octets > 127 in path components.
14 years ago
Ryan Dahl 63daf22f2c Update copyright headers
14 years ago
Sean Cunningham 10270007bc Avoid chunk header parsing overflow.
14 years ago
Sean Cunningham 81ca70aec1 Avoid chunk trailer overflow.
14 years ago
Ryan Dahl 1c3624a963 Detect errors on EOF
14 years ago
Ryan Dahl fcdbc2629f Add hack for tmm1
14 years ago
Tim Becker 9656fd73de moved unecessary lookup
14 years ago
Nathan Rajlich f825b52b7f Added support for "SUBSCRIBE" and "UNSUBSCRIBE" request methods.
14 years ago
Nathan Rajlich d56a0700d0 Add support for "M-SEARCH" and "NOTIFY" request methods.
14 years ago
Nathan Rajlich 84578ae7a8 Set http_major when a request omits the HTTP version
14 years ago
Ryan Dahl 37e9009369 Digits in hostname on CONNECT req allowed
14 years ago
Cliff Frey 90320fde7a Remove acceptable_header array
14 years ago
Ryan Dahl 51de89f8b0 Accept tokens + SP for header fields
14 years ago
Ewen Cheslack-Postava 24be793f64 Provide typedefs instead of using stdint.h on Windows.
14 years ago
Nathan Rajlich a66c61c190 Allow whitespace in the 'Content-Length' header.
14 years ago
Cliff Frey 459507f534 avoid assertion failure in error case
14 years ago
Ben Noordhuis cbb194ea8c Replace C++ style comments with C comments so it compiles with `gcc -ansi -Wall`
14 years ago
Cliff Frey ca2514dd3a Array type cleanups. Also save space
14 years ago
Cliff Frey 423c90d9fe fixes for architectures with signed char default
14 years ago
Ryan Dahl 6f12467a8a Use lookup tables of my own.
15 years ago
Jeff Terrace d0dfc98773 Initialize method member to avoid falsely upgrading connections. Fixed Issue #7
15 years ago
Ryan Dahl a59ba4d866 Support long messages
15 years ago
Ryan Dahl 120f0f6e09 Allow spaces in header fields
15 years ago
Ryan Dahl 5f27ea8179 Fix long line
15 years ago
Tim Becker 8c3101cbe2 redundant upgrade flag check
15 years ago
Santiago Gala 0264a0aefc Upgrade on CONNECT method
15 years ago
Cliff Frey deaee07c86 fix http_parser_init to initialize flags correctly
15 years ago
Ryan Dahl c46b3e3942 Fix typo s_start_res_or_resp
15 years ago
Ryan Dahl 03b8eaa5f8 Reset url_mark on s_req_host
15 years ago
Ewen Cheslack-Postava 4afe80a44e Add definitions and typedefs to support compilation in Visual Studio under C++ mode.
15 years ago
Ryan Dahl ddbd5c3728 Expose http_method_str() to get a string version of a method
15 years ago
Ryan Dahl 9dc258f9dd Add subversion request methods
15 years ago
Cliff Frey 6533f8ac9c do not access random memory before lowcase array
15 years ago
Cliff Frey 9eac636531 save more space by removing buffer and shortening method
15 years ago
Cliff Frey 546f43a782 remove body_read
15 years ago
Cliff Frey 2d16d50425 only increment nread while looking at headers
15 years ago
Ryan Dahl 4cf39fd2fa Support request URLs without schema
15 years ago
Ryan Dahl cdda8b6a60 Support empty header values
15 years ago
Cliff Frey 8732d108a4 stop tracking lengths of returned values
15 years ago
Cliff Frey 076fa15132 reduce the size of the http_parser struct
15 years ago
Cliff Frey 0e8ad4e003 reduce size of http_parser object from 104 to 84 bytes by only tracking one field size
15 years ago
Ryan Dahl 8beed7ef17 Fix whitespace
15 years ago
Cliff Frey b8c3336f5d add support for HTTP_BOTH
15 years ago
Ryan Dahl c2acc213ac Skip body for HEAD responses
15 years ago
Cliff Frey 7239788205 pass pointer to settings structure rather than pass by value
15 years ago
Ryan Dahl 7cfa645fc7 Fix long chunked message bug
15 years ago
Ryan Dahl 88d11b394d Support Upgrade header
15 years ago
Ryan Dahl da30924dc8 Use stddef.h
15 years ago
Ryan Dahl a458431e38 Remove string.h include
15 years ago
Ryan Dahl e07e0b952e Tasteful vertical whitespace.
15 years ago
Ryan Dahl 4bce6b4467 Use nginx-style method compare
15 years ago
Ryan Dahl dbd2dad461 Introduce http_parser_settings
15 years ago
Ryan Dahl ef14734f6c Use marcros instead of inline funcs to do callbacks
15 years ago
Ryan Dahl 8243fddd17 Fix c++ and mac compile errors
15 years ago
Ryan Dahl 1b30bf4ba5 Only allow 80kb of header bytes
15 years ago
Cliff Frey d5a900264f Allow newlines before HTTP requests.
15 years ago
Cliff Frey f167565742 Allow '_' in header fields.
15 years ago
Cliff Frey 6409a5bd17 Allow extra '?' in query strings, and add a test for it.
15 years ago
Cliff Frey ae8234de93 Prevent uninitialized variable use
15 years ago
Ryan Dahl 9cbd66e49a Support 'Proxy-Connection' header
15 years ago
Ryan Dahl caef58793e Update license for 2010
15 years ago
Ryan Dahl 1a677040c0 API: Define parser type in http_parser_init()
15 years ago
Ryan Dahl 6108b765ce Bugfix: sometimes servers send \n instead of \r\n
15 years ago
Ryan Dahl b5b116e59e Remove unused 's_headers_done' state
15 years ago
Ryan Dahl 79947a7334 Remove EOL whitespace
15 years ago
Ryan Dahl 402eda40a7 Change flag values to bit shifts
15 years ago
Ryan Dahl 0d6cebd70b wasn't correctly setting method for PROPPATCH and PROPFIND
15 years ago
Ryan Dahl 9c059ec60d Reimplement support for extension methods
15 years ago
Ryan Dahl 12808fe1e6 accept webdav methods
15 years ago
Ryan Dahl d53606f57e Add a macros for the usual case
15 years ago
Ryan Dahl 0cbc9101d0 Use error label, instead of returning directly
15 years ago
Ryan Dahl 51e9ff0314 Fix initialization bug.
15 years ago
Ryan Dahl 873912df5e Only use s_dead in STRICT mode.
15 years ago
Ryan Dahl a8f7a3cd78 add message_complete_on_eof test
15 years ago
Ryan Dahl bd291ab5d8 add license file
15 years ago
Ryan Dahl 5b00b6a64f add http_should_keep_alive()
15 years ago
Ryan Dahl 5b37977e32 Don't put should_keep_alive messages in front of messages
15 years ago
Ryan Dahl 8f52d451a6 Add http version to tests
15 years ago
Ryan Dahl 717d04ce2d Optimize increasing the header_index
15 years ago
Ryan Dahl ca1e011ab3 add response scan, fix persistent bug
15 years ago
Ryan Dahl fb6dc67b05 strict check
15 years ago
Ryan Dahl 3ac0ebdee5 Passing tests
15 years ago
Ryan Dahl 0642366f0e change around api
15 years ago
Ryan Dahl b283cd950f copyright header
15 years ago
Ryan Dahl 3834853a8a uri -> url
15 years ago
Ryan Dahl d931481302 fix bug, first scan works.
15 years ago
Ryan Dahl b71a17ec85 better output for test_scan
15 years ago
Ryan Dahl 0b8a48049c Handling chunked messages
15 years ago
Ryan Dahl c5a92f792f Now parsing some req headers
15 years ago
Ryan Dahl 433202d825 new version
15 years ago