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

otplib

Package Overview
Dependencies
Maintainers
1
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

otplib - npm Package Compare versions

Comparing version 10.0.0 to 10.0.1

2

authenticator.js

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -8,0 +8,0 @@ **/

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -8,0 +8,0 @@ **/

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -8,0 +8,0 @@ **/

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -8,0 +8,0 @@ **/

{
"name": "otplib",
"version": "10.0.0",
"version": "10.0.1",
"description": "HMAC-based (HOTP) and Time-based (TOTP) One-Time Password library",

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

"dtslint": "^0.3.0",
"eslint": "^4.18.2",
"eslint": "^5.0.0",
"eslint-config-prettier": "^2.9.0",

@@ -57,5 +57,5 @@ "eslint-plugin-prettier": "^2.6.0",

"minami": "^1.1.1",
"prettier": "1.13.5",
"prettier": "1.13.7",
"rimraf": "^2.6.1",
"rollup": "^0.60.0",
"rollup": "^0.62.0",
"rollup-plugin-cleanup": "^2.0.0",

@@ -62,0 +62,0 @@ "rollup-plugin-node-resolve": "^3.0.0",

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -8,0 +8,0 @@ **/

@@ -5,3 +5,3 @@ /**

* @author Gerald Yeo <contact@fusedthought.com>
* @version: 10.0.0
* @version: 10.0.1
* @license: MIT

@@ -21,4 +21,10 @@ **/

function isValidToken(value) {
return /^(\d+)(\.\d+)?$/.test(value);
}
function isSameToken(token1, token2) {
return parseFloat(token1) === parseFloat(token2);
if (isValidToken(token1) && isValidToken(token2)) {
return String(token1) === String(token2);
}
return false;
}

@@ -25,0 +31,0 @@

Sorry, the diff of this file is too big to display

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