@stablelib/blake2b
Advanced tools
Comparing version
@@ -88,7 +88,7 @@ // Copyright (C) 2017 Dmitry Chestnykh | ||
private _vtmp = new Int32Array(32); | ||
private _mtmp = new Int32Array(32); | ||
private _vtmp = new Uint32Array(32); | ||
private _mtmp = new Uint32Array(32); | ||
private _paddedKey: Uint8Array | undefined; // copy of zero-padded key if present | ||
private _initialState: Int32Array; // initial state after initialization | ||
private _initialState: Uint32Array; // initial state after initialization | ||
@@ -324,3 +324,3 @@ constructor(public digestLength = 64, config?: Config) { | ||
state: new Uint32Array(this._state), | ||
buffer: new Uint32Array(this._buffer), | ||
buffer: new Uint8Array(this._buffer), | ||
bufferLength: this._bufferLength, | ||
@@ -327,0 +327,0 @@ ctr: new Uint32Array(this._ctr), |
@@ -28,3 +28,3 @@ import { SerializableHash } from "@stablelib/hash"; | ||
digestLength: number; | ||
readonly blockSize: number; | ||
readonly blockSize = 128; | ||
private _state; | ||
@@ -51,5 +51,5 @@ private _buffer; | ||
cleanSavedState(savedState: SavedState): void; | ||
private _G(v, al, bl, cl, dl, ah, bh, ch, dh, ml0, mh0, ml1, mh1); | ||
private _incrementCounter(n); | ||
private _processBlock(length); | ||
private _G; | ||
private _incrementCounter; | ||
private _processBlock; | ||
} | ||
@@ -56,0 +56,0 @@ export declare type SavedState = { |
@@ -63,4 +63,4 @@ "use strict"; | ||
this._finished = false; | ||
this._vtmp = new Int32Array(32); | ||
this._mtmp = new Int32Array(32); | ||
this._vtmp = new Uint32Array(32); | ||
this._mtmp = new Uint32Array(32); | ||
// Validate digest length. | ||
@@ -265,3 +265,3 @@ if (digestLength < 1 || digestLength > exports.DIGEST_LENGTH) { | ||
state: new Uint32Array(this._state), | ||
buffer: new Uint32Array(this._buffer), | ||
buffer: new Uint8Array(this._buffer), | ||
bufferLength: this._bufferLength, | ||
@@ -268,0 +268,0 @@ ctr: new Uint32Array(this._ctr), |
{ | ||
"name": "@stablelib/blake2b", | ||
"version": "0.10.6", | ||
"version": "0.10.7", | ||
"description": "BLAKE2b cryptographic hash function", | ||
@@ -25,3 +25,4 @@ "main": "./lib/blake2b.js", | ||
"@stablelib/hex": "^0.5.0" | ||
} | ||
}, | ||
"gitHead": "bfc2e6b7c9c3f31c7bb3610b8a0c09d3ef3613ca" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
2322
0.09%223983
-0.5%