Commit Graph

72 Commits

Author SHA1 Message Date
Xiao Yu d968304570 Reland "Revert commits part of #40548 which still has some design debates and breaks valid local network http traffic"
This is a reland of d84f359786

Original change's description:
> Revert commits part of #40548 which still has some design debates and breaks valid local network http traffic
>
> Bug: https://github.com/flutter/flutter/issues/72723
> Change-Id: Ib5f809fccf1fad69add441fd40c463da8dc8be36
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192953
> Auto-Submit: Xiao Yu <xster@google.com>
> Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
> Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
> Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>

Bug: https://github.com/flutter/flutter/issues/72723
Change-Id: I466d888b3f324a996f0bef0463e7ab3df3179c56
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195485
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Commit-Queue: Xiao Yu <xster@google.com>
2021-04-16 20:25:36 +00:00
Xiao Yu f560d90059 Revert "Revert commits part of #40548 which still has some design debates and breaks valid local network http traffic"
This reverts commit d84f359786.

Reason for revert: removed some private looking but actually vm-entrypoints used by Flutter engine https://buganizer.corp.google.com/issues/185462669

Original change's description:
> Revert commits part of #40548 which still has some design debates and breaks valid local network http traffic
>
> Bug: https://github.com/flutter/flutter/issues/72723
> Change-Id: Ib5f809fccf1fad69add441fd40c463da8dc8be36
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192953
> Auto-Submit: Xiao Yu <xster@google.com>
> Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
> Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
> Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>

TBR=lrn@google.com,vegorov@google.com,xster@google.com

Change-Id: Ie746805ab7ef214bc4ba6f3582eb1d32672360ee
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/flutter/flutter/issues/72723
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/195484
Reviewed-by: Xiao Yu <xster@google.com>
Commit-Queue: Xiao Yu <xster@google.com>
2021-04-15 15:29:28 +00:00
Xiao Yu d84f359786 Revert commits part of #40548 which still has some design debates and breaks valid local network http traffic
Bug: https://github.com/flutter/flutter/issues/72723
Change-Id: Ib5f809fccf1fad69add441fd40c463da8dc8be36
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/192953
Auto-Submit: Xiao Yu <xster@google.com>
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2021-04-15 09:25:17 +00:00
Mehmet Fidanboylu 909a05cf8a [dart:io] Remove obsolete http embedder config.
This is no longer being used.

Change-Id: I316a28193698cc2ceb62e6d89c87adf0d05f7be7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/161800
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Mehmet Fidanboylu <mehmetf@google.com>
2020-09-04 16:50:10 +00:00
Leaf Petersen d44457f79d [Core Libraries] Eliminate the fork in the core libraries.
Move the nnbd core libraries from sdk_nnbd to sdk, and updates
references in build files and elsewhere accordingly.

Change-Id: I09760fe1e006657aacdfe80f3b22fdf6f7e30a9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151121
Commit-Queue: Leaf Petersen <leafp@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
2020-06-16 23:37:36 +00:00
Leaf Petersen d2543e32f4 Migrate standalone tests which rely on the pre-nnbd sdk libraries.
Migrate all the tests under standalone/ that include files under
sdk/sdk/ as part files to unblock the replacement of the unmigrated
sdk/sdk with the contents of the migrated sdk/sdk_nnbd.

Change-Id: Ia2e78bbff797f58244d94021d4b9616793bd641d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151036
Commit-Queue: Leaf Petersen <leafp@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Jonas Termansen <sortie@google.com>
2020-06-15 19:41:46 +00:00
Zichang Guo efabc6f848 [dart:io] Fixes _HttpHeaders forcing lowercased Header fields.
Outgoing HttpHeaders will use _build() to build headers. This cl make
_build() uses case-sensitive HttpHeaders.

Original change's description:
> [dart:io] Preserve header case in http header _builds()
>
> Bug: https://github.com/dart-lang/sdk/issues/33501
> Change-Id: I57d9bba251b76314bf40b81d1b09bd4643dce4d2
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141911
> Commit-Queue: Zichang Guo <zichangguo@google.com>
> Reviewed-by: Siva Annamalai <asiva@google.com>
> Reviewed-by: Jonas Termansen <sortie@google.com>

Bug: https://github.com/dart-lang/sdk/issues/33501
Change-Id: I2d42351b9593d86ad1b2ea248faaea625d321e96
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143081
Commit-Queue: Zichang Guo <zichangguo@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-05-19 19:24:08 +00:00
Mehmet Fidanboylu 74a20b7bfd Reland "[dart:_http] Allow the embedder to prohibit HTTP traffic."
This is a reland of 6b44c631ad

Original change's description:
> [dart:_http] Allow the embedder to prohibit HTTP traffic.
> 
> This can be configured by embedders by setting the `_embedderAllowsHttp`
> variable. It can also be overridden by client apps by introducing a
> `Zone` with the variable `#dart.library.io.allow_http` set to `true` or
> `false`.
> 
> The default behavior in SDK is unchanged.
> 
> Bug: https://github.com/dart-lang/sdk/issues/40548
> Change-Id: Ifec0ad2d759de4bbb836644840d8c312e560f285
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/138911
> Commit-Queue: Martin Kustermann <kustermann@google.com>
> Reviewed-by: Jonas Termansen <sortie@google.com>

Bug: https://github.com/dart-lang/sdk/issues/40548
Change-Id: I6ced6c1248b3b6687f6c7d998e5206b2b385f00b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142446
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
2020-04-06 17:46:44 +00:00
Aske Simon Christensen a5611cdda2 Revert "[dart:_http] Allow the embedder to prohibit HTTP traffic."
This reverts commit 6b44c631ad.

Reason for revert: Tests timing out on Windows

Original change's description:
> [dart:_http] Allow the embedder to prohibit HTTP traffic.
> 
> This can be configured by embedders by setting the `_embedderAllowsHttp`
> variable. It can also be overridden by client apps by introducing a
> `Zone` with the variable `#dart.library.io.allow_http` set to `true` or
> `false`.
> 
> The default behavior in SDK is unchanged.
> 
> Bug: https://github.com/dart-lang/sdk/issues/40548
> Change-Id: Ifec0ad2d759de4bbb836644840d8c312e560f285
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/138911
> Commit-Queue: Martin Kustermann <kustermann@google.com>
> Reviewed-by: Jonas Termansen <sortie@google.com>

TBR=sortie@google.com,lrn@google.com,kustermann@google.com,mehmetf@google.com

Change-Id: I824a1845e82b5facb839109f74bb482e7095e313
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/40548
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142363
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
2020-04-03 18:19:17 +00:00
Mehmet Fidanboylu 6b44c631ad [dart:_http] Allow the embedder to prohibit HTTP traffic.
This can be configured by embedders by setting the `_embedderAllowsHttp`
variable. It can also be overridden by client apps by introducing a
`Zone` with the variable `#dart.library.io.allow_http` set to `true` or
`false`.

The default behavior in SDK is unchanged.

Bug: https://github.com/dart-lang/sdk/issues/40548
Change-Id: Ifec0ad2d759de4bbb836644840d8c312e560f285
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/138911
Commit-Queue: Martin Kustermann <kustermann@google.com>
Reviewed-by: Jonas Termansen <sortie@google.com>
2020-04-03 16:39:26 +00:00
Jonas Termansen 778eb8f1d0 [dart:_http] Fix HeaderValue.parse if valueSeparator is parameterSeparator.
Closes https://github.com/dart-lang/sdk/issues/31080.

Change-Id: Iba235a339c345d1793935f65e3abe6ffdc157cb5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140869
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Commit-Queue: Jonas Termansen <sortie@google.com>
2020-03-31 12:46:30 +00:00
Jonas Termansen 96cf889e6b [dart:io] Fix HeaderValue parsing, toString(), and support null values.
This is a breaking change. https://github.com/dart-lang/sdk/issues/40709

This change makes the HeaderValue parsing more strict in two invalid
edge cases, supports parameters with null values as a feature, and fixes
toString() so it always produces tokens or quoted-strings valid per RFC
7230 3.2.6.

The empty parameter value without double quotes (which is not allowed by
the standards) is now parsed as the empty string rather than null. E.g.
HeaderValue.parse("v;a=").parameters now gives {"a": ""} rather than
{"a": null}.

Invalid inputs with unbalanced double quotes are now rejected. E.g.
HeaderValue.parse('v;a="b').parameters will now throw a HttpException
instead of giving {"a": "b"}.

The HeaderValue.toString() method now supports parameters with null
values by omitting the value. E.g.:

  HeaderValue("v", {"a": null, "b": "c"}).toString()

now gives

  v; a; b=c

This behavior can be used to implement some features in the Accept and
Sec-WebSocket-Extensions headers.

Likewise the empty value and values using characters outside of RFC 7230
3.2.6 tokens are now correctly implemented by double quoting such values
with escape sequences. E.g.:

  HeaderValue("v",
      {"a": "A", "b": "(B)", "c": "", "d": "ø", "e": "\\\""}).toString()

now gives

   v;a=A;b="(B)";c="";d="ø";e="\\\""

The NNBD migration required making subtle changes to some dart:io
semantics in order to provide a better API. This change backports one of
these semantic changes to the unmigrated SDK so any issues can be
discovered now instead of blocking the future SDK unfork.

Change-Id: Iafc790e03b6290232cac71fe14f995ce0f0b036b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/136620
Commit-Queue: Jonas Termansen <sortie@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2020-03-18 11:36:36 +00:00
Zichang Guo d39cdf03f8 Reland [dart:io] Stop forcing lower case on HttpHeaders
This is a breaking change. Request: https://github.com/dart-lang/sdk/issues/33501

HttpHeaders use lowercase by default for all headers, since it is supposed to be case insensitive. Some servers incorrectly treat case as significant, however, and expect headers with capitalization or in uppercase. The current implementation forces headers to be lower cases when adding values. Users cannot even manually modify the headers.

This change removes this restriction here so that users can modify the headers to whatever form they want. The new behavior is backwards compatible except if class was implemented. All headers inside http.dart are written as lower cases, adding values to HttpHeaders is still receiving lower cases input.

The other cl (https://dart-review.googlesource.com/c/http_multi_server/+/121411) migrates multi_headers.dart to be compatible with this change.

Bug: https://github.com/dart-lang/sdk/issues/33501
Change-Id: Ieb9f4061b27ed3bbc6d82e6a408c77d11abb037b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/135357
Commit-Queue: Zichang Guo <zichangguo@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
2020-02-14 22:23:17 +00:00
Jonas Termansen 3433d8cfc3 [nnbd] Migrate standalone/io to NNBD.
The tests are also now dartfmt.

Bug: https://github.com/dart-lang/sdk/issues/40040
Change-Id: I8dece8097b37b70d47a5374dae2f3fadb0fc4b90
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134338
Commit-Queue: Jonas Termansen <sortie@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
2020-02-07 14:41:36 +00:00
Siva Annamalai bc4860b0cb Most VM specific tests in standalone have been moved to standalone_2 and are being run in the regular bot tests. These tests are for VM functionality like io, process API etc. and have no strong mode implications. Currently we are running these tests twice once from standalone and once from standalone_2.
This CL removes these redundant tests from the standalone directory.

Bug:
Change-Id: Ib0adfa67fffa4de486e847698e18353fb4dd8a46
Reviewed-on: https://dart-review.googlesource.com/18429
Commit-Queue: Siva Annamalai <asiva@google.com>
Reviewed-by: Zach Anderson <zra@google.com>
2017-11-07 23:00:00 +00:00
William Hesse 7bf2788bcc Restore all deleted tests to tests/standalone from migration to standalone_2
We are no longer deleting tests from the Dart 1 test directories when we
add them to the _2 directories. This reverts the part of change
https://dart-review.googlesource.com/c/sdk/+/12240 that modifies
the tests/standlone directory.
Bug:
Change-Id: Ie26b185234d0d18736a2fa13b77c5fd42cbb7e92
Reviewed-on: https://dart-review.googlesource.com/12287
Reviewed-by: Morten Krogh-jespersen <mkroghj@google.com>
2017-10-09 10:46:55 +00:00
Siva Annamalai bd2a8e1d60 Reland migrate most of the tests in standalone to be strong mode clean and move them to standalone_2 directory.
Bug:
Change-Id: I4ca50f315361422db1d4356055862463bfe1d6f3
Reviewed-on: https://dart-review.googlesource.com/12240
Reviewed-by: Siva Annamalai <asiva@google.com>
Reviewed-by: Ben Konyi <bkonyi@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2017-10-07 01:29:36 +00:00
Siva Annamalai ff32187145 Revert "Migrate most of the tests in standalone to be strong mode clean and move"
This reverts commit c85563f582.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Migrate most of the tests in standalone to be strong mode clean and move
> them to standalone_2 directory.
> 
> Change-Id: I9887b8d6d4d86001e4660b400224b881205e6273
> Reviewed-on: https://dart-review.googlesource.com/6080
> Reviewed-by: Ben Konyi <bkonyi@google.com>

TBR=bkonyi@google.com,asiva@google.com

Change-Id: I3c7b6081f17fca45e7828603538f50d06417e2be
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/12020
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2017-10-06 17:24:20 +00:00
Siva Annamalai c85563f582 Migrate most of the tests in standalone to be strong mode clean and move
them to standalone_2 directory.

Change-Id: I9887b8d6d4d86001e4660b400224b881205e6273
Reviewed-on: https://dart-review.googlesource.com/6080
Reviewed-by: Ben Konyi <bkonyi@google.com>
2017-10-06 17:07:34 +00:00
Zachary Anderson 2948f8c1b7 Reland: [dart:io] Moves Http code into a separate library.
This moves Http code into dart:_http. dart:io then imports and
re-exports dart:_http. This is the first stage of moving
dart:_http into its own pub package.

This CL was reverted due to a failure in the Flutter engine build
which happened due to an incomplete change in gen_snapshot.cc, and to
update sdk/lib/libraries.yaml and sdk/lib/libraries.json

Change-Id: Ie90c77ef631aea7a163774b58e8ccbaf71a24d3c
Reviewed-on: https://dart-review.googlesource.com/7588
Reviewed-by: Zach Anderson <zra@google.com>
2017-09-21 19:21:25 +00:00
Zach Anderson 64bf1b49b0 Revert "[dart:io] Moves Http code into a separate library."
Reverting for broken Flutter build and kernel platform compilation test. It looks like the new _http library is missing from various snapshots. Not sure why this didn't fail locally.

This reverts commit ac9ff3f3af.

Change-Id: I7fbc2f842cf1380793e7af9fb869cacd14682885
Reviewed-on: https://dart-review.googlesource.com/7600
Reviewed-by: Zach Anderson <zra@google.com>
2017-09-21 15:57:59 +00:00
Zachary Anderson ac9ff3f3af [dart:io] Moves Http code into a separate library.
This moves Http code into dart:_http. dart:io then imports and
re-exports dart:_http. This is the first stage of moving
dart:_http into its own pub package.

Change-Id: Icd33232a97b3d75511ef7ec88b01fd47cdcf5a23
Reviewed-on: https://dart-review.googlesource.com/6420
Reviewed-by: Siva Annamalai <asiva@google.com>
Reviewed-by: Florian Loitsch <floitsch@google.com>
2017-09-21 15:10:22 +00:00
Jacob Richman 2dcd56ef43 Format all tests.
There are far too many files here to review everyone carefully.
Spot checking most of the diffs look good as test code is generally written
with less care than application code so lots of ugly formatting get through.
If people notice files where the automated formatting bothers them feel free
to comment indicating file names and I'll move spaces within comments to make
the formatting cleaner and use comments to force block formatting as I have
done for other case where formatting looked bad.

BUG=
R=efortuna@google.com

Review-Url: https://codereview.chromium.org/2771453003 .
2017-04-17 14:53:02 -07:00
Søren Gjesse f9404b969b Handle HTTP header parameters with empty values better
This handles the null issue reported.

Closes #26598

BUG= https://github.com/dart-lang/sdk/issues/26958
R=floitsch@google.com

Review URL: https://codereview.chromium.org/2225003002 .
2016-08-08 16:35:15 +02:00
Søren Gjesse eaf75a100e HeaderValues: Handle all parameters without values.
Some cases, an HttpHeader Value may contain all parameters and
no values. This changes ensures that such a header is parsed, that
it is handled correctly.

This was noticed when parsing the following header for websockets:
Sec-WebSocket-Extensions: permessage-deflate; client_no_context_takeover; client_max_window_bits; server_no_context_takeover

It was parsing with the value permessage-deflate (correct) with parameters:
{'client_no_context_takeover;' : 'client_max_window_bits',
'server_no_context_takeover' : null }

With this patch it now properly shows the parameters as:
{'client_no_context_takeover' : null,
'client_max_window_bits' : null,
'server_no_context_takeover' : null }

I've also included a test for this as well.

BUG=

Patch by Matthew Butler <butler.matthew@gmail.com>.

Review URL: https://codereview.chromium.org/1564913002 .
2016-01-07 09:03:53 +01:00
Rico Wind c99e5c02fa Fix tests that explicitly part in io library files
R=sgjesse@google.com
BUG=

Review URL: https://codereview.chromium.org//1328213003 .
2015-09-08 13:30:03 +02:00
William Hesse 13bf8ff9f8 Breaking Change: merge BoringSSL branch into master
This replaces the NSS secure networking library from Mozilla
with the BoringSSL library from Google. This library, based
on OpenSSL, reads certificates from files in PEM format, rather
than storing certificates and keys in a SQLite database, the
way NSS does. There will be a blog post, changelog entries,
and other documentation of the breaking changes.

Review URL: https://codereview.chromium.org//1319703002 .
2015-08-26 14:42:12 +02:00
ajohnsen@google.com 8240d9a4cf Only lower-case ContentType's values if the name is 'charset'.
BUG=https://code.google.com/p/dart/issues/detail?id=21385
R=lrn@google.com, sgjesse@google.com

Review URL: https://codereview.chromium.org//694293002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41456 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-03 12:34:08 +00:00
sgjesse@google.com ac911ff0bf Make the default HTTP server configuration more secure
Add a mechanism for setting default headers to add to all responses.

By default each the HTTP response now will contain the following headers:

  Content-Type: text/plain; charset=utf-8
  X-Frame-Options: SAMEORIGIN
  X-Content-Type-Options: nosniff
  X-XSS-Protection: 1; mode=block

New cookies created are now 'httpOnly' by default.

BUG=http://dartbug.com/19676
R=ajohnsen@google.com

Review URL: https://codereview.chromium.org//443373003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39118 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-12 07:12:03 +00:00
sgjesse@google.com a2875d1768 Fix bug in caching of chunked transfer encoding in HTTP headers
R=ajohnsen@google.com
BUG=http://dartbug.com/20335

Review URL: https://codereview.chromium.org//460653002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39116 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-12 06:39:12 +00:00
ajohnsen@google.com 877d4c2138 Validate headers when added to HttpHeaders.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//364313002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@38009 260f80e4-7a28-3924-810f-c04153c831b5
2014-07-04 11:04:03 +00:00
ajohnsen@google.com 198b11bd9b Add IO service object handler, with initial implementation for HTTP server.
This is tempoary disabling the Socket service handler.

BUG=
R=johnmccutchan@google.com

Review URL: https://codereview.chromium.org//284313011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@36417 260f80e4-7a28-3924-810f-c04153c831b5
2014-05-21 11:12:49 +00:00
kevmoo@google.com c054ad39c3 http_date: produce leading zero on day component
per http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.3

R=ajohnsen@google.com

Review URL: https://codereview.chromium.org//274243002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@36028 260f80e4-7a28-3924-810f-c04153c831b5
2014-05-12 13:32:23 +00:00
sgjesse@google.com 6a8e27ca96 Add fixed content type values for commonly used content types
This add fixed ContentType instances for:

  text/plain; charset=utf-8
  text/html; charset=utf-8
  application/json; charset=utf-8
  application/octet-stream

R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//195893019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@33744 260f80e4-7a28-3924-810f-c04153c831b5
2014-03-17 13:27:54 +00:00
ajohnsen@google.com 8fc417a717 Add validation to construction of Cookie objects.
BUG=https://code.google.com/p/dart/issues/detail?id=17135
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//196723020

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@33741 260f80e4-7a28-3924-810f-c04153c831b5
2014-03-17 12:39:16 +00:00
ajohnsen@google.com b39955232b Skip bad cookies in http headers.
BUG=https://code.google.com/p/dart/issues/detail?id=16540
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//151123003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@32313 260f80e4-7a28-3924-810f-c04153c831b5
2014-02-05 08:31:41 +00:00
ajohnsen@google.com b97593a8df Make dart:io unit-tests pass the analyzer.
BUG=http://code.google.com/p/dart/issues/detail?id=7066
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//87743002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30662 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-26 08:38:29 +00:00
whesse@google.com 2a987cceea Modify tests to use Directory.systemTemp.
BUG=
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//25471003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28219 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-03 13:28:35 +00:00
sgjesse@google.com 869cc6d4c9 Make the parameters map of the HTTP HeaderValue unmodifiable
BUG=http://dartbug.com/8951

R=whesse@google.com

Review URL: https://codereview.chromium.org//21351002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25663 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-31 13:59:46 +00:00
ajohnsen@google.com 10996fd256 Remove _HttpUtils from dart:io.
The Uri rewrite had all but one of these functions public available, so
they are used insted. The decodeHttpEntityString was only used by
HttpMultipartFormData, so moved to that class.

The function parseCookieDate was moved to HttpDate as a private
function. Renamed the file http_utils.dart to http_date.dart to match the content.

BUG=
R=lrn@google.com, whesse@google.com

Review URL: https://codereview.chromium.org//18576006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24783 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-05 09:51:39 +00:00
ajohnsen@google.com 80a28e9f12 Import dart:collection in dart:io unit-tests.
BUG=

Review URL: https://codereview.chromium.org//16948007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23982 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-13 14:24:02 +00:00
ajohnsen@google.com 5ce3b9ddea Clean up dart:io exceptions.
- Introduce IOException.
- Remove HttpParserException.
- Merge RedirectLimitExceededException and RedirectLoopException into
RedirectException.
- Remove 'IO' from FileIOException, DirectoryIOException, LinkIOException
and SocketIOException.

BUG=https://code.google.com/p/dart/issues/detail?id=9955
R=sgjesse@google.com

Review URL: https://codereview.chromium.org//16123036

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23848 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-11 13:15:46 +00:00
sgjesse@google.com ee02857f6a Don't change the case of cookie names and values
R=whesse@google.com
BUG=http://dartbug.com/11011

Review URL: https://codereview.chromium.org//16256012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23582 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-04 09:35:59 +00:00
sgjesse@google.com f13b6178e1 Change fromString constructor to parse static method
on HeaderValue and ContentType.

R=ajohnsen@google.com
BUG=

Review URL: https://codereview.chromium.org//14914002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22406 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-06 07:30:02 +00:00
floitsch@google.com 0a26d0e20b Rename DateTime constants to full names.
BUG= http://dartbug.com/9441

Review URL: https://codereview.chromium.org//13841005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21189 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-10 09:23:26 +00:00
floitsch@google.com 8fd6d0aafd Remove Expect from core library.
Committed: https://code.google.com/p/dart/source/detail?r=19755
Reverted: http://code.google.com/p/dart/source/detail?r=19756

Review URL: https://codereview.chromium.org//12212016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20996 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-05 19:43:16 +00:00
floitsch@google.com 5dc8107c53 Revert "Remove Expect from core library."
This reverts commit 19755.

Review URL: https://codereview.chromium.org//12743005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19756 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-09 03:19:07 +00:00
floitsch@google.com 12dbd2fd70 Remove Expect from core library.
Review URL: https://codereview.chromium.org//12212016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19755 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-09 02:40:37 +00:00
sgjesse@google.com ff47888a0d Make instances of HeaderValue and ContentType immutable
Their parameters map is still mutable though.

R=ajohnsen@google.com

BUG=

Review URL: https://codereview.chromium.org//12440002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19598 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-07 07:25:56 +00:00
ajohnsen@google.com b675e47aa0 Remane io_stream_consumer.dart to io_sink and move out all implementation from IOSink to _IOSinkImpl.
BUG=https://code.google.com/p/dart/issues/detail?id=8873

Review URL: https://codereview.chromium.org//12389050

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19311 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-01 13:33:19 +00:00