fsevents 1.0.17 → 1.0.18-0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fsevents might be problematic. Click here for more details.
- package/fsevents.js +3 -0
- package/install.js +7 -0
- package/node_modules/abbrev/abbrev.js +0 -1
- package/node_modules/abbrev/package.json +16 -13
- package/node_modules/ansi-regex/index.js +1 -1
- package/node_modules/ansi-regex/package.json +32 -21
- package/node_modules/ansi-regex/readme.md +10 -2
- package/node_modules/aproba/README.md +33 -3
- package/node_modules/aproba/index.js +71 -30
- package/node_modules/aproba/package.json +14 -14
- package/node_modules/aws4/aws4.js +15 -6
- package/node_modules/aws4/package.json +10 -10
- package/node_modules/bcrypt-pbkdf/index.js +1 -4
- package/node_modules/bcrypt-pbkdf/package.json +24 -12
- package/node_modules/gauge/CHANGELOG.md +10 -0
- package/node_modules/gauge/index.js +9 -6
- package/node_modules/gauge/package.json +11 -12
- package/node_modules/jsbn/index.js +8 -9
- package/node_modules/jsbn/package.json +15 -11
- package/node_modules/mime-db/HISTORY.md +16 -0
- package/node_modules/mime-db/db.json +41 -2
- package/node_modules/mime-db/package.json +23 -22
- package/node_modules/mime-types/HISTORY.md +6 -0
- package/node_modules/mime-types/package.json +14 -13
- package/node_modules/node-pre-gyp/CHANGELOG.md +4 -0
- package/node_modules/node-pre-gyp/lib/node-pre-gyp.js +1 -1
- package/node_modules/node-pre-gyp/lib/util/abi_crosswalk.json +52 -0
- package/node_modules/node-pre-gyp/package.json +15 -19
- package/node_modules/object-assign/index.js +11 -4
- package/node_modules/object-assign/package.json +22 -18
- package/node_modules/object-assign/readme.md +8 -3
- package/node_modules/qs/.eslintrc +3 -3
- package/node_modules/qs/CHANGELOG.md +12 -0
- package/node_modules/qs/README.md +34 -1
- package/node_modules/qs/dist/qs.js +32 -19
- package/node_modules/qs/lib/parse.js +9 -9
- package/node_modules/qs/lib/stringify.js +22 -9
- package/node_modules/qs/lib/utils.js +1 -1
- package/node_modules/qs/package.json +17 -17
- package/node_modules/qs/test/.eslintrc +1 -0
- package/node_modules/qs/test/parse.js +29 -4
- package/node_modules/qs/test/stringify.js +1 -1
- package/node_modules/rc/package.json +14 -10
- package/node_modules/sshpk/lib/identity.js +23 -1
- package/node_modules/sshpk/package.json +10 -10
- package/node_modules/strip-json-comments/index.js +70 -0
- package/node_modules/strip-json-comments/package.json +28 -30
- package/node_modules/strip-json-comments/readme.md +12 -28
- package/node_modules/supports-color/index.js +20 -2
- package/node_modules/supports-color/package.json +32 -31
- package/node_modules/supports-color/readme.md +6 -14
- package/package.json +2 -5
- package/node_modules/chalk/node_modules/supports-color/index.js +0 -50
- package/node_modules/chalk/node_modules/supports-color/package.json +0 -113
- package/node_modules/chalk/node_modules/supports-color/readme.md +0 -36
- package/node_modules/qs/CONTRIBUTING.md +0 -1
- package/node_modules/strip-json-comments/cli.js +0 -41
- package/node_modules/strip-json-comments/strip-json-comments.js +0 -73
- package/node_modules/supports-color/cli.js +0 -28
- /package/node_modules/{chalk/node_modules/supports-color → supports-color}/license +0 -0
package/fsevents.js
CHANGED
@@ -6,6 +6,9 @@
|
|
6
6
|
/* jshint node:true */
|
7
7
|
'use strict';
|
8
8
|
|
9
|
+
if (process.platform !== 'darwin')
|
10
|
+
throw new Error('Module \'fsevents\' is not compatible with platform \'' + process.platform + '\'');
|
11
|
+
|
9
12
|
var path = require('path');
|
10
13
|
var binary = require('node-pre-gyp');
|
11
14
|
var Native = require(binary.find(path.join(__dirname, 'package.json')));
|
package/install.js
ADDED
@@ -14,19 +14,19 @@
|
|
14
14
|
]
|
15
15
|
],
|
16
16
|
"_from": "abbrev@>=1.0.0 <2.0.0",
|
17
|
-
"_id": "abbrev@1.0
|
17
|
+
"_id": "abbrev@1.1.0",
|
18
18
|
"_inCache": true,
|
19
19
|
"_location": "/abbrev",
|
20
|
-
"_nodeVersion": "
|
20
|
+
"_nodeVersion": "8.0.0-pre",
|
21
21
|
"_npmOperationalInternal": {
|
22
|
-
"host": "packages-
|
23
|
-
"tmp": "tmp/abbrev-1.0.
|
22
|
+
"host": "packages-12-west.internal.npmjs.com",
|
23
|
+
"tmp": "tmp/abbrev-1.1.0.tgz_1487054000015_0.9229173036292195"
|
24
24
|
},
|
25
25
|
"_npmUser": {
|
26
26
|
"name": "isaacs",
|
27
27
|
"email": "i@izs.me"
|
28
28
|
},
|
29
|
-
"_npmVersion": "3.
|
29
|
+
"_npmVersion": "4.3.0",
|
30
30
|
"_phantomChildren": {},
|
31
31
|
"_requested": {
|
32
32
|
"raw": "abbrev@1",
|
@@ -41,8 +41,8 @@
|
|
41
41
|
"/nopt",
|
42
42
|
"/tap/nopt"
|
43
43
|
],
|
44
|
-
"_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.
|
45
|
-
"_shasum": "
|
44
|
+
"_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.0.tgz",
|
45
|
+
"_shasum": "d0554c2256636e2f56e7c2e5ad183f859428d81f",
|
46
46
|
"_shrinkwrap": null,
|
47
47
|
"_spec": "abbrev@1",
|
48
48
|
"_where": "/Users/eshanker/Code/fsevents/node_modules/nopt",
|
@@ -56,17 +56,17 @@
|
|
56
56
|
"dependencies": {},
|
57
57
|
"description": "Like ruby's abbrev module, but in js",
|
58
58
|
"devDependencies": {
|
59
|
-
"tap": "^
|
59
|
+
"tap": "^10.1"
|
60
60
|
},
|
61
61
|
"directories": {},
|
62
62
|
"dist": {
|
63
|
-
"shasum": "
|
64
|
-
"tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.
|
63
|
+
"shasum": "d0554c2256636e2f56e7c2e5ad183f859428d81f",
|
64
|
+
"tarball": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.0.tgz"
|
65
65
|
},
|
66
66
|
"files": [
|
67
67
|
"abbrev.js"
|
68
68
|
],
|
69
|
-
"gitHead": "
|
69
|
+
"gitHead": "7136d4d95449dc44115d4f78b80ec907724f64e0",
|
70
70
|
"homepage": "https://github.com/isaacs/abbrev-js#readme",
|
71
71
|
"license": "ISC",
|
72
72
|
"main": "abbrev.js",
|
@@ -84,7 +84,10 @@
|
|
84
84
|
"url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
|
85
85
|
},
|
86
86
|
"scripts": {
|
87
|
-
"
|
87
|
+
"postpublish": "git push origin --all; git push origin --tags",
|
88
|
+
"postversion": "npm publish",
|
89
|
+
"preversion": "npm test",
|
90
|
+
"test": "tap test.js --100"
|
88
91
|
},
|
89
|
-
"version": "1.0
|
92
|
+
"version": "1.1.0"
|
90
93
|
}
|
@@ -14,15 +14,19 @@
|
|
14
14
|
]
|
15
15
|
],
|
16
16
|
"_from": "ansi-regex@>=2.0.0 <3.0.0",
|
17
|
-
"_id": "ansi-regex@2.
|
17
|
+
"_id": "ansi-regex@2.1.1",
|
18
18
|
"_inCache": true,
|
19
19
|
"_location": "/ansi-regex",
|
20
|
-
"_nodeVersion": "0.
|
20
|
+
"_nodeVersion": "0.10.32",
|
21
|
+
"_npmOperationalInternal": {
|
22
|
+
"host": "packages-18-east.internal.npmjs.com",
|
23
|
+
"tmp": "tmp/ansi-regex-2.1.1.tgz_1484363378013_0.4482989883981645"
|
24
|
+
},
|
21
25
|
"_npmUser": {
|
22
|
-
"name": "
|
23
|
-
"email": "
|
26
|
+
"name": "qix",
|
27
|
+
"email": "i.am.qix@gmail.com"
|
24
28
|
},
|
25
|
-
"_npmVersion": "2.
|
29
|
+
"_npmVersion": "2.14.2",
|
26
30
|
"_phantomChildren": {},
|
27
31
|
"_requested": {
|
28
32
|
"raw": "ansi-regex@^2.0.0",
|
@@ -37,8 +41,8 @@
|
|
37
41
|
"/has-ansi",
|
38
42
|
"/strip-ansi"
|
39
43
|
],
|
40
|
-
"_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.
|
41
|
-
"_shasum": "
|
44
|
+
"_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
|
45
|
+
"_shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df",
|
42
46
|
"_shrinkwrap": null,
|
43
47
|
"_spec": "ansi-regex@^2.0.0",
|
44
48
|
"_where": "/Users/eshanker/Code/fsevents/node_modules/strip-ansi",
|
@@ -48,17 +52,18 @@
|
|
48
52
|
"url": "sindresorhus.com"
|
49
53
|
},
|
50
54
|
"bugs": {
|
51
|
-
"url": "https://github.com/
|
55
|
+
"url": "https://github.com/chalk/ansi-regex/issues"
|
52
56
|
},
|
53
57
|
"dependencies": {},
|
54
58
|
"description": "Regular expression for matching ANSI escape codes",
|
55
59
|
"devDependencies": {
|
56
|
-
"
|
60
|
+
"ava": "0.17.0",
|
61
|
+
"xo": "0.16.0"
|
57
62
|
},
|
58
63
|
"directories": {},
|
59
64
|
"dist": {
|
60
|
-
"shasum": "
|
61
|
-
"tarball": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.
|
65
|
+
"shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df",
|
66
|
+
"tarball": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz"
|
62
67
|
},
|
63
68
|
"engines": {
|
64
69
|
"node": ">=0.10.0"
|
@@ -66,8 +71,8 @@
|
|
66
71
|
"files": [
|
67
72
|
"index.js"
|
68
73
|
],
|
69
|
-
"gitHead": "
|
70
|
-
"homepage": "https://github.com/
|
74
|
+
"gitHead": "7c908e7b4eb6cd82bfe1295e33fdf6d166c7ed85",
|
75
|
+
"homepage": "https://github.com/chalk/ansi-regex#readme",
|
71
76
|
"keywords": [
|
72
77
|
"ansi",
|
73
78
|
"styles",
|
@@ -98,12 +103,12 @@
|
|
98
103
|
"license": "MIT",
|
99
104
|
"maintainers": [
|
100
105
|
{
|
101
|
-
"name": "
|
102
|
-
"email": "
|
106
|
+
"name": "qix",
|
107
|
+
"email": "i.am.qix@gmail.com"
|
103
108
|
},
|
104
109
|
{
|
105
|
-
"name": "
|
106
|
-
"email": "
|
110
|
+
"name": "sindresorhus",
|
111
|
+
"email": "sindresorhus@gmail.com"
|
107
112
|
}
|
108
113
|
],
|
109
114
|
"name": "ansi-regex",
|
@@ -111,11 +116,17 @@
|
|
111
116
|
"readme": "ERROR: No README data found!",
|
112
117
|
"repository": {
|
113
118
|
"type": "git",
|
114
|
-
"url": "git+https://github.com/
|
119
|
+
"url": "git+https://github.com/chalk/ansi-regex.git"
|
115
120
|
},
|
116
121
|
"scripts": {
|
117
|
-
"test": "
|
118
|
-
"view-supported": "node
|
122
|
+
"test": "xo && ava --verbose",
|
123
|
+
"view-supported": "node fixtures/view-codes.js"
|
119
124
|
},
|
120
|
-
"version": "2.
|
125
|
+
"version": "2.1.1",
|
126
|
+
"xo": {
|
127
|
+
"rules": {
|
128
|
+
"guard-for-in": 0,
|
129
|
+
"no-loop-func": 0
|
130
|
+
}
|
131
|
+
}
|
121
132
|
}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# ansi-regex [![Build Status](https://travis-ci.org/
|
1
|
+
# ansi-regex [![Build Status](https://travis-ci.org/chalk/ansi-regex.svg?branch=master)](https://travis-ci.org/chalk/ansi-regex)
|
2
2
|
|
3
3
|
> Regular expression for matching [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code)
|
4
4
|
|
@@ -13,7 +13,7 @@ $ npm install --save ansi-regex
|
|
13
13
|
## Usage
|
14
14
|
|
15
15
|
```js
|
16
|
-
|
16
|
+
const ansiRegex = require('ansi-regex');
|
17
17
|
|
18
18
|
ansiRegex().test('\u001b[4mcake\u001b[0m');
|
19
19
|
//=> true
|
@@ -25,6 +25,14 @@ ansiRegex().test('cake');
|
|
25
25
|
//=> ['\u001b[4m', '\u001b[0m']
|
26
26
|
```
|
27
27
|
|
28
|
+
## FAQ
|
29
|
+
|
30
|
+
### Why do you test for codes not in the ECMA 48 standard?
|
31
|
+
|
32
|
+
Some of the codes we run as a test are codes that we acquired finding various lists of non-standard or manufacturer specific codes. If I recall correctly, we test for both standard and non-standard codes, as most of them follow the same or similar format and can be safely matched in strings without the risk of removing actual string content. There are a few non-standard control codes that do not follow the traditional format (i.e. they end in numbers) thus forcing us to exclude them from the test because we cannot reliably match them.
|
33
|
+
|
34
|
+
On the historical side, those ECMA standards were established in the early 90's whereas the VT100, for example, was designed in the mid/late 70's. At that point in time, control codes were still pretty ungoverned and engineers used them for a multitude of things, namely to activate hardware ports that may have been proprietary. Somewhere else you see a similar 'anarchy' of codes is in the x86 architecture for processors; there are a ton of "interrupts" that can mean different things on certain brands of processors, most of which have been phased out.
|
35
|
+
|
28
36
|
|
29
37
|
## License
|
30
38
|
|
@@ -29,7 +29,8 @@ N | typeof == number
|
|
29
29
|
F | typeof == function
|
30
30
|
O | typeof == object and not type A and not type E
|
31
31
|
B | typeof == boolean
|
32
|
-
E | instanceof Error OR null
|
32
|
+
E | instanceof Error OR null **(special: see below)**
|
33
|
+
Z | == null
|
33
34
|
|
34
35
|
Validation failures throw one of three exception types, distinguished by a
|
35
36
|
`code` property of `EMISSINGARG`, `EINVALIDTYPE` or `ETOOMANYARGS`.
|
@@ -37,8 +38,37 @@ Validation failures throw one of three exception types, distinguished by a
|
|
37
38
|
If you pass in an invalid type then it will throw with a code of
|
38
39
|
`EUNKNOWNTYPE`.
|
39
40
|
|
40
|
-
If an error argument is found and is not null then the remaining
|
41
|
-
|
41
|
+
If an **error** argument is found and is not null then the remaining
|
42
|
+
arguments are optional. That is, if you say `ESO` then that's like using a
|
43
|
+
non-magical `E` in: `E|ESO|ZSO`.
|
44
|
+
|
45
|
+
### But I have optional arguments?!
|
46
|
+
|
47
|
+
You can provide more than one signature by separating them with pipes `|`.
|
48
|
+
If any signature matches the arguments then they'll be considered valid.
|
49
|
+
|
50
|
+
So for example, say you wanted to write a signature for
|
51
|
+
`fs.createWriteStream`. The docs for it describe it thusly:
|
52
|
+
|
53
|
+
```
|
54
|
+
fs.createWriteStream(path[, options])
|
55
|
+
```
|
56
|
+
|
57
|
+
This would be a signature of `SO|S`. That is, a string and and object, or
|
58
|
+
just a string.
|
59
|
+
|
60
|
+
Now, if you read the full `fs` docs, you'll see that actually path can ALSO
|
61
|
+
be a buffer. And options can be a string, that is:
|
62
|
+
```
|
63
|
+
path <String> | <Buffer>
|
64
|
+
options <String> | <Object>
|
65
|
+
```
|
66
|
+
|
67
|
+
To reproduce this you have to fully enumerate all of the possible
|
68
|
+
combinations and that implies a signature of `SO|SS|OO|OS|S|O`. The
|
69
|
+
awkwardness is a feature: It reminds you of the complexity you're adding to
|
70
|
+
your API when you do this sort of thing.
|
71
|
+
|
42
72
|
|
43
73
|
### Why this exists
|
44
74
|
|
@@ -1,36 +1,64 @@
|
|
1
1
|
'use strict'
|
2
2
|
|
3
3
|
function isArguments (thingy) {
|
4
|
-
return typeof thingy === 'object' && thingy.hasOwnProperty('callee')
|
4
|
+
return thingy != null && typeof thingy === 'object' && thingy.hasOwnProperty('callee')
|
5
5
|
}
|
6
6
|
|
7
7
|
var types = {
|
8
|
-
'*':
|
9
|
-
A:
|
10
|
-
S:
|
11
|
-
N:
|
12
|
-
F:
|
13
|
-
O:
|
14
|
-
B:
|
15
|
-
E:
|
16
|
-
}
|
17
|
-
|
18
|
-
|
19
|
-
|
8
|
+
'*': {label: 'any', check: function () { return true }},
|
9
|
+
A: {label: 'array', check: function (thingy) { return Array.isArray(thingy) || isArguments(thingy) }},
|
10
|
+
S: {label: 'string', check: function (thingy) { return typeof thingy === 'string' }},
|
11
|
+
N: {label: 'number', check: function (thingy) { return typeof thingy === 'number' }},
|
12
|
+
F: {label: 'function', check: function (thingy) { return typeof thingy === 'function' }},
|
13
|
+
O: {label: 'object', check: function (thingy) { return typeof thingy === 'object' && thingy != null && !types.A.check(thingy) && !types.E.check(thingy) }},
|
14
|
+
B: {label: 'boolean', check: function (thingy) { return typeof thingy === 'boolean' }},
|
15
|
+
E: {label: 'error', check: function (thingy) { return thingy instanceof Error }},
|
16
|
+
Z: {label: 'null', check: function (thingy) { return thingy == null }}
|
17
|
+
}
|
18
|
+
|
19
|
+
var validate = module.exports = function (rawSchemas, args) {
|
20
|
+
if (arguments.length !== 2) throw wrongNumberOfArgs(['SA'], arguments.length)
|
21
|
+
if (!rawSchemas) throw missingRequiredArg(0, 'rawSchemas')
|
20
22
|
if (!args) throw missingRequiredArg(1, 'args')
|
21
|
-
if (!types.S
|
22
|
-
if (!types.A
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
var
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
23
|
+
if (!types.S.check(rawSchemas)) throw invalidType(0, ['string'], rawSchemas)
|
24
|
+
if (!types.A.check(args)) throw invalidType(1, ['array'], args)
|
25
|
+
var schemas = rawSchemas.split('|')
|
26
|
+
var arity = {}
|
27
|
+
function addSchema (schema) {
|
28
|
+
var group = arity[schema.length] = arity[schema.length] || []
|
29
|
+
if (group.indexOf(schema) === -1) group.push(schema)
|
30
|
+
}
|
31
|
+
schemas.forEach(function (schema) {
|
32
|
+
for (var ii = 0; ii < schema.length; ++ii) {
|
33
|
+
var type = schema[ii]
|
34
|
+
if (!types[type]) throw unknownType(ii, type)
|
35
|
+
}
|
36
|
+
if (/E.*E/.test(schema)) throw moreThanOneError(schema)
|
37
|
+
addSchema(schema)
|
38
|
+
if (/E/.test(schema)) {
|
39
|
+
addSchema(schema.replace(/E.*$/, 'E'))
|
40
|
+
addSchema(schema.replace(/E/, 'Z'))
|
41
|
+
if (schema.length === 1) addSchema('')
|
42
|
+
}
|
43
|
+
})
|
44
|
+
var matching = arity[args.length]
|
45
|
+
if (!matching) {
|
46
|
+
throw wrongNumberOfArgs(Object.keys(arity), args.length)
|
47
|
+
}
|
48
|
+
for (var ii = 0; ii < args.length; ++ii) {
|
49
|
+
var newMatching = matching.filter(function (schema) {
|
50
|
+
var type = schema[ii]
|
51
|
+
var typeCheck = types[type].check
|
52
|
+
return typeCheck(args[ii])
|
53
|
+
})
|
54
|
+
if (!newMatching.length) {
|
55
|
+
var labels = matching.map(function (schema) {
|
56
|
+
return types[schema[ii]].label
|
57
|
+
}).filter(function (schema) { return schema != null })
|
58
|
+
throw invalidType(ii, labels, args[ii])
|
59
|
+
}
|
60
|
+
matching = newMatching
|
32
61
|
}
|
33
|
-
if (schema.length < args.length) throw tooManyArgs(schema.length, args.length)
|
34
62
|
}
|
35
63
|
|
36
64
|
function missingRequiredArg (num) {
|
@@ -41,17 +69,30 @@ function unknownType (num, type) {
|
|
41
69
|
return newException('EUNKNOWNTYPE', 'Unknown type ' + type + ' in argument #' + (num + 1))
|
42
70
|
}
|
43
71
|
|
44
|
-
function invalidType (num,
|
72
|
+
function invalidType (num, expectedTypes, value) {
|
45
73
|
var valueType
|
46
74
|
Object.keys(types).forEach(function (typeCode) {
|
47
|
-
if (types[typeCode]
|
75
|
+
if (types[typeCode].check(value)) valueType = types[typeCode].label
|
48
76
|
})
|
49
77
|
return newException('EINVALIDTYPE', 'Argument #' + (num + 1) + ': Expected ' +
|
50
|
-
|
78
|
+
englishList(expectedTypes) + ' but got ' + valueType)
|
79
|
+
}
|
80
|
+
|
81
|
+
function englishList (list) {
|
82
|
+
return list.join(', ').replace(/, ([^,]+)$/, ' or $1')
|
83
|
+
}
|
84
|
+
|
85
|
+
function wrongNumberOfArgs (expected, got) {
|
86
|
+
var english = englishList(expected)
|
87
|
+
var args = expected.every(function (ex) { return ex.length === 1 })
|
88
|
+
? 'argument'
|
89
|
+
: 'arguments'
|
90
|
+
return newException('EWRONGARGCOUNT', 'Expected ' + english + ' ' + args + ' but got ' + got)
|
51
91
|
}
|
52
92
|
|
53
|
-
function
|
54
|
-
return newException('
|
93
|
+
function moreThanOneError (schema) {
|
94
|
+
return newException('ETOOMANYERRORTYPES',
|
95
|
+
'Only one error type per argument signature is allowed, more than one found in "' + schema + '"')
|
55
96
|
}
|
56
97
|
|
57
98
|
function newException (code, msg) {
|
@@ -14,19 +14,19 @@
|
|
14
14
|
]
|
15
15
|
],
|
16
16
|
"_from": "aproba@>=1.0.3 <2.0.0",
|
17
|
-
"_id": "aproba@1.
|
17
|
+
"_id": "aproba@1.1.1",
|
18
18
|
"_inCache": true,
|
19
19
|
"_location": "/aproba",
|
20
|
-
"_nodeVersion": "
|
20
|
+
"_nodeVersion": "7.5.0",
|
21
21
|
"_npmOperationalInternal": {
|
22
|
-
"host": "packages-
|
23
|
-
"tmp": "tmp/aproba-1.
|
22
|
+
"host": "packages-18-east.internal.npmjs.com",
|
23
|
+
"tmp": "tmp/aproba-1.1.1.tgz_1486593129508_0.5718816472217441"
|
24
24
|
},
|
25
25
|
"_npmUser": {
|
26
26
|
"name": "iarna",
|
27
27
|
"email": "me@re-becca.org"
|
28
28
|
},
|
29
|
-
"_npmVersion": "
|
29
|
+
"_npmVersion": "4.2.0",
|
30
30
|
"_phantomChildren": {},
|
31
31
|
"_requested": {
|
32
32
|
"raw": "aproba@^1.0.3",
|
@@ -40,8 +40,8 @@
|
|
40
40
|
"_requiredBy": [
|
41
41
|
"/gauge"
|
42
42
|
],
|
43
|
-
"_resolved": "https://registry.npmjs.org/aproba/-/aproba-1.
|
44
|
-
"_shasum": "
|
43
|
+
"_resolved": "https://registry.npmjs.org/aproba/-/aproba-1.1.1.tgz",
|
44
|
+
"_shasum": "95d3600f07710aa0e9298c726ad5ecf2eacbabab",
|
45
45
|
"_shrinkwrap": null,
|
46
46
|
"_spec": "aproba@^1.0.3",
|
47
47
|
"_where": "/Users/eshanker/Code/fsevents/node_modules/gauge",
|
@@ -55,20 +55,20 @@
|
|
55
55
|
"dependencies": {},
|
56
56
|
"description": "A rediculously light-weight argument validator",
|
57
57
|
"devDependencies": {
|
58
|
-
"standard": "^
|
59
|
-
"tap": "^
|
58
|
+
"standard": "^8.6.0",
|
59
|
+
"tap": "^10.0.2"
|
60
60
|
},
|
61
61
|
"directories": {
|
62
62
|
"test": "test"
|
63
63
|
},
|
64
64
|
"dist": {
|
65
|
-
"shasum": "
|
66
|
-
"tarball": "https://registry.npmjs.org/aproba/-/aproba-1.
|
65
|
+
"shasum": "95d3600f07710aa0e9298c726ad5ecf2eacbabab",
|
66
|
+
"tarball": "https://registry.npmjs.org/aproba/-/aproba-1.1.1.tgz"
|
67
67
|
},
|
68
68
|
"files": [
|
69
69
|
"index.js"
|
70
70
|
],
|
71
|
-
"gitHead": "
|
71
|
+
"gitHead": "e7c76b4b42356092db3cd9e2d9388a0134845eb2",
|
72
72
|
"homepage": "https://github.com/iarna/aproba",
|
73
73
|
"keywords": [
|
74
74
|
"argument",
|
@@ -90,7 +90,7 @@
|
|
90
90
|
"url": "git+https://github.com/iarna/aproba.git"
|
91
91
|
},
|
92
92
|
"scripts": {
|
93
|
-
"test": "standard && tap test/*.js"
|
93
|
+
"test": "standard && tap -j3 test/*.js"
|
94
94
|
},
|
95
|
-
"version": "1.
|
95
|
+
"version": "1.1.1"
|
96
96
|
}
|
@@ -118,14 +118,14 @@ RequestSigner.prototype.prepareRequest = function() {
|
|
118
118
|
if (request.body && !headers['Content-Length'] && !headers['content-length'])
|
119
119
|
headers['Content-Length'] = Buffer.byteLength(request.body)
|
120
120
|
|
121
|
-
if (this.credentials.sessionToken)
|
121
|
+
if (this.credentials.sessionToken && !headers['X-Amz-Security-Token'] && !headers['x-amz-security-token'])
|
122
122
|
headers['X-Amz-Security-Token'] = this.credentials.sessionToken
|
123
123
|
|
124
|
-
if (this.service === 's3')
|
124
|
+
if (this.service === 's3' && !headers['X-Amz-Content-Sha256'] && !headers['x-amz-content-sha256'])
|
125
125
|
headers['X-Amz-Content-Sha256'] = hash(this.request.body || '', 'hex')
|
126
126
|
|
127
|
-
if (headers['X-Amz-Date'])
|
128
|
-
this.datetime = headers['X-Amz-Date']
|
127
|
+
if (headers['X-Amz-Date'] || headers['x-amz-date'])
|
128
|
+
this.datetime = headers['X-Amz-Date'] || headers['x-amz-date']
|
129
129
|
else
|
130
130
|
headers['X-Amz-Date'] = this.getDateTime()
|
131
131
|
}
|
@@ -202,13 +202,22 @@ RequestSigner.prototype.canonicalString = function() {
|
|
202
202
|
|
203
203
|
var pathStr = this.parsedPath.path,
|
204
204
|
query = this.parsedPath.query,
|
205
|
+
headers = this.request.headers,
|
205
206
|
queryStr = '',
|
206
207
|
normalizePath = this.service !== 's3',
|
207
208
|
decodePath = this.service === 's3' || this.request.doNotEncodePath,
|
208
209
|
decodeSlashesInPath = this.service === 's3',
|
209
210
|
firstValOnly = this.service === 's3',
|
210
|
-
bodyHash
|
211
|
-
|
211
|
+
bodyHash
|
212
|
+
|
213
|
+
if (this.service === 's3' && this.request.signQuery) {
|
214
|
+
bodyHash = 'UNSIGNED-PAYLOAD'
|
215
|
+
} else if (this.isCodeCommitGit) {
|
216
|
+
bodyHash = ''
|
217
|
+
} else {
|
218
|
+
bodyHash = headers['X-Amz-Content-Sha256'] || headers['x-amz-content-sha256'] ||
|
219
|
+
hash(this.request.body || '', 'hex')
|
220
|
+
}
|
212
221
|
|
213
222
|
if (query) {
|
214
223
|
queryStr = encodeRfc3986(querystring.stringify(Object.keys(query).sort().reduce(function(obj, key) {
|
@@ -14,19 +14,19 @@
|
|
14
14
|
]
|
15
15
|
],
|
16
16
|
"_from": "aws4@>=1.2.1 <2.0.0",
|
17
|
-
"_id": "aws4@1.
|
17
|
+
"_id": "aws4@1.6.0",
|
18
18
|
"_inCache": true,
|
19
19
|
"_location": "/aws4",
|
20
20
|
"_nodeVersion": "4.5.0",
|
21
21
|
"_npmOperationalInternal": {
|
22
|
-
"host": "packages-
|
23
|
-
"tmp": "tmp/aws4-1.
|
22
|
+
"host": "packages-18-east.internal.npmjs.com",
|
23
|
+
"tmp": "tmp/aws4-1.6.0.tgz_1486481933920_0.6127187723759562"
|
24
24
|
},
|
25
25
|
"_npmUser": {
|
26
26
|
"name": "hichaelmart",
|
27
27
|
"email": "michael.hart.au@gmail.com"
|
28
28
|
},
|
29
|
-
"_npmVersion": "
|
29
|
+
"_npmVersion": "4.0.5",
|
30
30
|
"_phantomChildren": {},
|
31
31
|
"_requested": {
|
32
32
|
"raw": "aws4@^1.2.1",
|
@@ -40,8 +40,8 @@
|
|
40
40
|
"_requiredBy": [
|
41
41
|
"/request"
|
42
42
|
],
|
43
|
-
"_resolved": "https://registry.npmjs.org/aws4/-/aws4-1.
|
44
|
-
"_shasum": "
|
43
|
+
"_resolved": "https://registry.npmjs.org/aws4/-/aws4-1.6.0.tgz",
|
44
|
+
"_shasum": "83ef5ca860b2b32e4a0deedee8c771b9db57471e",
|
45
45
|
"_shrinkwrap": null,
|
46
46
|
"_spec": "aws4@^1.2.1",
|
47
47
|
"_where": "/Users/eshanker/Code/fsevents/node_modules/request",
|
@@ -61,10 +61,10 @@
|
|
61
61
|
},
|
62
62
|
"directories": {},
|
63
63
|
"dist": {
|
64
|
-
"shasum": "
|
65
|
-
"tarball": "https://registry.npmjs.org/aws4/-/aws4-1.
|
64
|
+
"shasum": "83ef5ca860b2b32e4a0deedee8c771b9db57471e",
|
65
|
+
"tarball": "https://registry.npmjs.org/aws4/-/aws4-1.6.0.tgz"
|
66
66
|
},
|
67
|
-
"gitHead": "
|
67
|
+
"gitHead": "74bf0b64d1e8cbcd184964999c7ef53f52d7ad32",
|
68
68
|
"homepage": "https://github.com/mhart/aws4#readme",
|
69
69
|
"keywords": [
|
70
70
|
"amazon",
|
@@ -136,5 +136,5 @@
|
|
136
136
|
"scripts": {
|
137
137
|
"test": "mocha ./test/fast.js ./test/slow.js -b -t 100s -R list"
|
138
138
|
},
|
139
|
-
"version": "1.
|
139
|
+
"version": "1.6.0"
|
140
140
|
}
|
@@ -29,10 +29,7 @@ var crypto_hash_sha512 = require('tweetnacl').lowlevel.crypto_hash;
|
|
29
29
|
* 2. Redistributions in binary form must reproduce the above copyright
|
30
30
|
* notice, this list of conditions and the following disclaimer in the
|
31
31
|
* documentation and/or other materials provided with the distribution.
|
32
|
-
* 3.
|
33
|
-
* must display the following acknowledgement:
|
34
|
-
* This product includes software developed by Niels Provos.
|
35
|
-
* 4. The name of the author may not be used to endorse or promote products
|
32
|
+
* 3. The name of the author may not be used to endorse or promote products
|
36
33
|
* derived from this software without specific prior written permission.
|
37
34
|
*
|
38
35
|
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|