Files
node/lib
James M Snell 6192c9892f http: add checkIsHttpToken check for header fields
Ref: https://github.com/nodejs/node-convergence-archive/issues/13

This adds a new check for header and trailer fields names and method
names to ensure that they conform to the HTTP token rule. If they do
not, a `TypeError` is thrown.

Previously this had an additional `strictMode` option that has been
removed in favor of making the strict check the default (and only)
behavior.

Doc and test case are included.

On the client-side
```javascript
var http = require('http');
var url = require('url');
var p = url.parse('http://localhost:8888');
p.headers = {'testing 123': 123};
http.client(p, function(res) { }); // throws
```

On the server-side
```javascript
var http = require('http');
var server = http.createServer(function(req,res) {
  res.setHeader('testing 123', 123); // throws
  res.end('...');
});
```

Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Trevor Norris <trevnorris@nodejs.org>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
PR-URL: https://github.com/nodejs/node/pull/2526
2015-09-25 08:37:57 -07:00
..
2015-08-20 01:14:37 -07:00
2015-06-11 20:24:44 +02:00
2015-05-09 12:10:02 +09:00
2015-08-04 11:56:14 -07:00
2015-07-27 11:48:36 -07:00
2015-06-11 20:24:44 +02:00
2015-09-22 16:43:14 +02:00
2015-06-11 20:24:44 +02:00
2015-09-16 10:29:13 -07:00
2015-01-31 23:47:29 -05:00
2015-08-04 11:56:12 -07:00