Marc Schreiber
96b4142156
Upgrade to hyper 0.12.
...
* Use hyper's 'MakeService' implementation with futures API.
* Use tokio runtime to serve HTTP backend.
2020-07-11 09:24:03 -07:00
Sergio Benitez
263e39b5b4
Always override config defaults with env vars.
...
Fixes a regression introduced in f7b1089
.
2020-07-08 19:39:28 -07:00
gcarq
86d0bdddb2
Replace manual ASCII checks with 'std::char' calls.
2020-06-22 05:07:14 -07:00
Sergio Benitez
74f15a7ab5
Use top-level doc image URLs.
2020-06-11 02:30:14 -07:00
Sergio Benitez
f7b1089b49
Allow setting config path via 'ROCKET_CONFIG_FILE'.
2020-06-07 03:46:43 -07:00
Sergio Benitez
a4301c0a9a
Add 'Config::read()' and 'Config::read_from()'.
...
The former method allows constructing a 'Config' in the exact manner
Rocket does internally: reading the active environment's properties from
'Rocket.toml' and overriding values from environment variables. The
'read_from()' property does the same except it allows a custom config
file path.
This PR also improves the internal structure of the configuration code.
2020-06-07 02:42:15 -07:00
Jeb Rosen
097fbd7df0
Fix some broken links in API documentation.
2020-05-31 11:32:14 -07:00
Yusuke Kominami
a21221aeb6
Replace deprecated 'OffsetDateTime::now' with 'OffsetDateTime::now_utc'.
...
Update 'time' dependency accordingly.
2020-05-30 11:13:40 -07:00
Nia Watts
ea81f8e07b
Fix typo in 'Query' documentation: 'mplementation' -> 'implementation'.
2020-05-30 11:09:42 -07:00
Sergio Benitez
ee5988fe5c
Update 'cookie' to '0.14'.
2020-05-30 01:49:32 -07:00
Sergio Benitez
b8f9011c04
Fix 'LocalRequest::clone()' soundness issue.
...
The existing implementation of 'LocalRequest::clone()' mistakenly copied
the internal 'Request' pointer from the existing 'LocalRequest' to the
cloned 'LocalRequest'. This resulted in an aliased '*mut Request'
pointer, a clear soundness issue. The fix in this commit is to clone the
internal 'Request', replacing the internal pointer with the newly cloned
'Request' when producing the cloned 'LocalRequest'. A fix that removes
all 'unsafe' code should be explored.
Fixes #1312 .
2020-05-27 01:09:12 -07:00
Alex Macleod
ca4d1572d4
Hide emoji on Windows.
...
Closes #1122 .
2020-05-17 15:30:48 -07:00
Sergio Benitez
a8b029e423
Properly delimit length and name in flash cookies.
...
Fixes #1263 .
2020-05-16 17:55:54 -07:00
Thiago Veronezi
94a222f6fe
Fix typo in 'State' documentation: missing backtick.
2020-04-21 18:47:17 -07:00
Sergio Benitez
53353df633
Fix more broken links.
2020-03-09 02:03:38 -07:00
Sorin Davidoi
dfc9e9aab0
Improve accessibility of default error HTML.
2020-03-02 16:39:19 -08:00
Sergio Benitez
32e86c3b69
Inline macro docs into core crate.
2020-02-25 16:56:59 -08:00
Sergio Benitez
385b69cf69
Migrate to 'binascii' for base 16, 64 decoding.
2020-02-14 17:14:37 -08:00
Sergio Benitez
f35e3c4aca
Set cookies even on error responses.
...
Fixes #1213 .
2020-01-23 21:10:04 -08:00
Sergio Benitez
7c1b8dc9ad
Update 'cookie' to 0.13, 'rustls' to 0.16.
2020-01-21 16:10:04 -08:00
A. L
859224a209
Add additional Responder wrappers for some common HTTP status codes:
...
* 204 NoContent
* 401 Unauthorized
* 403 Forbidden
* 409 Conflict
2020-01-15 11:41:19 -08:00
Michael Howell
121210c55c
Add support for base16-encoded (a.k.a. hex-encoded) secret keys.
2019-11-29 12:06:55 -08:00
Jacob Pratt
4e6a7ddd5f
Remove use of the 'crate_visibility_modifier' feature.
...
Most items with 'crate' visibility become 'pub(crate)'.
Items are made 'pub' instead when they would remain private.
2019-09-21 09:16:04 -07:00
Jacob Pratt
bed93133b8
Abide by formatting in 'Debug' implementations.
2019-09-18 19:06:08 -07:00
Jacob Pratt
e3c1a4ad3a
Remove use of the 'try_trait' feature.
...
Add the 'try_outcome' macro to replace uses of '?' on 'Outcome'.
2019-09-18 18:43:16 -07:00
Jacob Pratt
b95b6765e1
Remove use of 'label_break_value' feature.
2019-09-10 17:27:40 -07:00
Sergio Benitez
2537a1164d
Remove 'Result' specialization. Add 'Debug' responder.
...
This removes all uses of specialization in Rocket.
2019-09-09 21:57:33 -07:00
Sergio Benitez
3fae9919f7
Deprecate 'Result<T, E>, E: !Responder' responder.
2019-09-09 21:56:55 -07:00
Sergio Benitez
c5973f01df
Remove use of specialization in 'status::Created'.
2019-09-09 16:37:46 -07:00
Jeb Rosen
3e4f8453ce
Remove use of the 'decl_macro' feature.
...
Also removes one internal use in the 'typed-uris' codegen test.
2019-07-19 11:39:56 -07:00
Jacob Pratt
34a741a26e
Remove use of '!' type in favor of 'Infallible'.
...
This removes the use of and dependence on the 'never_type' feature.
2019-07-09 15:10:51 -07:00
Sergio Benitez
21b10176ee
Forward from 'StaticFiles' if a file is not found.
...
Also adds a 'handler::Outcome::from_or_forward' method for easily
constructing handler outcomes that forward on responder failures.
Fixes #1036 .
2019-07-07 23:22:38 -07:00
Dmitry Murzin
c100a92127
Implement 'FromParam' for 'NonZero*' types.
2019-07-06 13:32:08 -07:00
Sergio Benitez
7f2c9f426c
Fix tests for Windows.
2019-07-06 00:59:01 -07:00
Jeb Rosen
34cb1c14b8
Migrate core to Rust 2018.
2019-06-25 13:45:23 -04:00
Thomas Lent
42f8af411e
Fix type in 'Data' rustdocs: 'T' -> 'DataGuard'.
2019-06-11 15:04:54 -07:00
jeb
6bf751fb22
Reexport derive macros alongside derived traits.
2019-05-22 22:19:47 -07:00
Sergio Benitez
1caf87eb21
Move to 0.5.0-dev on master.
2019-05-13 16:18:48 -07:00
Richard Petrie
75d2ea96d9
Replace deprecated 'isatty' with 'atty'.
2019-05-10 18:21:58 -07:00
Sergio Benitez
3e7a20ae57
Clarify defaults in 'Config' documentation.
2019-05-10 16:39:41 -07:00
Sergio Benitez
fdd76ecf7e
Clean up 'AdHoc' fairing implementation.
2019-05-09 09:04:31 -07:00
Sergio Benitez
7c2dda2647
Clean up 'Server' header commentary.
2019-05-08 20:20:26 -07:00
lu4nm3
0a978fdb5d
Set default 'Server' header only if it isn't set.
...
Closes #996 .
2019-05-08 20:18:10 -07:00
Konrad Borowski
7ab1c427b5
Replace uses of `FnBox`; `Box<dyn FnOnce>` now implements `FnOnce`.
2019-04-13 09:15:27 -07:00
Jacob Pratt
9b219ddc01
Remove stabilized feature gates.
...
* try_from
* transpose_result
2019-04-12 18:48:51 -07:00
Sergio Benitez
de9a98edd2
Update 'Rocket::custom()' docs to match signature.
...
Resolves #910 .
2019-02-06 17:18:53 -08:00
Chris Foster
4921af459f
Fix typo in 'LenientForm' docstring: 'gaurd' -> 'guard'.
2019-01-31 20:15:10 -08:00
Sergio Benitez
ca5623c641
Type encoding to fix encoding issues once and for all.
...
Fixes #849 .
2018-12-12 17:38:36 -08:00
Sergio Benitez
a4dcb0cf4c
New version: 0.4.0.
2018-12-06 09:19:11 -08:00
Sergio Benitez
90a6749313
New version: 0.4.0-rc.2.
2018-11-30 21:00:18 -08:00