Gathering detailed insights and metrics for tsse
Gathering detailed insights and metrics for tsse
Gathering detailed insights and metrics for tsse
Gathering detailed insights and metrics for tsse
sm2tsservice
swagger or yapi mock to typescript services and models
coc-tsserver
javascript and typescript language features extension of coc.nvim
@oribuild/tsserver-lean
lean subset of tsserver that only supports typechecking
mk-sm2tsservice
swagger or yapi mock to typescript services and models
npm install tsse
Typescript
Module System
Min. Node Version
Node Version
NPM Version
86.4
Supply Chain
99.7
Quality
75.6
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
3 Stars
67 Commits
2 Watchers
1 Branches
1 Contributors
Updated on Nov 23, 2023
Latest Version
2.1.0
Package Id
tsse@2.1.0
Unpacked Size
8.86 kB
Size
3.42 kB
File Count
4
NPM Version
6.14.8
Node Version
14.15.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
1
5
⏱ Constant time string/buffer equals.
Coded with ❤️ by Simone Primarosa.
tsse is a string comparison algorithm to prevent Node.js timing attacks.
This differs from
crypto.timingSafeEqual
because it:
- supports both
strings
andBuffers
;- supports inputs of different lengths.
$ npm install --save tsse
1const tsse = require('tsse'); 2 3const hash = '0a4d55a8d778e5022fab701977c5d840bbc486d0'; 4const givenHash = '1265a5eb08997ced279d3854629cba68a378b528'; 5 6if (tsse(hash, givenHash)) { 7 console.log('good hash'); 8} else { 9 console.log('bad hash'); 10} 11// => bad hash
boolean
Does a constant-time String comparison.
NOTE: When hiddenStr
and inputStr
have different lengths hiddenStr
is compared to itself, which makes the comparison non-commutative (time-wise).
Kind: global function
Returns: boolean
- true if equals, false otherwise.
Access: public
Param | Type | Description |
---|---|---|
hiddenStr | string | Buffer | A string that you don't want to leak. |
inputStr | string | Buffer | Another string. |
Contributions are REALLY welcome and if you find a security flaw in this code, PLEASE report it.
See also the list of contributors who participated in this project.
This project is licensed under the MIT License - see the license file for details.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
Found 0/30 approved changesets -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More