taler-typescript-core

Wallet core logic and WebUIs for various components
Log | Files | Refs | Submodules | README | LICENSE

commit 6861f514657445e734625c75048d8a4c4b0769a6
parent c84ac97dc1de944834c3fa6b5c97e58b57ae1f25
Author: hellekin <hellekin@cepheide.org>
Date:   Tue, 17 Feb 2026 21:42:40 +0100

Fix the COIN-gate (closes #11098)

@avalos coined the COIN-gate, this bug stemming from 'cosmetic change'
meaning to respect the original specification, and turned out to be a
nightmare for already deployed exchanges like NETZBON and BOOKZ.

What this fix does is to normalize all coin denominations references in
taler-harness to use lowercase characters. Since the Exchange
documentation uses taler-harness gen-coin-config... to generate
configuration files, it actually solves Exchange installation and
maintenance by making coin denomination config generation compliant and
consistent.

Diffstat:
Mpackages/taler-harness/src/harness/harness.ts | 2+-
Mpackages/taler-harness/src/index.ts | 2+-
Mpackages/taler-harness/src/lint.ts | 7+++----
3 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/packages/taler-harness/src/harness/harness.ts b/packages/taler-harness/src/harness/harness.ts @@ -1768,7 +1768,7 @@ export class ExchangeService implements ExchangeServiceInterface { .getPath("taler-exchange-secmod-eddsa", "KEY_DIR") .required(); // Be *VERY* careful when changing this, or you will accidentally delete user data. - await sh(this.globalState, "rm-secmod-keys", `rm -rf ${rsaKeydir}/COIN_*`); + await sh(this.globalState, "rm-secmod-keys", `rm -rf ${rsaKeydir}/coin_*`); await sh(this.globalState, "rm-secmod-keys", `rm ${eddsaKeydir}/*`); } diff --git a/packages/taler-harness/src/index.ts b/packages/taler-harness/src/index.ts @@ -1566,7 +1566,7 @@ deploymentCli spec: feespecRefund, }); - out += `[COIN_${currency}_n${n}_t${stamp}]\n`; + out += `[coin_${currency}_n${n}_t${stamp}]\n`; out += `VALUE = ${Amounts.stringify(x)}\n`; out += `DURATION_WITHDRAW = 7 days\n`; out += `DURATION_SPEND = 2 years\n`; diff --git a/packages/taler-harness/src/lint.ts b/packages/taler-harness/src/lint.ts @@ -169,12 +169,11 @@ function checkBasicConf(context: LintContext): BasicConf { function checkCoinConfig(context: LintContext, basic: BasicConf): void { const cfg = context.cfg; - const coinPrefix1 = "COIN_"; - const coinPrefix2 = "COIN-"; + const coinPrefix = "coin_"; let numCoins = 0; for (const secName of cfg.getSectionNames()) { - if (!(secName.startsWith(coinPrefix1) || secName.startsWith(coinPrefix2))) { + if (!secName.startsWith(coinPrefix)) { continue; } numCoins++; @@ -185,7 +184,7 @@ function checkCoinConfig(context: LintContext, basic: BasicConf): void { if (numCoins == 0) { context.numErr++; console.log( - "error: no coin denomination configured, please configure [coin-*] sections", + "error: no coin denomination configured, please configure [coin_*] sections", ); } }