Firebase Update

This commit is contained in:
Lukas Nowy
2018-12-22 23:30:39 +01:00
parent befb44764d
commit acffe619b3
11523 changed files with 1614327 additions and 930246 deletions

View File

@ -4,6 +4,86 @@
[1]: https://www.npmjs.com/package/google-auth-library-nodejs?activeTab=versions
## v2.0.2
12-16-2018 10:48 PST
### Fixes
- fix(types): export GCPEnv type ([#569](https://github.com/google/google-auth-library-nodejs/pull/569))
- fix: use post for token revocation ([#524](https://github.com/google/google-auth-library-nodejs/pull/524))
### Dependencies
- fix(deps): update dependency lru-cache to v5 ([#541](https://github.com/google/google-auth-library-nodejs/pull/541))
### Documentation
- docs: add ref docs again ([#553](https://github.com/google/google-auth-library-nodejs/pull/553))
- docs: clean up the readme ([#554](https://github.com/google/google-auth-library-nodejs/pull/554))
### Internal / Testing Changes
- chore(deps): update dependency @types/sinon to v7 ([#568](https://github.com/google/google-auth-library-nodejs/pull/568))
- refactor: use execa for install tests, run eslint on samples ([#559](https://github.com/google/google-auth-library-nodejs/pull/559))
- chore(build): inject yoshi automation key ([#566](https://github.com/google/google-auth-library-nodejs/pull/566))
- chore: update nyc and eslint configs ([#565](https://github.com/google/google-auth-library-nodejs/pull/565))
- chore: fix publish.sh permission +x ([#563](https://github.com/google/google-auth-library-nodejs/pull/563))
- fix(build): fix Kokoro release script ([#562](https://github.com/google/google-auth-library-nodejs/pull/562))
- build: add Kokoro configs for autorelease ([#561](https://github.com/google/google-auth-library-nodejs/pull/561))
- chore: always nyc report before calling codecov ([#557](https://github.com/google/google-auth-library-nodejs/pull/557))
- chore: nyc ignore build/test by default ([#556](https://github.com/google/google-auth-library-nodejs/pull/556))
- chore(build): update the prettier and renovate config ([#552](https://github.com/google/google-auth-library-nodejs/pull/552))
- chore: update license file ([#551](https://github.com/google/google-auth-library-nodejs/pull/551))
- fix(build): fix system key decryption ([#547](https://github.com/google/google-auth-library-nodejs/pull/547))
- chore(deps): update dependency typescript to ~3.2.0 ([#546](https://github.com/google/google-auth-library-nodejs/pull/546))
- chore(deps): unpin sinon ([#544](https://github.com/google/google-auth-library-nodejs/pull/544))
- refactor: drop non-required modules ([#542](https://github.com/google/google-auth-library-nodejs/pull/542))
- chore: add synth.metadata ([#537](https://github.com/google/google-auth-library-nodejs/pull/537))
- fix: Pin @types/sinon to last compatible version ([#538](https://github.com/google/google-auth-library-nodejs/pull/538))
- chore(deps): update dependency gts to ^0.9.0 ([#531](https://github.com/google/google-auth-library-nodejs/pull/531))
- chore: update eslintignore config ([#530](https://github.com/google/google-auth-library-nodejs/pull/530))
- chore: drop contributors from multiple places ([#528](https://github.com/google/google-auth-library-nodejs/pull/528))
- chore: use latest npm on Windows ([#527](https://github.com/google/google-auth-library-nodejs/pull/527))
- chore: update CircleCI config ([#523](https://github.com/google/google-auth-library-nodejs/pull/523))
- chore: include build in eslintignore ([#516](https://github.com/google/google-auth-library-nodejs/pull/516))
## v2.0.1
### Implementation Changes
- fix: verifyIdToken will never return null ([#488](https://github.com/google/google-auth-library-nodejs/pull/488))
- Update the url to application default credentials ([#470](https://github.com/google/google-auth-library-nodejs/pull/470))
- Update omitted parameter 'hd' ([#467](https://github.com/google/google-auth-library-nodejs/pull/467))
### Dependencies
- chore(deps): update dependency nock to v10 ([#501](https://github.com/google/google-auth-library-nodejs/pull/501))
- chore(deps): update dependency sinon to v7 ([#502](https://github.com/google/google-auth-library-nodejs/pull/502))
- chore(deps): update dependency typescript to v3.1.3 ([#503](https://github.com/google/google-auth-library-nodejs/pull/503))
- chore(deps): update dependency gh-pages to v2 ([#499](https://github.com/google/google-auth-library-nodejs/pull/499))
- chore(deps): update dependency typedoc to ^0.13.0 ([#497](https://github.com/google/google-auth-library-nodejs/pull/497))
### Documentation
- docs: Remove code format from Application Default Credentials ([#483](https://github.com/google/google-auth-library-nodejs/pull/483))
- docs: replace google/ with googleapis/ in URIs ([#472](https://github.com/google/google-auth-library-nodejs/pull/472))
- Fix typo in readme ([#469](https://github.com/google/google-auth-library-nodejs/pull/469))
- Update samples and docs for 2.0 ([#459](https://github.com/google/google-auth-library-nodejs/pull/459))
### Internal / Testing Changes
- chore: update issue templates ([#509](https://github.com/google/google-auth-library-nodejs/pull/509))
- chore: remove old issue template ([#507](https://github.com/google/google-auth-library-nodejs/pull/507))
- build: run tests on node11 ([#506](https://github.com/google/google-auth-library-nodejs/pull/506))
- chore(build): drop hard rejection and update gts in the kitchen test ([#504](https://github.com/google/google-auth-library-nodejs/pull/504))
- chores(build): do not collect sponge.xml from windows builds ([#500](https://github.com/google/google-auth-library-nodejs/pull/500))
- chores(build): run codecov on continuous builds ([#495](https://github.com/google/google-auth-library-nodejs/pull/495))
- chore: update new issue template ([#494](https://github.com/google/google-auth-library-nodejs/pull/494))
- build: fix codecov uploading on Kokoro ([#490](https://github.com/google/google-auth-library-nodejs/pull/490))
- test: move kitchen sink tests to system-test ([#489](https://github.com/google/google-auth-library-nodejs/pull/489))
- Update kokoro config ([#482](https://github.com/google/google-auth-library-nodejs/pull/482))
- fix: export additional typescript types ([#479](https://github.com/google/google-auth-library-nodejs/pull/479))
- Don't publish sourcemaps ([#478](https://github.com/google/google-auth-library-nodejs/pull/478))
- test: remove appveyor config ([#477](https://github.com/google/google-auth-library-nodejs/pull/477))
- Enable prefer-const in the eslint config ([#473](https://github.com/google/google-auth-library-nodejs/pull/473))
- Enable no-var in eslint ([#471](https://github.com/google/google-auth-library-nodejs/pull/471))
- Update CI config ([#468](https://github.com/google/google-auth-library-nodejs/pull/468))
- Retry npm install in CI ([#465](https://github.com/google/google-auth-library-nodejs/pull/465))
- Update Kokoro config ([#462](https://github.com/google/google-auth-library-nodejs/pull/462))
## v2.0.0
Well hello 2.0 🎉 **This release has multiple breaking changes**. It also has a lot of bug fixes.
@ -112,3 +192,5 @@ As always, if you run into any problems... please let us know!
- chore(package): Update gts to the latest version 🚀 (#387)
- chore(package): update sinon to version 6.0.0 (#386)
## Upgrading to 1.x
The `1.x` release includes a variety of bug fixes, new features, and breaking changes. Please take care, and see [the release notes](https://github.com/googleapis/google-auth-library-nodejs/releases/tag/v1.0.0) for a list of breaking changes, and the upgrade guide.

View File

@ -187,7 +187,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2013 Google Inc.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

View File

@ -3,7 +3,6 @@
# Google Auth Library
[![npm version][npmimg]][npm]
[![CircleCI][circle-image]][circle-url]
[![codecov][codecov-image]][codecov-url]
[![Dependencies][david-dm-img]][david-dm]
[![Known Vulnerabilities][snyk-image]][snyk-url]
@ -17,9 +16,6 @@ This library is distributed on `npm`. To add it as a dependency, run the followi
$ npm install google-auth-library
```
## Upgrading to 1.x
The `1.x` release includes a variety of bug fixes, new features, and breaking changes. Please take care, and see [the release notes](https://github.com/google/google-auth-library-nodejs/releases/tag/v1.0.0) for a list of breaking changes, and the upgrade guide.
## Ways to authenticate
This library provides a variety of ways to authenticate to your Google services.
- [Application Default Credentials](#choosing-the-correct-credential-type-automatically) - Use Application Default Credentials when you use a single identity for all users in your application. Especially useful for applications running on Google Cloud.
@ -34,7 +30,7 @@ They are best suited for cases when the call needs to have the same identity and
#### Download your Service Account Credentials JSON file
To use `Application Default Credentials`, You first need to download a set of JSON credentials for your project. Go to **APIs & Auth** > **Credentials** in the [Google Developers Console][devconsole] and select **Service account** from the **Add credentials** dropdown.
To use Application Default Credentials, You first need to download a set of JSON credentials for your project. Go to **APIs & Auth** > **Credentials** in the [Google Developers Console][devconsole] and select **Service account** from the **Add credentials** dropdown.
> This file is your *only copy* of these credentials. It should never be
> committed with your source code, and should be stored securely.
@ -161,7 +157,7 @@ main();
```
#### Handling token events
This library will automatically obtain an `access_token`, and automatically refresh the `access_token` if a `refresh_token` is present. The `refresh_token` is only returned on the [first authorization](https://github.com/google/google-api-nodejs-client/issues/750#issuecomment-304521450), so if you want to make sure you store it safely. An easy way to make sure you always store the most recent tokens is to use the `tokens` event:
This library will automatically obtain an `access_token`, and automatically refresh the `access_token` if a `refresh_token` is present. The `refresh_token` is only returned on the [first authorization](https://github.com/googleapis/google-api-nodejs-client/issues/750#issuecomment-304521450), so if you want to make sure you store it safely. An easy way to make sure you always store the most recent tokens is to use the `tokens` event:
```js
const client = await auth.getClient();
@ -220,7 +216,7 @@ original scopes, or audience for the token. To get the token info, you can use
```js
// after acquiring an oAuth2Client...
const tokenInfo = await oAuth2client.getTokenInfo('my-access-token');
const tokenInfo = await oAuth2Client.getTokenInfo('my-access-token');
// take a look at the scopes originally provisioned for the access token
console.log(tokenInfo.scopes);
@ -255,14 +251,12 @@ async function main() {
keys.private_key,
['https://www.googleapis.com/auth/cloud-platform'],
);
await client.authorize();
const url = `https://www.googleapis.com/dns/v1/projects/${keys.project_id}`;
const res = await client.request({url});
console.log(res.data);
}
main().catch(console.error);
```
The parameters for the JWT auth client including how to use it with a `.pem` file are explained in [samples/jwt.js](samples/jwt.js).
@ -302,7 +296,6 @@ async function main() {
// load the JWT or UserRefreshClient from the keys
const client = auth.fromJSON(keys);
client.scopes = ['https://www.googleapis.com/auth/cloud-platform'];
await client.authorize();
const url = `https://www.googleapis.com/dns/v1/projects/${keys.project_id}`;
const res = await client.request({url});
console.log(res.data);
@ -349,30 +342,23 @@ See [CONTRIBUTING][contributing].
This library is licensed under Apache 2.0. Full license text is available in [LICENSE][copying].
[Application Default Credentials]: https://developers.google.com/identity/protocols/application-default-credentials#callingnode
[Application Default Credentials]: https://cloud.google.com/docs/authentication/getting-started
[apptype]: https://user-images.githubusercontent.com/534619/36553844-3f9a863c-17b2-11e8-904a-29f6cd5f807a.png
[authdocs]: https://developers.google.com/accounts/docs/OAuth2Login
[axios]: https://github.com/axios/axios
[axiosOpts]: https://github.com/axios/axios#request-config
[bugs]: https://github.com/google/google-auth-library-nodejs/issues
[circle-image]: https://circleci.com/gh/google/google-auth-library-nodejs.svg?style=svg
[circle-url]: https://circleci.com/gh/google/google-auth-library-nodejs
[codecov-image]: https://codecov.io/gh/google/google-auth-library-nodejs/branch/master/graph/badge.svg
[codecov-url]: https://codecov.io/gh/google/google-auth-library-nodejs
[contributing]: https://github.com/google/google-auth-library-nodejs/blob/master/.github/CONTRIBUTING.md
[copying]: https://github.com/google/google-auth-library-nodejs/tree/master/LICENSE
[david-dm-img]: https://david-dm.org/google/google-auth-library-nodejs/status.svg
[david-dm]: https://david-dm.org/google/google-auth-library-nodejs
[bugs]: https://github.com/googleapis/google-auth-library-nodejs/issues
[codecov-image]: https://codecov.io/gh/googleapis/google-auth-library-nodejs/branch/master/graph/badge.svg
[codecov-url]: https://codecov.io/gh/googleapis/google-auth-library-nodejs
[contributing]: https://github.com/googleapis/google-auth-library-nodejs/blob/master/.github/CONTRIBUTING.md
[copying]: https://github.com/googleapis/google-auth-library-nodejs/tree/master/LICENSE
[david-dm-img]: https://david-dm.org/googleapis/google-auth-library-nodejs/status.svg
[david-dm]: https://david-dm.org/googleapis/google-auth-library-nodejs
[node]: http://nodejs.org/
[npmimg]: https://img.shields.io/npm/v/google-auth-library.svg
[npm]: https://www.npmjs.org/package/google-auth-library
[oauth]: https://developers.google.com/identity/protocols/OAuth2
[snyk-image]: https://snyk.io/test/github/google/google-auth-library-nodejs/badge.svg
[snyk-url]: https://snyk.io/test/github/google/google-auth-library-nodejs
[stability]: http://nodejs.org/api/stream.html#stream_stream
[snyk-image]: https://snyk.io/test/github/googleapis/google-auth-library-nodejs/badge.svg
[snyk-url]: https://snyk.io/test/github/googleapis/google-auth-library-nodejs
[stackoverflow]: http://stackoverflow.com/questions/tagged/google-auth-library-nodejs
[stream]: http://nodejs.org/api/stream.html#stream_class_stream_readable
[devconsole]: https://console.developer.google.com
[options]: https://github.com/google/google-auth-library-nodejs/tree/master#options
[gcloud]: https://github.com/GoogleCloudPlatform/gcloud-node
[cloudplatform]: https://developers.google.com/cloud/

View File

@ -1 +0,0 @@
{"version":3,"file":"authclient.js","sourceRoot":"","sources":["../../../src/auth/authclient.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAGH,mCAAoC;AAEpC,kDAAmD;AAQnD,MAAsB,UAAW,SAAQ,qBAAY;IAArD;;QACE,gBAAW,GAAG,IAAI,iCAAkB,EAAE,CAAC;QACvC,gBAAW,GAAgB,EAAE,CAAC;IAahC,CAAC;IANC;;OAEG;IACH,cAAc,CAAC,WAAwB;QACrC,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;IACjC,CAAC;CACF;AAfD,gCAeC"}

View File

@ -1 +0,0 @@
{"version":3,"file":"computeclient.js","sourceRoot":"","sources":["../../../src/auth/computeclient.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;AAGH,4CAA4C;AAC5C,wCAAwC;AAExC,iDAA8E;AAU9E,MAAa,OAAQ,SAAQ,2BAAY;IAGvC;;;;;OAKG;IACH,YAAY,UAA0B,EAAE;QACtC,KAAK,CAAC,OAAO,CAAC,CAAC;QACf,mEAAmE;QACnE,+CAA+C;QAC/C,IAAI,CAAC,WAAW,GAAG,EAAC,WAAW,EAAE,CAAC,EAAE,aAAa,EAAE,qBAAqB,EAAC,CAAC;QAC1E,IAAI,CAAC,mBAAmB,GAAG,OAAO,CAAC,mBAAmB,IAAI,SAAS,CAAC;IACtE,CAAC;IAED;;;;;OAKG;IACH,oBAAoB;QAClB,oEAAoE;QACpE,uEAAuE;QACvE,SAAS;QACT,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,gCAAgC,CAAC,CAAC;QACzD,OAAO,KAAK,CAAC;IACf,CAAC;IAED;;;OAGG;IACa,mBAAmB,CAAC,YACI;;YACtC,MAAM,SAAS,GAAG,oBAAoB,IAAI,CAAC,mBAAmB,QAAQ,CAAC;YACvE,IAAI,GAAqC,CAAC;YAC1C,IAAI;gBACF,GAAG,GAAG,MAAM,WAAW,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC;aAC7C;YAAC,OAAO,CAAC,EAAE;gBACV,CAAC,CAAC,OAAO,GAAG,iCAAiC,CAAC;gBAC9C,MAAM,CAAC,CAAC;aACT;Y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G,IAAI,KAAK,CAAC,cAAc,CAAC,CAAC;wBAC7B,CAA2B,CAAC,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC;qBAC3D;iBACF;aACF;YACD,MAAM,CAAC,CAAC;QACV,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AAvFD,0BAuFC"}

View File

@ -1 +0,0 @@
{"version":3,"file":"credentials.js","sourceRoot":"","sources":["../../../src/auth/credentials.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG"}

View File

@ -1 +0,0 @@
{"version":3,"file":"envDetect.js","sourceRoot":"","sources":["../../../src/auth/envDetect.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;AAEH,4CAA4C;AAE5C,IAAY,MAMX;AAND,WAAY,MAAM;IAChB,mCAAyB,CAAA;IACzB,iDAAuC,CAAA;IACvC,6CAAmC,CAAA;IACnC,2CAAiC,CAAA;IACjC,uBAAa,CAAA;AACf,CAAC,EANW,MAAM,GAAN,cAAM,KAAN,cAAM,QAMjB;AAED,IAAI,GAAqB,CAAC;AAE1B,SAAgB,KAAK;IACnB,GAAG,GAAG,SAAS,CAAC;AAClB,CAAC;AAFD,sBAEC;AAED,SAAsB,MAAM;;QAC1B,IAAI,CAAC,GAAG,EAAE;YACR,IAAI,WAAW,EAAE,EAAE;gBACjB,GAAG,GAAG,MAAM,CAAC,UAAU,CAAC;aACzB;iBAAM,IAAI,eAAe,EAAE,EAAE;gBAC5B,GAAG,GAAG,MAAM,CAAC,eAAe,CAAC;aAC9B;iBAAM,IAAI,MAAM,kBAAkB,EAAE,EAAE;gBACrC,GAAG,GAAG,MAAM,CAAC,iBAAiB,CAAC;aAChC;iBAAM,IAAI,MAAM,eAAe,EAAE,EAAE;gBAClC,GAAG,GAAG,MAAM,CAAC,cAAc,CAAC;aAC7B;iBAAM;gBACL,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC;aACnB;SACF;QACD,OAAO,GAAG,CAAC;IACb,CAAC;CAAA;AAfD,wBAeC;AAED,SAAS,WAAW;IAClB,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAAC;AACpE,CAAC;AAED,SAAS,eAAe;IACtB,OAAO,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC;AACrC,CAAC;AAED,SAAe,kBAAkB;;QAC/B,IAAI;YACF,MAAM,WAAW,CAAC,QAAQ,CAAC,yBAAyB,CAAC,CAAC;YACtD,OAAO,IAAI,CAAC;SACb;QAAC,OAAO,CAAC,EAAE;YACV,OAAO,KAAK,CAAC;SACd;IACH,CAAC;CAAA;AAED,SAAe,eAAe;;QAC5B,OAAO,WAAW,CAAC,WAAW,EAAE,CAAC;IACnC,CAAC;CAAA"}

View File

@ -164,7 +164,7 @@ class GoogleAuth {
}
if (!isGCE) {
// We failed to find the default credentials. Bail out with an error.
throw new Error('Could not load the default credentials. Browse to https://developers.google.com/accounts/docs/application-default-credentials for more information.');
throw new Error('Could not load the default credentials. Browse to https://cloud.google.com/docs/authentication/getting-started for more information.');
}
// For GCE, just return a default ComputeClient. It will take care of
// the rest.

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
{"version":3,"file":"iam.js","sourceRoot":"","sources":["../../../src/auth/iam.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,wCAAwC;AAOxC,MAAa,OAAO;IAClB;;;;;;OAMG;IACH,YAAmB,QAAgB,EAAS,KAAa;QAAtC,aAAQ,GAAR,QAAQ,CAAQ;QAAS,UAAK,GAAL,KAAK,CAAQ;QACvD,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACzB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;IAED;;;;;OAKG;IACH,oBAAoB;QAClB,yCAAyC;QACzC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,4BAA4B,CAAC,CAAC;QACrD,OAAO,KAAK,CAAC;IACf,CAAC;IAED;;;;;;OAMG;IACH,kBAAkB,CACd,SAAsB,EACtB,UAAiE;QACnE,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,mCAAmC,CAAC,CAAC;QAC5D,UAAU,CAAC,IAAI,EAAE,IAAI,CAAC,iBAAiB,EAAE,CAAC,CAAC;IAC7C,CAAC;IAED;;OAEG;IACH,iBAAiB;QACf,OAAO;YACL,+BAA+B,EAAE,IAAI,CAAC,QAAQ;YAC9C,gCAAgC,EAAE,IAAI,CAAC,KAAK;SAC7C,CAAC;IACJ,CAAC;CACF;AAhDD,0BAgDC"}

View File

@ -34,7 +34,7 @@ class JWTAccess {
* @param keyId the ID of the private key used to sign the token.
*/
constructor(email, key, keyId) {
this.cache = LRU({ max: 500, maxAge: 60 * 60 * 1000 });
this.cache = new LRU({ max: 500, maxAge: 60 * 60 * 1000 });
this.email = email;
this.key = key;
this.keyId = keyId;

View File

@ -1 +0,0 @@
{"version":3,"file":"jwtaccess.js","sourceRoot":"","sources":["../../../src/auth/jwtaccess.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,2BAA2B;AAC3B,iCAAiC;AAGjC,wCAAwC;AAKxC,MAAM,cAAc,GAAe;IACjC,GAAG,EAAE,OAAO;IACZ,GAAG,EAAE,KAAK;CACX,CAAC;AAMF,MAAa,SAAS;IAQpB;;;;;;;;;OASG;IACH,YAAY,KAAmB,EAAE,GAAiB,EAAE,KAAmB;QAZ/D,UAAK,GAAG,GAAG,CAAkB,EAAC,GAAG,EAAE,GAAG,EAAE,MAAM,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI,EAAC,CAAC,CAAC;QAavE,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACnB,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;QACf,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACrB,CAAC;IAED;;;;;OAKG;IACH,oBAAoB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,WAAW,CAAC,CAAC;SAC1C;IACH,CAAC;IAEO,eAAe,CAAC,WAA4B;QAClD,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;YACrC,IAAI,CAAC,WAAW,EAAE;gBAChB,MAAM,CAAC,IAAI,KAAK,CACZ,qEAAqE,CAAC,CAAC,CAAC;aAC7E;YACD,IAAI,CAAC,GAAG,EAAE,CAAC;YACX,WAAW,CAAC,WAAW,CAAC,MAAM,CAAC;iBAC1B,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,IAAI,KAAK,CAAC;iBACjC,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC;iBACnB,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;gBACd,IAAI;oBACF,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;oBAC3B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;oBACpB,OAAO,EAAE,CAAC;iBACX;gBAAC,OAAO,GAAG,EAAE;oBACZ,MAAM,CAAC,GAAG,CAAC,CAAC;iBACb;YACH,CAAC,CAAC,CAAC;QACT,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AA7JD,8BA6JC"}

View File

@ -27,7 +27,6 @@ const gtoken_1 = require("gtoken");
const messages = require("../messages");
const jwtaccess_1 = require("./jwtaccess");
const oauth2client_1 = require("./oauth2client");
const isString = require('lodash.isstring');
class JWT extends oauth2client_1.OAuth2Client {
constructor(optionsOrEmail, keyFile, key, scopes, subject, keyId) {
const opts = (optionsOrEmail && typeof optionsOrEmail === 'object') ?
@ -65,7 +64,9 @@ class JWT extends oauth2client_1.OAuth2Client {
* @param url the URI being authorized.
*/
getRequestMetadataAsync(url) {
const _super = name => super[name];
const _super = Object.create(null, {
getRequestMetadataAsync: { get: () => super.getRequestMetadataAsync }
});
return __awaiter(this, void 0, void 0, function* () {
if (!this.apiKey && !this.hasScopes() && url) {
if (this.additionalClaims && this.additionalClaims.target_audience) {
@ -83,7 +84,7 @@ class JWT extends oauth2client_1.OAuth2Client {
}
}
else {
return _super("getRequestMetadataAsync").call(this, url);
return _super.getRequestMetadataAsync.call(this, url);
}
});
}
@ -222,7 +223,7 @@ class JWT extends oauth2client_1.OAuth2Client {
* @param apiKey The API Key in string form.
*/
fromAPIKey(apiKey) {
if (!isString(apiKey)) {
if (typeof apiKey !== 'string') {
throw new Error('Must provide an API Key string.');
}
this.apiKey = apiKey;

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
{"version":3,"file":"loginticket.js","sourceRoot":"","sources":["../../../src/auth/loginticket.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,MAAa,WAAW;IAItB;;;;;;OAMG;IACH,YAAY,GAAY,EAAE,GAAkB;QAC1C,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC;QACpB,IAAI,CAAC,OAAO,GAAG,GAAG,CAAC;IACrB,CAAC;IAED,WAAW;QACT,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IAED,UAAU;QACR,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IAED;;;;OAIG;IACH,SAAS;QACP,MAAM,OAAO,GAAG,IAAI,CAAC,UAAU,EAAE,CAAC;QAClC,IAAI,OAAO,IAAI,OAAO,CAAC,GAAG,EAAE;YAC1B,OAAO,OAAO,CAAC,GAAG,CAAC;SACpB;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;OAKG;IACH,aAAa;QACX,OAAO,EAAC,QAAQ,EAAE,IAAI,CAAC,WAAW,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,UAAU,EAAE,EAAC,CAAC;IACpE,CAAC;CACF;AA9CD,kCA8CC"}

View File

@ -95,16 +95,6 @@ export interface TokenInfo {
*/
access_type?: string;
}
export interface TokenInfoRequest {
aud: string;
user_id?: string;
scope: string;
expires_in: number;
azp?: string;
sub?: string;
exp?: number;
access_type?: string;
}
export interface GenerateAuthUrlOpts {
/**
* Recommended. Indicates whether your application can refresh access tokens
@ -117,6 +107,19 @@ export interface GenerateAuthUrlOpts {
* tokens.
*/
access_type?: string;
/**
* The hd (hosted domain) parameter streamlines the login process for G Suite
* hosted accounts. By including the domain of the G Suite user (for example,
* mycollege.edu), you can indicate that the account selection UI should be
* optimized for accounts at that domain. To optimize for G Suite accounts
* generally instead of just one domain, use an asterisk: hd=*.
* Don't rely on this UI optimization to control who can access your app,
* as client-side requests can be modified. Be sure to validate that the
* returned ID token has an hd claim value that matches what you expect
* (e.g. mycolledge.edu). Unlike the request parameter, the ID token claim is
* contained within a security token from Google, so the value can be trusted.
*/
hd?: string;
/**
* The 'response_type' will always be set to 'CODE'.
*/
@ -285,7 +288,7 @@ export declare class OAuth2Client extends AuthClient {
*/
constructor(options?: OAuth2ClientOptions);
constructor(clientId?: string, clientSecret?: string, redirectUri?: string);
protected static readonly GOOGLE_TOKEN_INFO_URL: string;
protected static readonly GOOGLE_TOKEN_INFO_URL = "https://oauth2.googleapis.com/tokeninfo";
/**
* The base URL for auth endpoints.
*/
@ -413,8 +416,8 @@ export declare class OAuth2Client extends AuthClient {
* @param options that contains all options.
* @param callback Callback supplying GoogleLogin if successful
*/
verifyIdToken(options: VerifyIdTokenOptions): Promise<LoginTicket | null>;
verifyIdToken(options: VerifyIdTokenOptions, callback: (err: Error | null, login?: LoginTicket | null) => void): void;
verifyIdToken(options: VerifyIdTokenOptions): Promise<LoginTicket>;
verifyIdToken(options: VerifyIdTokenOptions, callback: (err: Error | null, login?: LoginTicket) => void): void;
private verifyIdTokenAsync;
/**
* Obtains information about the provisioned access token. Especially useful

View File

@ -295,7 +295,8 @@ class OAuth2Client extends authclient_1.AuthClient {
revokeToken(token, callback) {
const opts = {
url: OAuth2Client.GOOGLE_OAUTH2_REVOKE_URL_ + '?' +
querystring.stringify({ token })
querystring.stringify({ token }),
method: 'POST'
};
if (callback) {
this.transporter.request(opts).then(r => callback(null, r), callback);

File diff suppressed because one or more lines are too long

View File

@ -47,9 +47,11 @@ class UserRefreshClient extends oauth2client_1.OAuth2Client {
* @param callback Optional callback.
*/
refreshTokenNoCache(refreshToken) {
const _super = name => super[name];
const _super = Object.create(null, {
refreshTokenNoCache: { get: () => super.refreshTokenNoCache }
});
return __awaiter(this, void 0, void 0, function* () {
return _super("refreshTokenNoCache").call(this, this._refreshToken);
return _super.refreshTokenNoCache.call(this, this._refreshToken);
});
}
/**

View File

@ -1 +0,0 @@
{"version":3,"file":"refreshclient.js","sourceRoot":"","sources":["../../../src/auth/refreshclient.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;;;;;;;AAIH,iDAA8E;AAQ9E,MAAa,iBAAkB,SAAQ,2BAAY;IAgBjD,YACI,iBAAmD,EACnD,YAAqB,EAAE,YAAqB,EAC5C,2BAAoC;QACtC,MAAM,IAAI,GAAG,CAAC,iBAAiB,IAAI,OAAO,iBAAiB,KAAK,QAAQ,CAAC,CAAC,CAAC;YACvE,iBAAiB,CAAC,CAAC;YACnB;gBACE,QAAQ,EAAE,iBAAiB;gBAC3B,YAAY;gBACZ,YAAY;gBACZ,2BAA2B;aAC5B,CAAC;QACN,KAAK,CAAC;YACJ,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,2BAA2B,EAAE,IAAI,CAAC,2BAA2B;SAC9D,CAAC,CAAC;QACH,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,YAAY,CAAC;IACzC,CAAC;IAED;;;;OAIG;IACa,mBAAmB,CAAC,YACI;;;YACtC,OAAO,6BAAyB,YAAC,IAAI,CAAC,aAAa,EAAE;QACvD,CAAC;KAAA;IAED;;;;OAIG;IACH,QAAQ,CAAC,IAAc;QACrB,IAAI,CAAC,IAAI,EAAE;YACT,MAAM,IAAI,KAAK,CACX,8DAA8D,CAAC,CAAC;SACrE;QACD,IAAI,IAAI,CAAC,IAAI,KAAK,iBAAiB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AAE,EAAE,CAAC,CAAC,IAAI,KAAK,CAAC;qBACjC,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;oBACd,IAAI;wBACF,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;wBAC3B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;wBACpB,OAAO,OAAO,EAAE,CAAC;qBAClB;oBAAC,OAAO,GAAG,EAAE;wBACZ,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;qBACpB;gBACH,CAAC,CAAC,CAAC;YACT,CAAC,CAAC,CAAC;QACL,CAAC;KAAA;CACF;AArHD,8CAqHC"}

View File

@ -15,13 +15,14 @@
*/
import { GoogleAuth } from './auth/googleauth';
export { Compute, ComputeOptions } from './auth/computeclient';
export { Credentials } from './auth/credentials';
export { CredentialBody, CredentialRequest, Credentials, JWTInput } from './auth/credentials';
export { GCPEnv } from './auth/envDetect';
export { GoogleAuthOptions } from './auth/googleauth';
export { IAMAuth } from './auth/iam';
export { JWTAccess } from './auth/jwtaccess';
export { JWT } from './auth/jwtclient';
export { CodeChallengeMethod, OAuth2Client } from './auth/oauth2client';
export { UserRefreshClient } from './auth/refreshclient';
export { IAMAuth, RequestMetadata } from './auth/iam';
export { Claims, JWTAccess } from './auth/jwtaccess';
export { JWT, JWTOptions } from './auth/jwtclient';
export { Certificates, CodeChallengeMethod, GenerateAuthUrlOpts, GetTokenOptions, OAuth2Client, OAuth2ClientOptions, RefreshOptions, TokenInfo, VerifyIdTokenOptions } from './auth/oauth2client';
export { UserRefreshClient, UserRefreshClientOptions } from './auth/refreshclient';
export { DefaultTransporter } from './transporters';
declare const auth: GoogleAuth;
export { auth, GoogleAuth };

View File

@ -19,6 +19,8 @@ const googleauth_1 = require("./auth/googleauth");
exports.GoogleAuth = googleauth_1.GoogleAuth;
var computeclient_1 = require("./auth/computeclient");
exports.Compute = computeclient_1.Compute;
var envDetect_1 = require("./auth/envDetect");
exports.GCPEnv = envDetect_1.GCPEnv;
var iam_1 = require("./auth/iam");
exports.IAMAuth = iam_1.IAMAuth;
var jwtaccess_1 = require("./auth/jwtaccess");

View File

@ -1 +0,0 @@
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;AAAA;;;;;;;;;;;;;;GAcG;AACH,kDAA6C;AAa/B,qBAbN,uBAAU,CAaM;AAXxB,sDAA6D;AAArD,kCAAA,OAAO,CAAA;AAGf,kCAAmC;AAA3B,wBAAA,OAAO,CAAA;AACf,8CAA2C;AAAnC,gCAAA,SAAS,CAAA;AACjB,8CAAqC;AAA7B,0BAAA,GAAG,CAAA;AACX,oDAAsE;AAA9D,6CAAA,mBAAmB,CAAA;AAAE,sCAAA,YAAY,CAAA;AACzC,sDAAuD;AAA/C,4CAAA,iBAAiB,CAAA;AACzB,+CAAkD;AAA1C,4CAAA,kBAAkB,CAAA;AAE1B,MAAM,IAAI,GAAG,IAAI,uBAAU,EAAE,CAAC;AACtB,oBAAI"}

View File

@ -1 +0,0 @@
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../src/messages.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,iCAAiC;AAEjC,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,mCAAmB,CAAA;IACnB,kDAAkC,CAAA;AACpC,CAAC,EAHW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAGvB;AAED,SAAgB,IAAI,CAAC,OAAgB;IACnC,iCAAiC;IACjC,IAAI,OAAO,CAAC,MAAM,EAAE;QAClB,OAAO;KACR;IACD,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IACtB,IAAI,MAAM,CAAC,SAAS,CAAC,OAAO,CAAC,OAAO,EAAE,KAAK,CAAC,EAAE;QAC5C,6DAA6D;QAC7D,6CAA6C;QAC7C,mGAAmG;QACnG,kCAAkC;QAClC,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,EAAE,OAAc,CAAC,CAA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AAC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAC;QACtE,EAAC,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAC;KACpC,CAAC;IACF,KAAK,MAAM,IAAI,IAAI,MAAM,EAAE;QACzB,IAAI,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE;YACzB,MAAM,CAAC,GAAG,IACN,IAAI,CAAC,OAAO,sDACZ,IAAI,CAAC,QAAQ,+IAA+I,CAAC;YACjK,MAAM,IAAI,KAAK,CAAC,CAAC,CAAC,CAAC;SACpB;KACF;AACH,CAAC;AAbD,4BAaC"}

View File

@ -1 +0,0 @@
{"version":3,"file":"pemverifier.js","sourceRoot":"","sources":["../../src/pemverifier.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,iCAAiC;AAEjC,MAAa,WAAW;IACtB,MAAM,CACF,MAAc,EAAE,IAAmB,EAAE,SAAiB,EACtD,QAAwC;QAC1C,MAAM,QAAQ,GAAG,MAAM,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;QAC/C,QAAQ,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;QACtB,OAAO,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC;IACtD,CAAC;CACF;AARD,kCAQC"}

View File

@ -1 +0,0 @@
{"version":3,"file":"transporters.js","sourceRoot":"","sources":["../../src/transporters.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;AAEH,iCAAyF;AACzF,uCAAmC;AAEnC,yCAAyC;AACzC,MAAM,eAAe,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;AAErD,2CAA2C;AAC3C,MAAM,GAAG,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAC1C,MAAM,YAAY,GAAG,0BAA0B,CAAC;AAmBhD;;;;;;GAMG;AACH,eAAK,CAAC,QAAQ,CAAC,OAAO,GAAG,OAAO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AC,MAAM,CAAC;aAChC;iBAAM;gBACL,GAAG,CAAC,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC;gBACjC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,GAAG,CAAC,MAAM,CAAC;aAC1C;SACF;aAAM,IAAI,GAAG,IAAI,GAAG,CAAC,MAAM,IAAI,GAAG,EAAE;YACnC,6CAA6C;YAC7C,GAAG,CAAC,OAAO,GAAG,IAAI,CAAC;YACnB,GAAG,CAAC,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC;SAClC;QACD,OAAO,GAAG,CAAC;IACb,CAAC;;AA/FD;;GAEG;AACa,6BAAU,GAAG,GAAG,YAAY,IAAI,GAAG,CAAC,OAAO,EAAE,CAAC;AAJhE,gDAiGC"}

View File

@ -1,8 +1,8 @@
{
"_from": "google-auth-library@^2.0.0",
"_id": "google-auth-library@2.0.0",
"_id": "google-auth-library@2.0.2",
"_inBundle": false,
"_integrity": "sha512-lN6jecH8L30uAirTeOm9ij9CTMJniwg7fbuyOpgH4lFkO50LKhPrx/ZbLGK8aBCzi/u4/tpdZnJABFuMqtIx0A==",
"_integrity": "sha512-FURxmo1hBVmcfLauuMRKOPYAPKht3dGuI2wjeJFalDUThO0HoYVjr4yxt5cgYSFm1dgUpmN9G/poa7ceTFAIiA==",
"_location": "/google-auth-library",
"_phantomChildren": {},
"_requested": {
@ -16,13 +16,12 @@
"fetchSpec": "^2.0.0"
},
"_requiredBy": [
"/googleapis",
"/googleapis-common"
"/google-gax"
],
"_resolved": "https://registry.npmjs.org/google-auth-library/-/google-auth-library-2.0.0.tgz",
"_shasum": "55d20e03a9820a1c28ee14cd1b6864b7be38b5e4",
"_resolved": "https://registry.npmjs.org/google-auth-library/-/google-auth-library-2.0.2.tgz",
"_shasum": "7a315d2036744af6afcad87b210ee6638b40f57b",
"_spec": "google-auth-library@^2.0.0",
"_where": "C:\\Users\\Georg\\GitHub\\SmartShopper\\express-server\\node_modules\\googleapis",
"_where": "D:\\Desktop\\Git\\Firebase\\SmartShopperFirebase\\node_modules\\google-gax",
"author": {
"name": "Google Inc."
},
@ -36,54 +35,54 @@
"gtoken": "^2.3.0",
"https-proxy-agent": "^2.2.1",
"jws": "^3.1.5",
"lodash.isstring": "^4.0.1",
"lru-cache": "^4.1.3",
"lru-cache": "^5.0.0",
"semver": "^5.5.0"
},
"deprecated": false,
"description": "Google APIs Authentication Client Library for Node.js",
"devDependencies": {
"@compodoc/compodoc": "^1.1.7",
"@types/execa": "^0.9.0",
"@types/jws": "^3.1.0",
"@types/lodash.isstring": "^4.0.3",
"@types/lru-cache": "^4.1.0",
"@types/mocha": "^5.2.1",
"@types/mv": "^2.1.0",
"@types/ncp": "^2.0.1",
"@types/nock": "^9.1.3",
"@types/node": "^10.5.1",
"@types/pify": "^3.0.2",
"@types/semver": "^5.5.0",
"@types/sinon": "^5.0.1",
"@types/sinon": "^7.0.0",
"@types/tmp": "^0.0.33",
"assert-rejects": "^1.0.0",
"codecov": "^3.0.2",
"gh-pages": "^1.2.0",
"gts": "^0.8.0",
"hard-rejection": "^1.0.0",
"eslint": "^5.10.0",
"eslint-config-prettier": "^3.3.0",
"eslint-plugin-node": "^8.0.0",
"eslint-plugin-prettier": "^3.0.0",
"execa": "^1.0.0",
"gh-pages": "^2.0.1",
"gts": "^0.9.0",
"intelli-espower-loader": "^1.0.1",
"js-green-licenses": "^0.5.0",
"keypair": "^1.0.1",
"mocha": "^5.2.0",
"mv": "^2.1.1",
"ncp": "^2.0.0",
"nock": "^9.3.0",
"nock": "^10.0.0",
"nyc": "^13.0.0",
"pify": "^4.0.0",
"prettier": "^1.13.4",
"sinon": "^6.0.0",
"sinon": "^7.0.0",
"source-map-support": "^0.5.6",
"tmp": "^0.0.33",
"typedoc": "^0.12.0",
"typescript": "~3.0.0"
"typedoc": "^0.13.0",
"typescript": "~3.2.0"
},
"engines": {
"node": ">=6"
},
"files": [
"LICENSE",
"README.md",
"build/src",
"package.json"
"!build/src/**/*.map"
],
"homepage": "https://github.com/google/google-auth-library-nodejs#readme",
"keywords": [
@ -96,35 +95,25 @@
"license": "Apache-2.0",
"main": "./build/src/index.js",
"name": "google-auth-library",
"nyc": {
"exclude": [
"build/test"
]
},
"repository": {
"type": "git",
"url": "git+https://github.com/google/google-auth-library-nodejs.git"
},
"scripts": {
"check": "gts check",
"clean": "gts clean",
"codecov": "nyc report --reporter=json && codecov -f coverage/*.json",
"compile": "tsc -p .",
"docs": "exit 0; typedoc --excludePrivate --excludeExternals --mode modules --out docs src && touch docs/.nojekyll",
"fix": "gts fix && npm run fix-samples",
"fix-samples": "prettier --write --single-quote samples/*.js",
"docs": "compodoc src/ && touch docs/.nojekyll",
"fix": "gts fix && eslint --fix '**/*.js'",
"license-check": "jsgl --local .",
"lint": "npm run check",
"posttest": "npm run check && npm run license-check",
"lint": "gts check && eslint '**/*.js' && jsgl --local .",
"prepare": "npm run compile",
"presystem-test": "npm run compile",
"pretest": "npm run compile",
"publish-docs": "gh-pages --dotfiles --dist docs --remote upstream",
"publish-docs": "gh-pages -d docs --remote upstream && git push upstream gh-pages",
"samples-test": "mocha samples/system-test",
"system-test": "mocha build/system-test",
"test": "npm run test-only",
"test-only": "nyc mocha build/test"
"test": "nyc mocha build/test"
},
"types": "./build/src/index.d.ts",
"version": "2.0.0"
"version": "2.0.2"
}