vulcan 0.2.5 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +1 -80
- data/lib/vulcan/cli.rb +12 -33
- data/lib/vulcan/version.rb +1 -1
- data/server/bin/make +3 -1
- data/server/lib/spawner.js +4 -9
- data/server/node_modules/connect-form/node_modules/formidable/Readme.md +2 -13
- data/server/node_modules/connect-form/node_modules/formidable/lib/incoming_form.js +7 -19
- data/server/node_modules/connect-form/node_modules/formidable/lib/multipart_parser.js +1 -12
- data/server/node_modules/connect-form/node_modules/formidable/package.json +1 -1
- data/server/node_modules/connect-form/node_modules/formidable/test/fixture/http/special-chars-in-filename/osx-chrome-13.http +10 -0
- data/server/node_modules/connect-form/node_modules/formidable/test/fixture/http/special-chars-in-filename/xp-chrome-12.http +9 -0
- data/server/node_modules/connect-form/node_modules/formidable/test/legacy/simple/test-multipart-parser.js +1 -1
- data/server/node_modules/cradle/lib/cradle.js +1 -0
- data/server/node_modules/cradle/node_modules/vows/LICENSE +20 -0
- data/server/node_modules/cradle/node_modules/vows/Makefile +7 -0
- data/server/node_modules/cradle/node_modules/vows/README.md +39 -0
- data/server/node_modules/cradle/node_modules/vows/bin/vows +515 -0
- data/server/node_modules/cradle/node_modules/vows/lib/assert/error.js +27 -0
- data/server/node_modules/cradle/node_modules/vows/lib/assert/macros.js +215 -0
- data/server/node_modules/cradle/node_modules/vows/lib/assert/utils.js +77 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows.js +193 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/console.js +131 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/context.js +55 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/file.js +29 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/fragments/coverage-foot.html +2 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/fragments/coverage-head.html +61 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/report-html.js +54 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/report-json.js +54 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/coverage/report-plain.js +38 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/extras.js +28 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/dot-matrix.js +67 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/json.js +16 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/silent.js +8 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/spec.js +44 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/watch.js +39 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/reporters/xunit.js +90 -0
- data/server/node_modules/cradle/node_modules/vows/lib/vows/suite.js +319 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/LICENSE +20 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/Makefile +4 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/README.md +72 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/lib/eyes.js +233 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/package.json +14 -0
- data/server/node_modules/cradle/node_modules/vows/node_modules/eyes/test/eyes-test.js +55 -0
- data/server/node_modules/cradle/node_modules/vows/package.json +14 -0
- data/server/node_modules/cradle/node_modules/vows/test/assert-test.js +135 -0
- data/server/node_modules/cradle/node_modules/vows/test/fixtures/isolate/failing.js +18 -0
- data/server/node_modules/cradle/node_modules/vows/test/fixtures/isolate/log.js +18 -0
- data/server/node_modules/cradle/node_modules/vows/test/fixtures/isolate/passing.js +17 -0
- data/server/node_modules/cradle/node_modules/vows/test/fixtures/isolate/stderr.js +18 -0
- data/server/node_modules/cradle/node_modules/vows/test/isolate-test.js +140 -0
- data/server/node_modules/cradle/node_modules/vows/test/testInherit.js +133 -0
- data/server/node_modules/cradle/node_modules/vows/test/vows-error-test.js +51 -0
- data/server/node_modules/cradle/node_modules/vows/test/vows-test.js +374 -0
- data/server/node_modules/cradle/package.json +3 -3
- data/server/node_modules/cradle/test/cache-test.js +7 -6
- data/server/node_modules/cradle/test/cradle-test.js +5 -4
- data/server/node_modules/cradle/test/response-test.js +6 -5
- data/server/node_modules/express/History.md +1 -53
- data/server/node_modules/express/Makefile +9 -3
- data/server/node_modules/express/Readme.md +1 -3
- data/server/node_modules/express/bin/express +66 -65
- data/server/node_modules/express/lib/express.js +1 -1
- data/server/node_modules/express/lib/request.js +9 -23
- data/server/node_modules/express/lib/response.js +2 -3
- data/server/node_modules/express/lib/utils.js +0 -13
- data/server/node_modules/express/lib/view.js +16 -19
- data/server/node_modules/express/lib/view/view.js +1 -2
- data/server/node_modules/express/node_modules/connect/lib/connect.js +1 -1
- data/server/node_modules/express/node_modules/connect/lib/http.js +0 -2
- data/server/node_modules/express/node_modules/connect/lib/middleware/bodyParser.js +31 -135
- data/server/node_modules/express/node_modules/connect/lib/middleware/limit.js +1 -5
- data/server/node_modules/express/node_modules/connect/lib/middleware/session.js +2 -2
- data/server/node_modules/express/node_modules/connect/lib/middleware/static.js +21 -26
- data/server/node_modules/express/node_modules/connect/lib/middleware/staticCache.js +38 -91
- data/server/node_modules/express/node_modules/connect/lib/middleware/vhost.js +1 -1
- data/server/node_modules/express/node_modules/connect/lib/utils.js +4 -11
- data/server/node_modules/express/node_modules/connect/package.json +6 -7
- data/server/node_modules/express/node_modules/connect/test.js +31 -44
- data/server/node_modules/express/node_modules/mime/index.js +1 -0
- data/server/node_modules/express/node_modules/mime/mime.js +3 -3
- data/server/node_modules/express/node_modules/mime/{types/mime.types → mime.types} +0 -0
- data/server/node_modules/express/node_modules/mime/{types/node.types → node.types} +0 -17
- data/server/node_modules/express/node_modules/mime/package.json +10 -21
- data/server/node_modules/express/node_modules/mime/test.js +3 -2
- data/server/node_modules/express/node_modules/qs/History.md +0 -11
- data/server/node_modules/express/node_modules/qs/Makefile +3 -1
- data/server/node_modules/express/node_modules/qs/Readme.md +4 -2
- data/server/node_modules/express/node_modules/qs/lib/querystring.js +74 -100
- data/server/node_modules/express/node_modules/qs/package.json +2 -9
- data/server/node_modules/express/node_modules/qs/support/expresso/History.md +128 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/Makefile +53 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/Readme.md +61 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/bin/expresso +856 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/docs/api.html +1080 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/docs/index.html +377 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/docs/index.md +290 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/docs/layout/foot.html +3 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/docs/layout/head.html +42 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/lib/bar.js +4 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/lib/foo.js +16 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/package.json +12 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/assert.test.js +91 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/async.test.js +12 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/bar.test.js +13 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/foo.test.js +14 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/http.test.js +146 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/serial/async.test.js +39 -0
- data/server/node_modules/express/node_modules/qs/support/expresso/test/serial/http.test.js +48 -0
- data/server/node_modules/express/node_modules/qs/support/should/History.md +22 -0
- data/server/node_modules/express/node_modules/qs/support/should/Makefile +6 -0
- data/server/node_modules/express/node_modules/qs/support/should/Readme.md +248 -0
- data/server/node_modules/express/node_modules/qs/support/should/examples/runner.js +53 -0
- data/server/node_modules/express/node_modules/qs/support/should/index.js +2 -0
- data/server/node_modules/express/node_modules/qs/support/should/lib/eql.js +91 -0
- data/server/node_modules/express/node_modules/qs/support/should/lib/should.js +548 -0
- data/server/node_modules/express/node_modules/qs/support/should/package.json +8 -0
- data/server/node_modules/express/node_modules/qs/support/should/test/should.test.js +358 -0
- data/server/node_modules/express/node_modules/qs/test/{parse.js → parse.test.js} +2 -1
- data/server/node_modules/express/node_modules/qs/test/{stringify.js → stringify.test.js} +0 -0
- data/server/node_modules/express/package.json +8 -9
- data/server/node_modules/node-uuid/README.md +67 -166
- data/server/node_modules/node-uuid/package.json +3 -5
- data/server/node_modules/node-uuid/{benchmark → test}/benchmark-native.c +0 -0
- data/server/node_modules/node-uuid/test/benchmark.js +27 -0
- data/server/node_modules/node-uuid/test/test.html +0 -3
- data/server/node_modules/node-uuid/test/test.js +57 -214
- data/server/node_modules/node-uuid/uuid.js +56 -225
- data/server/node_modules/restler/README.md +7 -20
- data/server/node_modules/restler/bin/restler +1 -1
- data/server/node_modules/restler/lib/multipartform.js +8 -9
- data/server/node_modules/restler/lib/restler.js +22 -64
- data/server/node_modules/restler/package.json +2 -2
- data/server/node_modules/restler/test/restler.js +2 -22
- data/server/node_modules/restler/test/test_helper.js +1 -20
- data/server/package.json +10 -10
- data/server/web.js +7 -30
- metadata +96 -89
- data/server/node_modules/connect-form/node_modules/formidable/test/fixture/file/plain.txt +0 -1
- data/server/node_modules/connect-form/node_modules/formidable/test/fixture/http/no-filename/generic.http +0 -13
- data/server/node_modules/connect-form/node_modules/formidable/test/fixture/js/no-filename.js +0 -3
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/Makefile +0 -14
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/Readme.md +0 -286
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/TODO +0 -3
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/benchmark/bench-multipart-parser.js +0 -70
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/example/post.js +0 -43
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/example/upload.js +0 -48
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/index.js +0 -1
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/file.js +0 -61
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/incoming_form.js +0 -377
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/index.js +0 -3
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/multipart_parser.js +0 -312
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/querystring_parser.js +0 -25
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/lib/util.js +0 -6
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/package.json +0 -22
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/common.js +0 -19
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/file/funkyfilename.txt +0 -1
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/file/plain.txt +0 -1
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/no-filename/generic.http +0 -13
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/info.md +0 -3
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/osx-chrome-13.http +0 -26
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/osx-firefox-3.6.http +0 -24
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/osx-safari-5.http +0 -23
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/xp-chrome-12.http +0 -24
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/xp-ie-7.http +0 -22
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/xp-ie-8.http +0 -22
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/xp-safari-5.http +0 -22
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/js/no-filename.js +0 -3
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/js/special-chars-in-filename.js +0 -21
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/multi_video.upload +0 -0
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/fixture/multipart.js +0 -72
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/integration/test-fixtures.js +0 -89
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/common.js +0 -24
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/integration/test-multipart-parser.js +0 -80
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/simple/test-file.js +0 -104
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/simple/test-incoming-form.js +0 -715
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/simple/test-multipart-parser.js +0 -50
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/simple/test-querystring-parser.js +0 -45
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/system/test-multi-video-upload.js +0 -72
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/run.js +0 -2
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/unit/test-incoming-form.js +0 -63
- data/server/node_modules/express/node_modules/connect/node_modules/formidable/tool/record.js +0 -47
- data/server/node_modules/express/node_modules/mkdirp/LICENSE +0 -21
- data/server/node_modules/express/node_modules/mkdirp/README.markdown +0 -21
- data/server/node_modules/express/node_modules/mkdirp/examples/pow.js +0 -6
- data/server/node_modules/express/node_modules/mkdirp/examples/pow.js.orig +0 -6
- data/server/node_modules/express/node_modules/mkdirp/examples/pow.js.rej +0 -19
- data/server/node_modules/express/node_modules/mkdirp/index.js +0 -20
- data/server/node_modules/express/node_modules/mkdirp/package.json +0 -23
- data/server/node_modules/express/node_modules/mkdirp/test/mkdirp.js +0 -28
- data/server/node_modules/express/node_modules/mkdirp/test/race.js +0 -41
- data/server/node_modules/express/node_modules/mkdirp/test/rel.js +0 -32
- data/server/node_modules/express/node_modules/qs/test/mocha.opts +0 -2
- data/server/node_modules/express/testing/foo/app.js +0 -35
- data/server/node_modules/express/testing/foo/package.json +0 -9
- data/server/node_modules/express/testing/foo/public/stylesheets/style.css +0 -8
- data/server/node_modules/express/testing/foo/routes/index.js +0 -10
- data/server/node_modules/express/testing/foo/views/index.jade +0 -2
- data/server/node_modules/express/testing/foo/views/layout.jade +0 -6
- data/server/node_modules/express/testing/index.js +0 -43
- data/server/node_modules/express/testing/public/test.txt +0 -2971
- data/server/node_modules/express/testing/views/page.html +0 -1
- data/server/node_modules/express/testing/views/page.jade +0 -3
- data/server/node_modules/express/testing/views/test.md +0 -1
- data/server/node_modules/express/testing/views/user/index.jade +0 -1
- data/server/node_modules/express/testing/views/user/list.jade +0 -1
- data/server/node_modules/node-uuid/benchmark/README.md +0 -53
- data/server/node_modules/node-uuid/benchmark/bench.gnu +0 -174
- data/server/node_modules/node-uuid/benchmark/bench.sh +0 -34
- data/server/node_modules/node-uuid/benchmark/benchmark.js +0 -84
- data/server/node_modules/node-uuid/test/benchmark-native +0 -0
- data/server/node_modules/node-uuid/test/compare_v1.js +0 -63
@@ -1,24 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Host: localhost:8080
|
3
|
-
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.22) Gecko/20110902 Firefox/3.6.22
|
4
|
-
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
|
5
|
-
Accept-Language: en-us,en;q=0.5
|
6
|
-
Accept-Encoding: gzip,deflate
|
7
|
-
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
|
8
|
-
Keep-Alive: 115
|
9
|
-
Connection: keep-alive
|
10
|
-
Referer: http://localhost:8080/
|
11
|
-
Content-Type: multipart/form-data; boundary=---------------------------9849436581144108930470211272
|
12
|
-
Content-Length: 438
|
13
|
-
|
14
|
-
-----------------------------9849436581144108930470211272
|
15
|
-
Content-Disposition: form-data; name="title"
|
16
|
-
|
17
|
-
Weird filename
|
18
|
-
-----------------------------9849436581144108930470211272
|
19
|
-
Content-Disposition: form-data; name="upload"; filename=": \ ? % * | " < > . ☃ ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
20
|
-
Content-Type: text/plain
|
21
|
-
|
22
|
-
I am a text file with a funky name!
|
23
|
-
|
24
|
-
-----------------------------9849436581144108930470211272--
|
@@ -1,23 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Host: localhost:8080
|
3
|
-
Origin: http://localhost:8080
|
4
|
-
Content-Length: 383
|
5
|
-
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_8; en-us) AppleWebKit/533.21.1 (KHTML, like Gecko) Version/5.0.5 Safari/533.21.1
|
6
|
-
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryQJZ1gvhvdgfisJPJ
|
7
|
-
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
|
8
|
-
Referer: http://localhost:8080/
|
9
|
-
Accept-Language: en-us
|
10
|
-
Accept-Encoding: gzip, deflate
|
11
|
-
Connection: keep-alive
|
12
|
-
|
13
|
-
------WebKitFormBoundaryQJZ1gvhvdgfisJPJ
|
14
|
-
Content-Disposition: form-data; name="title"
|
15
|
-
|
16
|
-
Weird filename
|
17
|
-
------WebKitFormBoundaryQJZ1gvhvdgfisJPJ
|
18
|
-
Content-Disposition: form-data; name="upload"; filename=": \ ? % * | %22 < > . ? ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
19
|
-
Content-Type: text/plain
|
20
|
-
|
21
|
-
I am a text file with a funky name!
|
22
|
-
|
23
|
-
------WebKitFormBoundaryQJZ1gvhvdgfisJPJ--
|
@@ -1,24 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Host: 192.168.56.1:8080
|
3
|
-
Connection: keep-alive
|
4
|
-
Referer: http://192.168.56.1:8080/
|
5
|
-
Content-Length: 344
|
6
|
-
Cache-Control: max-age=0
|
7
|
-
Origin: http://192.168.56.1:8080
|
8
|
-
User-Agent: Mozilla/5.0 (Windows NT 5.1) AppleWebKit/534.30 (KHTML, like Gecko) Chrome/12.0.742.122 Safari/534.30
|
9
|
-
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryEvqBNplR3ByrwQPa
|
10
|
-
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
|
11
|
-
Accept-Encoding: gzip,deflate,sdch
|
12
|
-
Accept-Language: de-DE,de;q=0.8,en-US;q=0.6,en;q=0.4
|
13
|
-
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.3
|
14
|
-
|
15
|
-
------WebKitFormBoundaryEvqBNplR3ByrwQPa
|
16
|
-
Content-Disposition: form-data; name="title"
|
17
|
-
|
18
|
-
Weird filename
|
19
|
-
------WebKitFormBoundaryEvqBNplR3ByrwQPa
|
20
|
-
Content-Disposition: form-data; name="upload"; filename=" ? % * | %22 < > . ? ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
21
|
-
Content-Type: text/plain
|
22
|
-
|
23
|
-
|
24
|
-
------WebKitFormBoundaryEvqBNplR3ByrwQPa--
|
@@ -1,22 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, */*
|
3
|
-
Referer: http://192.168.56.1:8080/
|
4
|
-
Accept-Language: de
|
5
|
-
User-Agent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1)
|
6
|
-
Content-Type: multipart/form-data; boundary=---------------------------7db1fe232017c
|
7
|
-
Accept-Encoding: gzip, deflate
|
8
|
-
Host: 192.168.56.1:8080
|
9
|
-
Content-Length: 368
|
10
|
-
Connection: Keep-Alive
|
11
|
-
Cache-Control: no-cache
|
12
|
-
|
13
|
-
-----------------------------7db1fe232017c
|
14
|
-
Content-Disposition: form-data; name="title"
|
15
|
-
|
16
|
-
Weird filename
|
17
|
-
-----------------------------7db1fe232017c
|
18
|
-
Content-Disposition: form-data; name="upload"; filename=" ? % * | " < > . ☃ ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
19
|
-
Content-Type: application/octet-stream
|
20
|
-
|
21
|
-
|
22
|
-
-----------------------------7db1fe232017c--
|
@@ -1,22 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Accept: image/gif, image/jpeg, image/pjpeg, image/pjpeg, application/x-shockwave-flash, */*
|
3
|
-
Referer: http://192.168.56.1:8080/
|
4
|
-
Accept-Language: de
|
5
|
-
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)
|
6
|
-
Content-Type: multipart/form-data; boundary=---------------------------7db3a8372017c
|
7
|
-
Accept-Encoding: gzip, deflate
|
8
|
-
Host: 192.168.56.1:8080
|
9
|
-
Content-Length: 368
|
10
|
-
Connection: Keep-Alive
|
11
|
-
Cache-Control: no-cache
|
12
|
-
|
13
|
-
-----------------------------7db3a8372017c
|
14
|
-
Content-Disposition: form-data; name="title"
|
15
|
-
|
16
|
-
Weird filename
|
17
|
-
-----------------------------7db3a8372017c
|
18
|
-
Content-Disposition: form-data; name="upload"; filename=" ? % * | " < > . ☃ ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
19
|
-
Content-Type: application/octet-stream
|
20
|
-
|
21
|
-
|
22
|
-
-----------------------------7db3a8372017c--
|
@@ -1,22 +0,0 @@
|
|
1
|
-
POST /upload HTTP/1.1
|
2
|
-
Host: 192.168.56.1:8080
|
3
|
-
Referer: http://192.168.56.1:8080/
|
4
|
-
Accept: application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
|
5
|
-
Accept-Language: en-US
|
6
|
-
Origin: http://192.168.56.1:8080
|
7
|
-
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/533.19.4 (KHTML, like Gecko) Version/5.0.3 Safari/533.19.4
|
8
|
-
Accept-Encoding: gzip, deflate
|
9
|
-
Content-Type: multipart/form-data; boundary=----WebKitFormBoundarykmaWSUbu697WN9TM
|
10
|
-
Content-Length: 344
|
11
|
-
Connection: keep-alive
|
12
|
-
|
13
|
-
------WebKitFormBoundarykmaWSUbu697WN9TM
|
14
|
-
Content-Disposition: form-data; name="title"
|
15
|
-
|
16
|
-
Weird filename
|
17
|
-
------WebKitFormBoundarykmaWSUbu697WN9TM
|
18
|
-
Content-Disposition: form-data; name="upload"; filename=" ? % * | %22 < > . ? ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt"
|
19
|
-
Content-Type: text/plain
|
20
|
-
|
21
|
-
|
22
|
-
------WebKitFormBoundarykmaWSUbu697WN9TM--
|
@@ -1,21 +0,0 @@
|
|
1
|
-
var properFilename = 'funkyfilename.txt';
|
2
|
-
|
3
|
-
function expect(filename) {
|
4
|
-
return [
|
5
|
-
{type: 'field', name: 'title', value: 'Weird filename'},
|
6
|
-
{type: 'file', name: 'upload', filename: filename, fixture: properFilename},
|
7
|
-
];
|
8
|
-
};
|
9
|
-
|
10
|
-
var webkit = " ? % * | \" < > . ? ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt";
|
11
|
-
var ffOrIe = " ? % * | \" < > . ☃ ; ' @ # $ ^ & ( ) - _ = + { } [ ] ` ~.txt";
|
12
|
-
|
13
|
-
module.exports = {
|
14
|
-
'osx-chrome-13.http' : expect(webkit),
|
15
|
-
'osx-firefox-3.6.http' : expect(ffOrIe),
|
16
|
-
'osx-safari-5.http' : expect(webkit),
|
17
|
-
'xp-chrome-12.http' : expect(webkit),
|
18
|
-
'xp-ie-7.http' : expect(ffOrIe),
|
19
|
-
'xp-ie-8.http' : expect(ffOrIe),
|
20
|
-
'xp-safari-5.http' : expect(webkit),
|
21
|
-
};
|
Binary file
|
@@ -1,72 +0,0 @@
|
|
1
|
-
exports['rfc1867'] =
|
2
|
-
{ boundary: 'AaB03x',
|
3
|
-
raw:
|
4
|
-
'--AaB03x\r\n'+
|
5
|
-
'content-disposition: form-data; name="field1"\r\n'+
|
6
|
-
'\r\n'+
|
7
|
-
'Joe Blow\r\nalmost tricked you!\r\n'+
|
8
|
-
'--AaB03x\r\n'+
|
9
|
-
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
10
|
-
'Content-Type: text/plain\r\n'+
|
11
|
-
'\r\n'+
|
12
|
-
'... contents of file1.txt ...\r\r\n'+
|
13
|
-
'--AaB03x--\r\n',
|
14
|
-
parts:
|
15
|
-
[ { headers: {
|
16
|
-
'content-disposition': 'form-data; name="field1"',
|
17
|
-
},
|
18
|
-
data: 'Joe Blow\r\nalmost tricked you!',
|
19
|
-
},
|
20
|
-
{ headers: {
|
21
|
-
'content-disposition': 'form-data; name="pics"; filename="file1.txt"',
|
22
|
-
'Content-Type': 'text/plain',
|
23
|
-
},
|
24
|
-
data: '... contents of file1.txt ...\r',
|
25
|
-
}
|
26
|
-
]
|
27
|
-
};
|
28
|
-
|
29
|
-
exports['noTrailing\r\n'] =
|
30
|
-
{ boundary: 'AaB03x',
|
31
|
-
raw:
|
32
|
-
'--AaB03x\r\n'+
|
33
|
-
'content-disposition: form-data; name="field1"\r\n'+
|
34
|
-
'\r\n'+
|
35
|
-
'Joe Blow\r\nalmost tricked you!\r\n'+
|
36
|
-
'--AaB03x\r\n'+
|
37
|
-
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
38
|
-
'Content-Type: text/plain\r\n'+
|
39
|
-
'\r\n'+
|
40
|
-
'... contents of file1.txt ...\r\r\n'+
|
41
|
-
'--AaB03x--',
|
42
|
-
parts:
|
43
|
-
[ { headers: {
|
44
|
-
'content-disposition': 'form-data; name="field1"',
|
45
|
-
},
|
46
|
-
data: 'Joe Blow\r\nalmost tricked you!',
|
47
|
-
},
|
48
|
-
{ headers: {
|
49
|
-
'content-disposition': 'form-data; name="pics"; filename="file1.txt"',
|
50
|
-
'Content-Type': 'text/plain',
|
51
|
-
},
|
52
|
-
data: '... contents of file1.txt ...\r',
|
53
|
-
}
|
54
|
-
]
|
55
|
-
};
|
56
|
-
|
57
|
-
exports['emptyHeader'] =
|
58
|
-
{ boundary: 'AaB03x',
|
59
|
-
raw:
|
60
|
-
'--AaB03x\r\n'+
|
61
|
-
'content-disposition: form-data; name="field1"\r\n'+
|
62
|
-
': foo\r\n'+
|
63
|
-
'\r\n'+
|
64
|
-
'Joe Blow\r\nalmost tricked you!\r\n'+
|
65
|
-
'--AaB03x\r\n'+
|
66
|
-
'content-disposition: form-data; name="pics"; filename="file1.txt"\r\n'+
|
67
|
-
'Content-Type: text/plain\r\n'+
|
68
|
-
'\r\n'+
|
69
|
-
'... contents of file1.txt ...\r\r\n'+
|
70
|
-
'--AaB03x--\r\n',
|
71
|
-
expectError: true,
|
72
|
-
};
|
@@ -1,89 +0,0 @@
|
|
1
|
-
var hashish = require('hashish');
|
2
|
-
var fs = require('fs');
|
3
|
-
var findit = require('findit');
|
4
|
-
var path = require('path');
|
5
|
-
var http = require('http');
|
6
|
-
var net = require('net');
|
7
|
-
var assert = require('assert');
|
8
|
-
|
9
|
-
var common = require('../common');
|
10
|
-
var formidable = common.formidable;
|
11
|
-
|
12
|
-
var server = http.createServer();
|
13
|
-
server.listen(common.port, findFixtures);
|
14
|
-
|
15
|
-
function findFixtures() {
|
16
|
-
var fixtures = [];
|
17
|
-
findit
|
18
|
-
.sync(common.dir.fixture + '/js')
|
19
|
-
.forEach(function(jsPath) {
|
20
|
-
if (!/\.js$/.test(jsPath)) return;
|
21
|
-
|
22
|
-
var group = path.basename(jsPath, '.js');
|
23
|
-
hashish.forEach(require(jsPath), function(fixture, name) {
|
24
|
-
fixtures.push({
|
25
|
-
name : group + '/' + name,
|
26
|
-
fixture : fixture,
|
27
|
-
});
|
28
|
-
});
|
29
|
-
});
|
30
|
-
|
31
|
-
testNext(fixtures);
|
32
|
-
}
|
33
|
-
|
34
|
-
function testNext(fixtures) {
|
35
|
-
var fixture = fixtures.shift();
|
36
|
-
if (!fixture) return server.close();
|
37
|
-
|
38
|
-
var name = fixture.name;
|
39
|
-
var fixture = fixture.fixture;
|
40
|
-
|
41
|
-
uploadFixture(name, function(err, parts) {
|
42
|
-
if (err) throw err;
|
43
|
-
|
44
|
-
fixture.forEach(function(expectedPart, i) {
|
45
|
-
var parsedPart = parts[i];
|
46
|
-
assert.equal(parsedPart.type, expectedPart.type);
|
47
|
-
assert.equal(parsedPart.name, expectedPart.name);
|
48
|
-
|
49
|
-
if (parsedPart.type === 'file') {
|
50
|
-
var filename = parsedPart.value.name;
|
51
|
-
assert.equal(filename, expectedPart.filename);
|
52
|
-
}
|
53
|
-
});
|
54
|
-
|
55
|
-
testNext(fixtures);
|
56
|
-
});
|
57
|
-
};
|
58
|
-
|
59
|
-
function uploadFixture(name, cb) {
|
60
|
-
server.once('request', function(req, res) {
|
61
|
-
var form = new formidable.IncomingForm();
|
62
|
-
form.uploadDir = common.dir.tmp;
|
63
|
-
form.parse(req);
|
64
|
-
|
65
|
-
function callback() {
|
66
|
-
var realCallback = cb;
|
67
|
-
cb = function() {};
|
68
|
-
realCallback.apply(null, arguments);
|
69
|
-
}
|
70
|
-
|
71
|
-
var parts = [];
|
72
|
-
form
|
73
|
-
.on('error', callback)
|
74
|
-
.on('fileBegin', function(name, value) {
|
75
|
-
parts.push({type: 'file', name: name, value: value});
|
76
|
-
})
|
77
|
-
.on('field', function(name, value) {
|
78
|
-
parts.push({type: 'field', name: name, value: value});
|
79
|
-
})
|
80
|
-
.on('end', function() {
|
81
|
-
callback(null, parts);
|
82
|
-
});
|
83
|
-
});
|
84
|
-
|
85
|
-
var socket = net.createConnection(common.port);
|
86
|
-
var file = fs.createReadStream(common.dir.fixture + '/http/' + name);
|
87
|
-
|
88
|
-
file.pipe(socket);
|
89
|
-
}
|
data/server/node_modules/express/node_modules/connect/node_modules/formidable/test/legacy/common.js
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
var path = require('path'),
|
2
|
-
fs = require('fs');
|
3
|
-
|
4
|
-
try {
|
5
|
-
global.Gently = require('gently');
|
6
|
-
} catch (e) {
|
7
|
-
throw new Error('this test suite requires node-gently');
|
8
|
-
}
|
9
|
-
|
10
|
-
exports.lib = path.join(__dirname, '../../lib');
|
11
|
-
|
12
|
-
global.GENTLY = new Gently();
|
13
|
-
|
14
|
-
global.assert = require('assert');
|
15
|
-
global.TEST_PORT = 13532;
|
16
|
-
global.TEST_FIXTURES = path.join(__dirname, '../fixture');
|
17
|
-
global.TEST_TMP = path.join(__dirname, '../tmp');
|
18
|
-
|
19
|
-
// Stupid new feature in node that complains about gently attaching too many
|
20
|
-
// listeners to process 'exit'. This is a workaround until I can think of a
|
21
|
-
// better way to deal with this.
|
22
|
-
if (process.setMaxListeners) {
|
23
|
-
process.setMaxListeners(10000);
|
24
|
-
}
|
@@ -1,80 +0,0 @@
|
|
1
|
-
var common = require('../common');
|
2
|
-
var CHUNK_LENGTH = 10,
|
3
|
-
multipartParser = require(common.lib + '/multipart_parser'),
|
4
|
-
MultipartParser = multipartParser.MultipartParser,
|
5
|
-
parser = new MultipartParser(),
|
6
|
-
fixtures = require(TEST_FIXTURES + '/multipart'),
|
7
|
-
Buffer = require('buffer').Buffer;
|
8
|
-
|
9
|
-
Object.keys(fixtures).forEach(function(name) {
|
10
|
-
var fixture = fixtures[name],
|
11
|
-
buffer = new Buffer(Buffer.byteLength(fixture.raw, 'binary')),
|
12
|
-
offset = 0,
|
13
|
-
chunk,
|
14
|
-
nparsed,
|
15
|
-
|
16
|
-
parts = [],
|
17
|
-
part = null,
|
18
|
-
headerField,
|
19
|
-
headerValue,
|
20
|
-
endCalled = '';
|
21
|
-
|
22
|
-
parser.initWithBoundary(fixture.boundary);
|
23
|
-
parser.onPartBegin = function() {
|
24
|
-
part = {headers: {}, data: ''};
|
25
|
-
parts.push(part);
|
26
|
-
headerField = '';
|
27
|
-
headerValue = '';
|
28
|
-
};
|
29
|
-
|
30
|
-
parser.onHeaderField = function(b, start, end) {
|
31
|
-
headerField += b.toString('ascii', start, end);
|
32
|
-
};
|
33
|
-
|
34
|
-
parser.onHeaderValue = function(b, start, end) {
|
35
|
-
headerValue += b.toString('ascii', start, end);
|
36
|
-
}
|
37
|
-
|
38
|
-
parser.onHeaderEnd = function() {
|
39
|
-
part.headers[headerField] = headerValue;
|
40
|
-
headerField = '';
|
41
|
-
headerValue = '';
|
42
|
-
};
|
43
|
-
|
44
|
-
parser.onPartData = function(b, start, end) {
|
45
|
-
var str = b.toString('ascii', start, end);
|
46
|
-
part.data += b.slice(start, end);
|
47
|
-
}
|
48
|
-
|
49
|
-
parser.onEnd = function() {
|
50
|
-
endCalled = true;
|
51
|
-
}
|
52
|
-
|
53
|
-
buffer.write(fixture.raw, 'binary', 0);
|
54
|
-
|
55
|
-
while (offset < buffer.length) {
|
56
|
-
if (offset + CHUNK_LENGTH < buffer.length) {
|
57
|
-
chunk = buffer.slice(offset, offset+CHUNK_LENGTH);
|
58
|
-
} else {
|
59
|
-
chunk = buffer.slice(offset, buffer.length);
|
60
|
-
}
|
61
|
-
offset = offset + CHUNK_LENGTH;
|
62
|
-
|
63
|
-
nparsed = parser.write(chunk);
|
64
|
-
if (nparsed != chunk.length) {
|
65
|
-
if (fixture.expectError) {
|
66
|
-
return;
|
67
|
-
}
|
68
|
-
puts('-- ERROR --');
|
69
|
-
p(chunk.toString('ascii'));
|
70
|
-
throw new Error(chunk.length+' bytes written, but only '+nparsed+' bytes parsed!');
|
71
|
-
}
|
72
|
-
}
|
73
|
-
|
74
|
-
if (fixture.expectError) {
|
75
|
-
throw new Error('expected parse error did not happen');
|
76
|
-
}
|
77
|
-
|
78
|
-
assert.ok(endCalled);
|
79
|
-
assert.deepEqual(parts, fixture.parts);
|
80
|
-
});
|