Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@mybiogen/auth-openid

Package Overview
Dependencies
Maintainers
14
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mybiogen/auth-openid - npm Package Compare versions

Comparing version 1.5.4 to 1.5.5

lib/encodeBody.d.ts

1

lib/OAuthClient.d.ts

@@ -34,2 +34,3 @@ import { OAuthUserInfo, Token, WatchAuthCallback, Init, AuthenticateExtraParams } from './types';

private keepRefreshingToken;
private waitForAuthorizationEndpoint;
watchAuth: (cb: WatchAuthCallback<UserInfo, Claims>) => Promise<void>;

@@ -36,0 +37,0 @@ private fetchConfig;

@@ -91,2 +91,24 @@ "use strict";

};
this.waitForAuthorizationEndpoint = function (callback) {
if (_this.authorizationEndpoint) {
callback();
return;
}
var UPDATE_INTERVAL = 200;
var MAXIMUM_WAITING_TIME = 5000;
var attemptsAmount = MAXIMUM_WAITING_TIME / UPDATE_INTERVAL;
var interval = window.setInterval(function () {
if (_this.authorizationEndpoint) {
clearInterval(interval);
callback();
}
else {
if (attemptsAmount === 0) {
clearInterval(interval);
throw new Error('Authorization endpoint waiting time has been exceeded.');
}
attemptsAmount--;
}
}, UPDATE_INTERVAL);
};
this.watchAuth = function (cb) { return __awaiter(_this, void 0, void 0, function () {

@@ -275,12 +297,12 @@ return __generator(this, function (_a) {

var loginQuery = query_string_1.default.stringify(params);
if (_this.authorizationEndpoint) {
var url = _this.authorizationEndpoint + "?" + loginQuery;
window.location.replace(url);
}
var url = _this.authorizationEndpoint + "?" + loginQuery;
window.location.replace(url);
};
this.login = function (forcedRedirectTo, extraParams) {
_this.authenticate({ forcedRedirectTo: forcedRedirectTo, extraParams: extraParams });
var authenticate = function () { return _this.authenticate({ forcedRedirectTo: forcedRedirectTo, extraParams: extraParams }); };
_this.waitForAuthorizationEndpoint(authenticate);
};
this.signup = function (forcedRedirectTo, extraParams) {
_this.authenticate({ forcedRedirectTo: forcedRedirectTo, extraParams: extraParams, isSignup: true });
var authenticate = function () { return _this.authenticate({ forcedRedirectTo: forcedRedirectTo, extraParams: extraParams, isSignup: true }); };
_this.waitForAuthorizationEndpoint(authenticate);
};

@@ -470,2 +492,2 @@ this.getUserInfo = function () { return __awaiter(_this, void 0, void 0, function () {

exports.default = OpenIDClient;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiT0F1dGhDbGllbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi9zcmMvT0F1dGhDbGllbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7Ozs7OztBQUFBLDhEQUF1QztBQUN2Qyw2QkFBb0M7QUFDcEMsaUNBQTBHO0FBWTFHO0lBdUNFLHNCQUFZLFFBQWdCLEVBQUUsU0FBaUIsRUFBRSxXQUFtQixFQUFFLFVBQWtCLEVBQUUsaUJBQXlCLEVBQUUsTUFBNkIsRUFBRSxNQUFnQztRQUFwTCxpQkFnQ0M7UUFoQ29ILHVCQUFBLEVBQUEsVUFBb0IsUUFBUSxDQUFDO1FBQUUsdUJBQUEsRUFBQSxXQUFnQztRQVZwTCxjQUFTLEdBQStDLEVBQUUsQ0FBQztRQTRIbkQsd0JBQW1CLEdBQUc7O1lBQzVCLElBQUksUUFBQyxLQUFJLENBQUMsS0FBSywwQ0FBRSxZQUFZLENBQUEsRUFBRTtnQkFDN0IsT0FBTyxDQUFDLElBQUksQ0FBQyx3QkFBd0IsQ0FBQyxDQUFBO2dCQUN0QyxPQUFPO2FBQ1I7WUFFRCxJQUFJLEtBQUksQ0FBQyxJQUFJLElBQUksS0FBSSxDQUFDLEtBQUssSUFBSSxDQUFDLEtBQUksQ0FBQyxvQkFBb0IsRUFBRTtnQkFDekQsSUFBTSx3QkFBd0IsR0FB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MDA7IC8vIDEgbWluXG4gICAgICB0aGlzLnJlZnJlc2hUb2tlbkludGVydmFsID0gd2luZG93LnNldEludGVydmFsKGFzeW5jICgpID0+IHtcbiAgICAgICAgdHJ5IHtcbiAgICAgICAgICBhd2FpdCB0aGlzLnJlZnJlc2hUb2tlbigpO1xuICAgICAgICB9IGNhdGNoIChlcnJvcikge1xuICAgICAgICAgIGNsZWFySW50ZXJ2YWwodGhpcy5yZWZyZXNoVG9rZW5JbnRlcnZhbCk7XG4gICAgICAgICAgdGhpcy5sb2dvdXQoKTtcbiAgICAgICAgfVxuICAgICAgfSwgKHRoaXMudG9rZW4uZXhwaXJlc0luICogMTAwMCkgLSBTQUZFVFlfR0FQX1JFRlJFU0hfVE9LRU4pO1xuICAgIH1cbiAgfTtcblxuICBwcml2YXRlIHdhaXRGb3JBdXRob3JpemF0aW9uRW5kcG9pbnQgPSAoY2FsbGJhY2spOiB2b2lkID0+IHtcbiAgICBpZiAodGhpcy5hdXRob3JpemF0aW9uRW5kcG9pbnQpIHtcbiAgICAgIGNhbGxiYWNrKCk7XG4gICAgICByZXR1cm47XG4gICAgfVxuXG4gICAgY29uc3QgVVBEQVRFX0lOVEVSVkFMID0gMjAwOyAvLyAwLjIgc2Vjb25kXG4gICAgY29uc3QgTUFYSU1VTV9XQUlUSU5HX1RJTUUgPSA1MDAwOyAvLyA1IHNlY29uZHNcbiAgICBsZXQgYXR0ZW1wdHNBbW91bnQgPSBNQVhJTVVNX1dBSVRJTkdfVElNRSAvIFVQREFURV9JTlRFUlZBTDtcblxuICAgIGNvbnN0IGludGVydmFsID0gd2luZG93LnNldEludGVydmFsKCgpID0+IHtcbiAgICAgIGlmICh0aGlzLmF1dGhvcml6YXRpb25FbmRwb2ludCkge1xuICAgICAgICBjbGVhckludGVydmFsKGludGVydmFsKTtcbiAgICAgICAgY2FsbGJhY2soKTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIGlmIChhdHRlbXB0c0Ftb3VudCA9PT0gMCkge1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kU2Vzc2lvblVSSSk7XG4gICAgfSBlbHNlIHtcbiAgICAgIC8vIE9rdGFKU1xuICAgICAgY29uc3QgcGFyYW1zID0ge1xuICAgICAgICAnaWRfdG9rZW5faGludCc6IHRoaXMudG9rZW4/LmlkVG9rZW4sXG4gICAgICAgICdwb3N0X2xvZ291dF9yZWRpcmVjdF91cmknOiB0aGlzLmxvZ291dFJlZGlyZWN0VVJJLFxuICAgICAgfTtcbiAgICAgIGlmICh0aGlzLmVuZFNlc3Npb25FbmRwb2ludCkge1xuICAgICAgICBjb25zdCB1cmwgPSBgJHt0aGlzLmVuZFNlc3Npb25FbmRwb2ludH0/JHtxdWVyeVN0cmluZy5zdHJpbmdpZnkocGFyYW1zKX1gO1xuICAgICAgICB3aW5kb3cubG9jYXRpb24ucmVwbGFjZSh1cmwpOyAgXG4gICAgICB9XG4gICAgfVxuXG4gIH07XG59XG4iXX0=

4

package.json
{
"name": "@mybiogen/auth-openid",
"version": "1.5.4",
"version": "1.5.5",
"description": "Authorization for OpenID",

@@ -35,3 +35,3 @@ "license": "MIT",

},
"gitHead": "b9bcb880b5599cebd001440bdaf24e2cd48cbf8f"
"gitHead": "d01f659ff35b6ffc9dfd5e7800c32af7d2b9f7b5"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc