diff options
author | Florian Dold <florian@dold.me> | 2022-02-21 16:17:59 +0100 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2022-02-21 16:17:59 +0100 |
commit | 5fbe82b3746d63a69dc6c0c5b0b4980aa357f085 (patch) | |
tree | d3d0062e0831d7dcad13b2be8c352183a274f938 | |
parent | 5c93f15157b4fc9d0fefb6bb2a9956592ebb1ec9 (diff) |
disable setupRefreshPlanchet C crypto worker call
-rw-r--r-- | packages/taler-util/src/talerCrypto.ts | 19 | ||||
-rw-r--r-- | packages/taler-wallet-core/src/crypto/workers/cryptoImplementation.ts | 3 |
2 files changed, 3 insertions, 19 deletions
diff --git a/packages/taler-util/src/talerCrypto.ts b/packages/taler-util/src/talerCrypto.ts index 40d2e55da..83e5dc6fe 100644 --- a/packages/taler-util/src/talerCrypto.ts +++ b/packages/taler-util/src/talerCrypto.ts @@ -608,6 +608,7 @@ export function hashCoinEv( return hashContext.finish(); } + const logger = new Logger("talerCrypto.ts"); export function hashCoinEvInner( @@ -682,24 +683,6 @@ export interface FreshCoin { bks: Uint8Array; } -// export function setupRefreshPlanchet( -// secretSeed: Uint8Array, -// coinNumber: number, -// ): FreshCoin { -// const info = stringToBytes("taler-coin-derivation"); -// const saltArrBuf = new ArrayBuffer(4); -// const salt = new Uint8Array(saltArrBuf); -// const saltDataView = new DataView(saltArrBuf); -// saltDataView.setUint32(0, coinNumber); -// const out = kdf(64, secretSeed, salt, info); -// const coinPriv = out.slice(0, 32); -// const bks = out.slice(32, 64); -// return { -// bks, -// coinPriv, -// coinPub: eddsaGetPublic(coinPriv), -// }; -// } function bufferForUint32(n: number): Uint8Array { const arrBuf = new ArrayBuffer(4); diff --git a/packages/taler-wallet-core/src/crypto/workers/cryptoImplementation.ts b/packages/taler-wallet-core/src/crypto/workers/cryptoImplementation.ts index 9f6d82348..bd18e8d2e 100644 --- a/packages/taler-wallet-core/src/crypto/workers/cryptoImplementation.ts +++ b/packages/taler-wallet-core/src/crypto/workers/cryptoImplementation.ts @@ -557,7 +557,8 @@ export class CryptoImplementation { let coinPub: Uint8Array; let coinPriv: Uint8Array; let blindingFactor: Uint8Array; - if (this.primitiveWorker) { + // disabled while not implemented in the C code + if (0 && this.primitiveWorker) { const r = await this.primitiveWorker.setupRefreshPlanchet({ transfer_secret: encodeCrock(transferSecret), coin_index: coinIndex, |