Commit graph

214 commits

Author SHA1 Message Date
Josh Matthews
43369fa897 Rename create_with_headers to create. 2016-04-15 01:46:04 -04:00
Josh Matthews
a761f2bed4 Remove unused header manipulation facilities. 2016-04-15 01:46:03 -04:00
Josh Matthews
a315f8db9e Reorganize header manipulation that occurs before sending an HTTP request so we can provide the full set of headers while creating a request. 2016-04-15 01:45:56 -04:00
Josh Matthews
0e1703d747 Convert NetworkHttpRequestFactory. 2016-04-15 01:45:55 -04:00
Josh Matthews
80eaeac9f4 Make headers available when creating an HTTP request via a factory. 2016-04-15 01:45:48 -04:00
Josh Matthews
dc790048ec Remove unnecessary type annotations. 2016-04-15 01:00:44 -04:00
Daniel
b0e1f10ba5 401 authorization UI then restart request/save successful auth creds 2016-04-14 21:38:45 -04:00
Ms2ger
489d2e5e49 Update uuid. 2016-04-07 09:00:22 +02:00
Connor Brewster
b09570b2b6 Added global state struct
Replace hsts_list, auth_cache, and cookie_jar with http_state

Reverted a few changes

Moved http_state back to factory
Removed unnecessary Arc

Removed Arc for http_state
2016-03-25 12:35:40 -06:00
Daniel
d49d3b01f2 add auth cache to resources + set auth header if url does not have creds 2016-03-24 12:24:08 -04:00
bors-servo
162e89d8c6 Auto merge of #9780 - bobthekingofegypt:github_hsts_bug, r=jdm
correctly send secure cookies after hsts url match

Fixes #8100, where sites in the hsts list were not recieving secure
cookies if the site was originally loading using a plain http url.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9780)
<!-- Reviewable:end -->
2016-03-09 15:13:52 +05:30
Nikki
b187985e49 set response.body asynchronously in Fetch 2016-03-07 15:09:39 -07:00
Bob
17e6007685 send correct url to devtool on request
Send url that was not modified by the hosts file to the dev tools
2016-03-03 17:15:29 +00:00
Bob
06ffdd68e8 refactor http_loader hostname/htst order
Changed hostname rewrite to happen inside obtain response after any htst
changes.  Removed  url from load leaving just doc_url to avoid confusion
2016-03-01 18:10:58 +00:00
Chandler Abraham
3a949b77b2 don't unconditionally override header 2016-02-27 10:47:13 -05:00
Bob
759099c78d correctly send secure cookies after hsts url match
Fix for #8100, where sites in the hsts list were not recieving secure
cookies if the site was originally loading using a plain http url.
2016-02-27 15:16:53 +00:00
bors-servo
bc034845b7 Auto merge of #9662 - rebstar6:websocket_cookies, r=jdm
Add support for websocket cookies

Addresses both cookies in request and response. Resolves #9540.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.svg" height="40" alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9662)
<!-- Reviewable:end -->
2016-02-18 02:44:01 +05:30
Rebecca
cf6fd6dafe Add support for websocket request and response cookies
Also change expected behavior to pass for all in tests/wpt/web-platform-tests/websockets/cookies
2016-02-17 14:50:52 -05:00
Daniel Robertson
4d15b02dde Handle credentials in modify_request_headers
Handle credentials and set the apropriate header in
`modify_request_headers`.
2016-02-15 06:47:47 +00:00
Paul Rouget
63519c3574 mozbrowsersercuritychange event 2016-02-09 08:05:17 +01:00
Nikki
5a8c533755 Implement a basic test for Fetch and fix errors it finds 2016-01-13 16:45:57 -07:00
rohan.prinja
1f02c4ebbb task -> thread 2016-01-10 17:58:13 +09:00
Nikki
af310f7874 minimal implementation of http_network_fetch for testing purposes 2016-01-05 12:14:07 -07:00
Johannes Linke
6b215f38ee Fix a bunch of clippy lints 2016-01-02 23:27:15 +01:00
bors-servo
7371da6ca0 Auto merge of #9078 - nikkisquared:split_http_loader_load, r=jdm
Split http_loader::load into two methods

This is intended to fix #8976 by moving the http_loader::load code that deals with getting a response and moving it into its own function. I've built it and run existing tests against my changes and that looks fine. I'd like feedback on changes I've made to accommodate refactoring the code. And I'm sure there's a more descriptive function name than "load_response", I just wasn't sure how to describe what it does.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9078)
<!-- Reviewable:end -->
2016-01-01 01:48:09 +05:30
David Rajchenbach-Teller
1e81b8c133 Resolves #4183 - Implemementing context-based MIME type sniffing
The version of the standard is not finalized at the time of this writing.
Specifications may be found here: https://mimesniff.spec.whatwg.org/#context-specific-sniffing .
2015-12-31 07:45:03 -05:00
Nikki
f665858271 Fixes #8976: Split load() into process_response() 2015-12-29 17:19:22 -07:00
Abhishek Kumar
f889b1ccd7 Support responseCookies, responseContent, responseHeaders, requestCookies, getResponseHeaders,
getResponseContent, getRequestPostData, getRequestCookies, getResponseCookies, getEventTimings and
getSecurityInfo message for network devtools

Fixing Indentation
2015-12-21 10:28:40 -05:00
Mathieu Agopian
11234f5370 Use Url.join instead of UrlParser.base_url(...).parse (#9002) 2015-12-18 17:02:41 +01:00
Jigesh Mehta
ce3c9ff57c implement support for withCredentials 2015-12-04 16:34:30 -05:00
Alex Gaynor
2d662aa4e7 Always disable SSLv2 and SSLv3.
These protocols have serious known weakness and our turned off in other browsers.
2015-11-21 12:11:48 -05:00
Alex Gaynor
008d99663f Fixed #8594 -- use a more modern default cipher suite list by default 2015-11-20 11:40:07 -05:00
Ravi Shankar
afb9b0707b Testing cancellation during redirects 2015-11-14 10:04:32 +05:30
Josh Matthews
5e123df7a7 Make SSL cert verification errors work again. Add a horrible, no-good, very bad regression test. 2015-11-13 11:30:38 -05:00
Ravi Shankar
10f5584f78 Implement cancellation listener for cancelling network requests 2015-11-12 14:02:59 +05:30
Abhishek Kumar
b7de946205 Check in for task 1,4 and 5
Adding pipelineID to httpresponse message, clearner code for task1

Commit for Refactored task

Unit tests

Removing extra whitespaces.

Removing extra whitespaces.

Removing tabs whitespaces

Making Code tidier.

Style issues Fix

Test-tidy Fixes
2015-11-05 00:17:24 -05:00
Nova Fallen
00528f1f1f Refactor code dealing with headers of requests and responses into separate functions to enable use by websocket code 2015-11-03 11:17:53 -05:00
nxnfufunezn
468eaac096 Accept Brotli-compressed HTTP responses #8156 2015-11-01 08:59:18 +05:30
Eli Friedman
10664cf3f4 Refactor resource loaders to use send_error utility.
No substantial functional change.
2015-10-13 16:37:12 -07:00
David Raifaizen
43a0651761 Removed user agent parameter from being unnecessarily passed 2015-10-13 18:17:26 -04:00
Corey Farwell
20beaf5af3 Fix issues found by rust-clippy 2015-10-12 20:21:49 -04:00
bors-servo
ac1b595609 Auto merge of #7976 - frewsxcv:clippy, r=jdm
Cleanup code that was warned by rust-clippy

[whitespace agnostic diff](https://github.com/servo/servo/pull/7976/files?w=1)

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7976)
<!-- Reviewable:end -->
2015-10-12 04:37:42 -06:00
Rahul Sharma
4b363d2a0e convert match to if let for location header check #7969 2015-10-12 10:27:20 +05:30
Corey Farwell
81e034885b Cleanup code that was warned by rust-clippy 2015-10-11 20:47:45 -04:00
Gökberk Yaltıraklı
5eeca1f037 Use typed header API instead of set_raw in set_default_accept_encoding 2015-10-11 11:00:03 +03:00
Prabhjyot Singh Sodhi
920bb5e4b8 tests for devtools integration with network requests/responses 2015-09-25 22:07:01 +05:30
Ravi Shankar
889eec364b sorted the extern crate, mod & use declarations 2015-09-24 02:12:45 +05:30
Maciej Skrzypkowski
88815d21ba Add plugins for compositing and net crates #7699
Changed to_string calls to to_owned calls
where was a need.
2015-09-22 13:51:21 +02:00
Sam Gibson
6d20b388f6 General cleanup for HSTS/Cookie Arc 2015-09-19 18:30:38 +12:00
Sam Gibson
6f573d5d44 Move HSTS/CookieStorage to Arc<RwLock> from Ipc
servo/servo#7421
2015-09-19 18:30:37 +12:00