Connor Imes
b526214a3d
Move net_error_list from net to net_traits. Fixes #7050 .
2015-08-06 16:37:08 -05:00
James Graham
f52276d2cc
Use hosts-replaced URL only when loading resources
2015-08-05 10:34:20 +01:00
Sam Gibson
0d94ee917d
Ensure STS headers are only honoured when they come from an HTTPS host
2015-08-02 21:18:24 +12:00
Sam Gibson
c44579018a
Obey Strict-Transport-Security header
2015-08-02 21:17:58 +12:00
Patrick Walton
024c4df912
script: Fix merge fallout.
2015-07-31 11:28:09 -07:00
Patrick Walton
2aa5174246
script: Make the resource task communication use IPC channels.
2015-07-31 11:28:09 -07:00
Patrick Walton
44d13f7fd4
net: Use a thread for each AsyncResponseTarget
to avoid having to send
...
trait objects across process boundaries.
2015-07-31 11:27:49 -07:00
Patrick Walton
9c9d7dc93b
net: Make most of the resource task messages serializable.
2015-07-31 11:27:49 -07:00
Patrick Walton
164e10202c
devtools: Convert the developer tools to run over IPC.
2015-07-27 09:10:01 -07:00
Patrick Walton
82b53d83ff
script: Make the ImageCacheTask
use IPC.
...
This necessitated getting rid of the boxed trait object that was being
be passed between the script task and the image cache task.
2015-07-26 23:07:44 -07:00
Patrick Walton
43cb7d5abd
net: Convert the storage task to use IPC.
2015-07-26 17:07:17 -07:00
Sam Gibson
118122da38
Uses the approach suggested by @SimonSapin for changing Url scheme
...
servo/rust-url#61
2015-07-22 11:49:10 +12:00
Sam Gibson
5014da42fc
Only secure URL's that aren't already to HTTPS.
...
Cuts down on logger spam, and unnecessary Url::clone's
2015-07-22 11:49:09 +12:00
Sam Gibson
bae979137a
Moves HSTS includeSubdomains enum to net_traits
2015-07-22 11:49:09 +12:00
Sam Gibson
82cafc4274
Passes an Arc<Mutex<HSTSList>> to threads instead of cloning
2015-07-22 11:49:09 +12:00
Sam Gibson
11f5be6d85
Responds to more code review feedback
...
* Use regex from resource task
* Don't have an option of an HSTS list, default to empty
2015-07-22 11:49:08 +12:00
Sam Gibson
f2148f06b1
Moves the HSTS replacement code to http_loader
...
This respects STS for redirects as well.
2015-07-22 11:49:08 +12:00
Sam Gibson
826f56bdf3
Moves HSTS code to it's own module
2015-07-22 11:49:07 +12:00
Sam Gibson
02bd5cdc1b
Resolves remaining code review issues
...
* Don't pass a boolean to the HSTSEntry constructor, use an enum instead
* Don't clone when securing load data
* Comment about the Url bug
* Change remaining assert!(... == ...) to assert_eq!(..., ...)
2015-07-22 11:49:07 +12:00
Sam Gibson
29a34dbdb5
Resolves code review comments
...
* Lots of rust-isms
* Mutable iterator for modifying entries (much better)
2015-07-22 11:49:06 +12:00
Sam Gibson
a068a80619
Don't unnecessarily clone strings
2015-07-22 11:49:06 +12:00
Sam Gibson
8a401d5a7f
Re-parse URL to not have inconsistent state
2015-07-22 11:49:05 +12:00
Sam Gibson
795454fb81
Adds control message for HSTS headers
2015-07-22 11:49:04 +12:00
Sam Gibson
f284181781
Abstract out ResourceManager messaging from impl
...
De-coupling makes testing a bit easier.
2015-07-22 11:49:04 +12:00
Sam Gibson
ff1777e446
Evict HSTS entries when a max-age of 0 is seen
2015-07-22 11:49:03 +12:00
Sam Gibson
690ac636eb
Rename/refactor
2015-07-22 11:49:03 +12:00
Sam Gibson
15c90a58b2
Expire HSTS entries that have exceeded their max-age
...
servo/servo#6105
2015-07-22 11:49:03 +12:00
Sam Gibson
8d39fb6dcf
Shift checking for IP address host for HSTS entry to constructor
...
servo/servo#6105
2015-07-22 11:48:05 +12:00
Sam Gibson
cb9b0c2a7a
Add max-age to HSTS entries
...
Refactors API for pushing new entries on, and adds a max age. This does
not add a check for the max-age, or remove old entries from the list.
Instead this just adds the data-field.
servo/servo#6105
2015-07-22 11:48:05 +12:00
Sam Gibson
72d4433587
Do not allow IP address in HSTS list
...
As per [rfc6797](https://tools.ietf.org/html/rfc6797#section-8.1.1 ), do
not allow IPv4 or IPv6 addresses as host entries into the HSTS list.
servo/servo#6105
2015-07-22 11:48:04 +12:00
Sam Gibson
d2f35555b9
Implement mutable HSTS list
...
This prepares the resource task to update the HSTS list when it sees STS
headers. This will allow full HSTS support for servo/servo#6105 when the
resource task implements the header checking
2015-07-22 11:48:03 +12:00
Sam Gibson
aa19a9a741
Preload an HSTS domain list from chromium
...
This resolves the first part of servo/servo#6105 . The remaining part is
to update the list based on the STS headers from the server.
2015-07-22 11:48:03 +12:00
Bogdan Cuza
0baa6b477c
Replace astersisks with appropriate versions in deps
2015-07-20 20:08:08 +03:00
Patrick Walton
b6485a9eaf
compositing: Make the constellation messages serializable.
2015-07-18 12:43:08 -07:00
Simon Sapin
83d2a11d86
Upgrade to rustc 1.3.0-dev (fddfd089b 2015-07-10)
2015-07-15 00:46:43 +02:00
Ms2ger
28086f3c75
Use Box::into_raw rather than boxed::into_raw.
...
The latter is deprecated.
2015-06-25 23:03:54 +02:00
Ms2ger
73a7e92bfd
Update to rustc 2d0cbf3e3e25e092bd9e4c94d08e446b680869f0.
2015-06-25 20:02:36 +02:00
Pyfisch
468faf9d43
Remove is_some() from mime_classifier.rs and fix typo "uknown" -> "unknown"
2015-06-23 22:46:22 +02:00
ecoal95
8cbfb3482c
Use euclid from crates.io
2015-06-19 00:04:24 +02:00
bors-servo
db2eb36e19
Auto merge of #6325 - Ms2ger:from_str, r=nox
...
The former appears to be preferred.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6325 )
<!-- Reviewable:end -->
2015-06-14 03:55:56 -06:00
Ms2ger
b49bd79625
Use str::parse() rather than FromStr::from_str.
...
The former appears to be preferred.
2015-06-13 17:58:16 +02:00
Eduard Burtescu
9a87f830fc
Preserve UserAgent header on redirect.
2015-06-12 21:44:22 +03:00
Manish Goregaokar
c73eaefc47
Audit and reduce unstable usage in net
...
Reasons behind existing unstable features:
std_misc:
- `Handle` usage (API will be replaced and is perhaps broken)
path_ext:
- Checking if a file exists. This is doable from the File directly, but slightly longer
core:
- `FnBox`
alloc:
- `boxed::into_raw()` (naming)
2015-06-10 00:15:09 +05:30
Eduard Burtescu
00e8e5f77d
Use the correct log crate and setup env_logger in main.
2015-06-06 23:20:40 +03:00
Corey Farwell
a14c745a6a
Bump rust-url version: 0.2.16 → 0.2.35
2015-06-04 16:45:15 -04:00
bors-servo
20f63459ef
Auto merge of #6254 - servo:rustup_20150601, r=SimonSapin
...
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6254 )
<!-- Reviewable:end -->
2015-06-02 12:53:37 -05:00
Manish Goregaokar
f80f99fe1e
Move to latest hyper everywhere
2015-06-02 20:12:14 +05:30
Corey Farwell
435e551753
Remove get_
prefix on getters
...
Part of #6224
I certainly didn't remove all of them; I avoided `unsafe` areas and also `components/script`
2015-06-02 08:54:44 -04:00
Mike Blumenkrantz
68fc51205f
add error enum for chromium net errors, create window method for error propagation
2015-05-27 14:45:50 -04:00
bors-servo
be6c251e4c
Auto merge of #6171 - eleweek:fix-4184-ok, r=Manishearth
...
I tried fixing #4184 , here is the code I have right now.
I haven't tested it, because I don't know what is the best way to test this part of code. Would like some help with testing this. Should I write an autotest or should I just test manually?
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6171 )
<!-- Reviewable:end -->
2015-05-25 23:10:18 -05:00