diff options
-rw-r--r-- | node_modules/npm-registry-client/lib/authify.js | 4 | ||||
-rw-r--r-- | node_modules/npm-registry-client/lib/fetch.js | 13 | ||||
-rw-r--r-- | node_modules/npm-registry-client/lib/initialize.js | 3 | ||||
-rw-r--r-- | node_modules/npm-registry-client/package.json | 24 | ||||
-rw-r--r-- | package-lock.json | 6 | ||||
-rw-r--r-- | package.json | 2 |
6 files changed, 22 insertions, 30 deletions
diff --git a/node_modules/npm-registry-client/lib/authify.js b/node_modules/npm-registry-client/lib/authify.js index 0a259757b..9b38a30a9 100644 --- a/node_modules/npm-registry-client/lib/authify.js +++ b/node_modules/npm-registry-client/lib/authify.js @@ -1,6 +1,10 @@ module.exports = authify function authify (authed, parsed, headers, credentials) { + if (credentials && credentials.otp) { + this.log.verbose('request', 'passing along npm otp') + headers['npm-otp'] = credentials.otp + } if (credentials && credentials.token) { this.log.verbose('request', 'using bearer token for auth') headers.authorization = 'Bearer ' + credentials.token diff --git a/node_modules/npm-registry-client/lib/fetch.js b/node_modules/npm-registry-client/lib/fetch.js index ff3ee216b..5ab858778 100644 --- a/node_modules/npm-registry-client/lib/fetch.js +++ b/node_modules/npm-registry-client/lib/fetch.js @@ -35,10 +35,7 @@ function fetch (uri, params, cb) { var er var statusCode = res && res.statusCode if (statusCode === 200) { - // Work around bug in node v0.10.0 where the CryptoStream - // gets stuck and never starts reading again. res.resume() - if (process.version === 'v0.10.0') unstick(res) req.once('error', function (er) { res.emit('error', er) @@ -62,16 +59,6 @@ function fetch (uri, params, cb) { }) } -function unstick (response) { - response.resume = (function (orig) { - return function () { - var ret = orig.apply(response, arguments) - if (response.socket.encrypted) response.socket.encrypted.read(0) - return ret - } - })(response.resume) -} - function makeRequest (remote, params, cb) { var parsed = url.parse(remote) this.log.http('fetch', 'GET', parsed.href) diff --git a/node_modules/npm-registry-client/lib/initialize.js b/node_modules/npm-registry-client/lib/initialize.js index 174d6470a..a25077eae 100644 --- a/node_modules/npm-registry-client/lib/initialize.js +++ b/node_modules/npm-registry-client/lib/initialize.js @@ -14,7 +14,8 @@ function initialize (uri, method, accept, headers) { if (this.config.isFromCI == null) { this.config.isFromCI = Boolean( process.env['CI'] === 'true' || process.env['TDDIUM'] || - process.env['JENKINS_URL'] || process.env['bamboo.buildKey']) + process.env['JENKINS_URL'] || process.env['bamboo.buildKey'] || + process.env['GO_PIPELINE_NAME']) } var opts = { diff --git a/node_modules/npm-registry-client/package.json b/node_modules/npm-registry-client/package.json index c8c2f60ff..619940a5e 100644 --- a/node_modules/npm-registry-client/package.json +++ b/node_modules/npm-registry-client/package.json @@ -1,30 +1,30 @@ { - "_from": "npm-registry-client@8.4.0", - "_id": "npm-registry-client@8.4.0", + "_from": "npm-registry-client@latest", + "_id": "npm-registry-client@8.5.0", "_inBundle": false, - "_integrity": "sha512-PVNfqq0lyRdFnE//nDmn3CC9uqTsr8Bya9KPLIevlXMfkP0m4RpCVyFFk0W1Gfx436kKwyhLA6J+lV+rgR81gQ==", + "_integrity": "sha512-Nkcw24bfECKFNt0FLDQ+PjVqSlKxMggcboXiUBIvjbCnA15xjRO4kCwRDluGNXZjHFLx/vPjN4+ESXyVjpXLbQ==", "_location": "/npm-registry-client", "_phantomChildren": { "inherits": "2.0.3", - "readable-stream": "2.2.10" + "readable-stream": "2.3.3" }, "_requested": { - "type": "version", + "type": "tag", "registry": true, - "raw": "npm-registry-client@8.4.0", + "raw": "npm-registry-client@latest", "name": "npm-registry-client", "escapedName": "npm-registry-client", - "rawSpec": "8.4.0", + "rawSpec": "latest", "saveSpec": null, - "fetchSpec": "8.4.0" + "fetchSpec": "latest" }, "_requiredBy": [ "#USER", "/" ], - "_resolved": "https://registry.npmjs.org/npm-registry-client/-/npm-registry-client-8.4.0.tgz", - "_shasum": "d52b901685647fc62a4c03eafecb6ceaa5018d4c", - "_spec": "npm-registry-client@8.4.0", + "_resolved": "https://registry.npmjs.org/npm-registry-client/-/npm-registry-client-8.5.0.tgz", + "_shasum": "4878fb6fa1f18a5dc08ae83acf94d0d0112d7ed0", + "_spec": "npm-registry-client@latest", "_where": "/Users/rebecca/code/npm", "author": { "name": "Isaac Z. Schlueter", @@ -76,5 +76,5 @@ "scripts": { "test": "standard && tap test/*.js" }, - "version": "8.4.0" + "version": "8.5.0" } diff --git a/package-lock.json b/package-lock.json index a76720c8c..df30c6384 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1728,9 +1728,9 @@ } }, "npm-registry-client": { - "version": "8.4.0", - "resolved": "https://registry.npmjs.org/npm-registry-client/-/npm-registry-client-8.4.0.tgz", - "integrity": "sha512-PVNfqq0lyRdFnE//nDmn3CC9uqTsr8Bya9KPLIevlXMfkP0m4RpCVyFFk0W1Gfx436kKwyhLA6J+lV+rgR81gQ==", + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/npm-registry-client/-/npm-registry-client-8.5.0.tgz", + "integrity": "sha512-Nkcw24bfECKFNt0FLDQ+PjVqSlKxMggcboXiUBIvjbCnA15xjRO4kCwRDluGNXZjHFLx/vPjN4+ESXyVjpXLbQ==", "requires": { "concat-stream": "1.6.0", "graceful-fs": "4.1.11", diff --git a/package.json b/package.json index eb6a7c9ef..c33c1ec80 100644 --- a/package.json +++ b/package.json @@ -85,7 +85,7 @@ "npm-package-arg": "~5.1.2", "npm-packlist": "~1.1.9", "npm-profile": "~2.0.4", - "npm-registry-client": "~8.4.0", + "npm-registry-client": "~8.5.0", "npm-user-validate": "~1.0.0", "npmlog": "~4.1.2", "once": "~1.4.0", |