kevmoo@google.com
4e87f2a87c
pkg/http_server: move to multi-lib layout
...
Dependencies between features are now crystal clear
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//756493002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41936 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-24 18:14:19 +00:00
sgjesse@google.com
1e4c88c97b
Don't to do HTML entity decoding for multi-part form fields
...
The code was trying to do HTML entity decoding on text field values
in multipart form posts. This has been removed as it did not work.
The parsing was expecting HTML entities to always be used, but that is
not the case. Chrome, Firefox and Safari will do it if e.g. the attribute
accept-charset="latin1" is set on the HTML form element, but the default
when accept-charset is not set or is set to utf8 UTF-8 encoding will be
used.
Also when HTML entity encoding is used, the encoding done by the browser
cannot be consistently decoded. E.g. if the value '&#<some large char>' is
entered in a form with accept-charset="latin1" the value in the
multipart/form-data response is '&#ひ' (<some large char> is HTML
entity encoded as ひ), so '&#' is not escaped in any way.
Passing the value returned by the browser into user code without trying to
be clever is the right thing to do.
R=kustermann@google.com
BUG=
Review URL: https://codereview.chromium.org//730203008
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41821 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-19 07:41:17 +00:00
sgjesse@google.com
82ba3ad49b
Fix a number of issues with the Range header handling for serving files
...
* Handling end position after file length
* Handling suffix range longer than file length
* Ignore syntactically invalid Range headers
* Return 416 (Requested range not satisfiable) if start < end
Added tests for these cases.
BUG=http://dartbug.com/21587
R=ajohnsen@google.com , kustermann@google.com
Review URL: https://codereview.chromium.org//721213002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41775 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-17 14:21:09 +00:00
ajohnsen@google.com
979f82002f
Add 'pathPrefix' optional argument to VirtualDirectory constructor.
...
By setting the pathPrefix, all incoming requests are expected to have
its uri starting with the path. Then, before doing resource lookup, the
prefix is trimmed from the path.
BUG=https://code.google.com/p/dart/issues/detail?id=17353
R=kevmoo@google.com
Review URL: https://codereview.chromium.org//424063002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@38720 260f80e4-7a28-3924-810f-c04153c831b5
2014-07-30 06:50:23 +00:00
nweiz@google.com
1e72a8f408
Remove documentation links for repo packages.
...
pub.dartlang.org will now automatically link to dartdocs.org for
packages with no documentation link.
BUG= http://dartbug.com/20177 , http://dartbug.com/20178 , http://dartbug.com/20186
R=sigmund@google.com
Review URL: https://codereview.chromium.org//416973003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@38551 260f80e4-7a28-3924-810f-c04153c831b5
2014-07-24 20:23:52 +00:00
ajohnsen@google.com
d3411334c8
Fix links of VirtualDirectory.
...
BUG=https://code.google.com/p/dart/issues/detail?id=19717
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//370753002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@38010 260f80e4-7a28-3924-810f-c04153c831b5
2014-07-04 12:04:25 +00:00
ajohnsen@google.com
4c9f0be0fc
Use utf-8 encoding for listing and error page, in http_server VirtualDirectory.
...
BUG=https://code.google.com/p/dart/issues/detail?id=15157
R=ricow@google.com
Review URL: https://codereview.chromium.org//360453004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@37779 260f80e4-7a28-3924-810f-c04153c831b5
2014-06-27 09:11:25 +00:00
kevmoo@google.com
1e7466a677
pkg/http_server: fixes for unittest deprecations
...
R=ajohnsen@google.com
Review URL: https://codereview.chromium.org//217143002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@34506 260f80e4-7a28-3924-810f-c04153c831b5
2014-03-28 16:37:57 +00:00
kevmoo@google.com
a300ce0a1d
pkg/http_server: return future for VirtualDirectory serveRequest
...
Also:
- Return the subscription from serve method
- Bumped version
BUG= https://code.google.com/p/dart/issues/detail?id=15893
BUG= https://code.google.com/p/dart/issues/detail?id=16005
R=ajohnsen@google.com
Review URL: https://codereview.chromium.org//124833003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31701 260f80e4-7a28-3924-810f-c04153c831b5
2014-01-10 19:27:05 +00:00
nweiz@google.com
113bd79bc6
Make pkg/path 1.0.0 and upgrade dependencies appropriately.
...
All existing packages that use pkg/path (other than pkg/stack_trace,
which has already been updated) are compatible with both the pre-1.0
and post-1.0 path API, so I've marked their version constraints as
">=0.9.0 <2.0.0". I've also incremented their patch versions and I
intend to release new versions as soon as this CL lands.
R=alanknight@google.com , efortuna@google.com , jmesserly@google.com , rnystrom@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org//110873002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31005 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-10 00:24:01 +00:00
dgrove@google.com
18ca7d0036
Re-land r29957 (add versions and constraints for packages and samples), with
...
SDK constraints bumped from 1.0.0 to 0.8.10+6 .
R=ricow@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org//62473002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29986 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-06 18:28:22 +00:00
ajohnsen@google.com
61f6c51990
Revert "add versions and constraints for packages and samples"
...
This is currently blocking us from testing samples.
BUG=
R=kasperl@google.com
Review URL: https://codereview.chromium.org//59513007
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29960 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-06 09:09:18 +00:00
jmesserly@google.com
02638c5760
add versions and constraints for packages and samples
...
- all packages at 0.9.0, except "analyzer" which had a version already
- dependencies at ">=0.9.0 <0.10.0" except analyzer is ">=0.10.0 <0.11.0"
- sdk constraint ">=1.0.0 <2.0.0"
R=sigmund@google.com
Review URL: https://codereview.chromium.org//59763006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29957 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-06 03:27:58 +00:00
sethladd@google.com
d0f5d11552
http_server depends on path
...
BUG=
R=ajohnsen@google.com
Review URL: https://codereview.chromium.org//47313002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29330 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-27 19:19:39 +00:00
ajohnsen@google.com
64bc9874f9
Add README file for http_server package.
...
BUG=https://code.google.com/p/dart/issues/detail?id=14192
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//32003002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28923 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-21 09:21:37 +00:00
kevmoo@j832.com
18d38085ab
pkg: analysis aided cleanup
...
Removed a lot of warnings and hints when opening many pkg projects in the editor
R=gram@google.com
Review URL: https://codereview.chromium.org//22284003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25831 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-06 20:42:04 +00:00
ajohnsen@google.com
53badd793a
Add auto-detection of MIME-type in VirtualDirectory.
...
Default charset for text/* is still missing.
BUG=
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//17573011
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24328 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-24 13:05:39 +00:00
ajohnsen@google.com
0ef921b335
First push of a new 'http_server' dart package.
...
The package will contain helper-classes for writing http server, such as
VirtualDirectory, VirtualHost etc.
BUG=
R=sgjesse@google.com
Review URL: https://codereview.chromium.org//17544005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24281 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-21 11:22:31 +00:00