mirror of
https://codeberg.org/keyoxide/doipjs.git
synced 2024-12-22 22:49:28 -07:00
chore: release 1.1.1
This commit is contained in:
parent
beb78e8227
commit
ba6941448c
9 changed files with 54 additions and 9 deletions
|
@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [1.1.1] - 2023-09-22
|
||||||
|
### Fixed
|
||||||
|
- Normalize case before hashed proof verification
|
||||||
|
|
||||||
## [1.1.0] - 2023-09-21
|
## [1.1.0] - 2023-09-21
|
||||||
### Changed
|
### Changed
|
||||||
- Unify fromJSON() for Profile, Persona and Claim classes
|
- Unify fromJSON() for Profile, Persona and Claim classes
|
||||||
|
|
41
dist/doip.core.js
vendored
41
dist/doip.core.js
vendored
|
@ -2586,6 +2586,27 @@ var doip = (function (exports, openpgp$1, fetcher) {
|
||||||
case '2a':
|
case '2a':
|
||||||
case '2b':
|
case '2b':
|
||||||
case '2y':
|
case '2y':
|
||||||
|
try {
|
||||||
|
// Patch until promise.race properly works on WASM
|
||||||
|
if (parseInt(match[0].split('$')[2]) > 12) continue
|
||||||
|
|
||||||
|
const hashPromise = bcryptVerify({
|
||||||
|
password: fingerprintURI.toLowerCase(),
|
||||||
|
hash: match[0]
|
||||||
|
})
|
||||||
|
.then(result => result)
|
||||||
|
.catch(_ => false);
|
||||||
|
|
||||||
|
result = await Promise.race([hashPromise, timeoutPromise]).then((result) => {
|
||||||
|
clearTimeout(timeoutHandle);
|
||||||
|
return result
|
||||||
|
});
|
||||||
|
} catch (err) {
|
||||||
|
result = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Accept mixed-case fingerprints until deadline
|
||||||
|
if (!result) {
|
||||||
try {
|
try {
|
||||||
// Patch until promise.race properly works on WASM
|
// Patch until promise.race properly works on WASM
|
||||||
if (parseInt(match[0].split('$')[2]) > 12) continue
|
if (parseInt(match[0].split('$')[2]) > 12) continue
|
||||||
|
@ -2604,12 +2625,31 @@ var doip = (function (exports, openpgp$1, fetcher) {
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
result = false;
|
result = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
break
|
break
|
||||||
|
|
||||||
case 'argon2':
|
case 'argon2':
|
||||||
case 'argon2i':
|
case 'argon2i':
|
||||||
case 'argon2d':
|
case 'argon2d':
|
||||||
case 'argon2id':
|
case 'argon2id':
|
||||||
|
try {
|
||||||
|
const hashPromise = argon2Verify({
|
||||||
|
password: fingerprintURI.toLowerCase(),
|
||||||
|
hash: match[0]
|
||||||
|
})
|
||||||
|
.then(result => result)
|
||||||
|
.catch(_ => false);
|
||||||
|
|
||||||
|
result = await Promise.race([hashPromise, timeoutPromise]).then((result) => {
|
||||||
|
clearTimeout(timeoutHandle);
|
||||||
|
return result
|
||||||
|
});
|
||||||
|
} catch (err) {
|
||||||
|
result = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Accept mixed-case fingerprints until deadline
|
||||||
|
if (!result) {
|
||||||
try {
|
try {
|
||||||
const hashPromise = argon2Verify({
|
const hashPromise = argon2Verify({
|
||||||
password: fingerprintURI,
|
password: fingerprintURI,
|
||||||
|
@ -2625,6 +2665,7 @@ var doip = (function (exports, openpgp$1, fetcher) {
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
result = false;
|
result = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
2
dist/doip.core.min.js
vendored
2
dist/doip.core.min.js
vendored
File diff suppressed because one or more lines are too long
2
dist/doip.fetchers.js
vendored
2
dist/doip.fetchers.js
vendored
|
@ -2728,7 +2728,7 @@ var doipFetchers = (function (exports) {
|
||||||
* doip.js library version
|
* doip.js library version
|
||||||
* @constant {string}
|
* @constant {string}
|
||||||
*/
|
*/
|
||||||
const version = '1.1.0';
|
const version = '1.1.1';
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Copyright 2022 Yarmo Mackenbach
|
Copyright 2022 Yarmo Mackenbach
|
||||||
|
|
2
dist/doip.fetchers.min.js
vendored
2
dist/doip.fetchers.min.js
vendored
File diff suppressed because one or more lines are too long
2
dist/doip.fetchers.minimal.js
vendored
2
dist/doip.fetchers.minimal.js
vendored
|
@ -2698,7 +2698,7 @@ var doipFetchers = (function (exports) {
|
||||||
* doip.js library version
|
* doip.js library version
|
||||||
* @constant {string}
|
* @constant {string}
|
||||||
*/
|
*/
|
||||||
const version = '1.1.0';
|
const version = '1.1.1';
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Copyright 2022 Yarmo Mackenbach
|
Copyright 2022 Yarmo Mackenbach
|
||||||
|
|
2
dist/doip.fetchers.minimal.min.js
vendored
2
dist/doip.fetchers.minimal.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "doipjs",
|
"name": "doipjs",
|
||||||
"version": "1.1.0",
|
"version": "1.1.1",
|
||||||
"description": "Decentralized Online Identity Proofs library in Node.js",
|
"description": "Decentralized Online Identity Proofs library in Node.js",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./src/index.js",
|
"main": "./src/index.js",
|
||||||
|
|
|
@ -22,4 +22,4 @@ limitations under the License.
|
||||||
* doip.js library version
|
* doip.js library version
|
||||||
* @constant {string}
|
* @constant {string}
|
||||||
*/
|
*/
|
||||||
export const version = '1.1.0'
|
export const version = '1.1.1'
|
||||||
|
|
Loading…
Reference in a new issue