Socket
Socket
Sign inDemoInstall

oauth-pkce

Package Overview
Dependencies
0
Maintainers
2
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.6 to 0.0.7

4

dist/index.js

@@ -9,3 +9,3 @@ "use strict";

length = 43;
var cryptoLib = window.msCrypto || window.crypto;
var cryptoLib = (typeof window !== 'undefined') && window.msCrypto || crypto;
var verifier = b64Uri(Array.prototype.map

@@ -21,3 +21,3 @@ .call(cryptoLib.getRandomValues(new Uint8Array(length)), function (number) {

var digest = cryptoLib.subtle.digest('SHA-256', randomArray);
if (window.CryptoOperation) {
if ((typeof window !== 'undefined') && window.CryptoOperation) {
digest.onerror = callback;

@@ -24,0 +24,0 @@ digest.oncomplete = function (event) {

@@ -8,3 +8,3 @@ "use strict";

length = 43;
var cryptoLib = window.msCrypto || window.crypto;
var cryptoLib = (typeof window !== 'undefined') && window.msCrypto || crypto;
var verifier = b64Uri(Array.prototype.map

@@ -20,3 +20,3 @@ .call(cryptoLib.getRandomValues(new Uint8Array(length)), function (number) {

var digest = cryptoLib.subtle.digest('SHA-256', randomArray);
if (window.CryptoOperation) {
if ((typeof window !== 'undefined') && window.CryptoOperation) {
digest.onerror = callback;

@@ -23,0 +23,0 @@ digest.oncomplete = function (event) {

@@ -1,1 +0,1 @@

"use strict";function b64Uri(r){return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function getPkce(r,n){r=r||43;for(var t=window.msCrypto||window.crypto,e=b64Uri(Array.prototype.map.call(t.getRandomValues(new Uint8Array(r)),function(r){return String.fromCharCode(r)}).join("")).substring(0,r),a=new Uint8Array(e.length),o=0;o<e.length;o++)a[o]=e.charCodeAt(o);var i=t.subtle.digest("SHA-256",a);window.CryptoOperation?(i.onerror=n,i.oncomplete=function(r){runCallback(n,e,r.target.result)}):i.then(function(r){runCallback(n,e,r)}).catch(n)}function runCallback(r,n,t){r(null,{verifier:n,challenge:b64Uri(String.fromCharCode.apply(null,new Uint8Array(t)))})}
"use strict";function b64Uri(n){return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function getPkce(n,r){n=n||43;for(var e="undefined"!=typeof window&&window.msCrypto||crypto,t=b64Uri(Array.prototype.map.call(e.getRandomValues(new Uint8Array(n)),function(n){return String.fromCharCode(n)}).join("")).substring(0,n),o=new Uint8Array(t.length),a=0;a<t.length;a++)o[a]=t.charCodeAt(a);var i=e.subtle.digest("SHA-256",o);"undefined"!=typeof window&&window.CryptoOperation?(i.onerror=r,i.oncomplete=function(n){runCallback(r,t,n.target.result)}):i.then(function(n){runCallback(r,t,n)}).catch(r)}function runCallback(n,r,e){n(null,{verifier:r,challenge:b64Uri(String.fromCharCode.apply(null,new Uint8Array(e)))})}
{
"name": "oauth-pkce",
"version": "0.0.6",
"version": "0.0.7",
"description": "OAUTH PKCE code_verifier and code_challenge generator",

@@ -72,3 +72,3 @@ "main": "./dist/index.js",

},
"gitHead": "dd7bfef9795c3dc80b3f2bdf1abfb1945bafc347"
"gitHead": "35d274d6b5fd8619751f31a4e74d94f3204589f6"
}
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc