1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-12-01 04:43:29 +03:00

Merge pull request #1221 from matrix-org/travis/qr-binary

Reduce secret size for new binary packing
This commit is contained in:
Travis Ralston
2020-02-21 10:05:03 -07:00
committed by GitHub

View File

@@ -410,7 +410,7 @@ export class VerificationRequest extends EventEmitter {
}
_generateSharedSecret() {
const secretBytes = new Uint8Array(32); // 256bits
const secretBytes = new Uint8Array(8);
global.crypto.getRandomValues(secretBytes);
this._sharedSecret = olmlib.encodeBase64(secretBytes);
}