chore: tooling, docs and a guard for the name (fork, Phase 6)

- rootProject.name is Giza. Res is pinned, so no import moves.
- Regtest: GIZA_REGTEST, GIZA_SPLICE_DELAYS and the gizaRegtest task input;
  node aliases giza-lsp and giza-payer.
- README describes Giza and says what it shares with Bennu: one network, one
  derivation, and a recovery phrase that must not run in both apps at once.
  The clone URL is the planned giza-kmp repository, which does not exist yet.
- docs/README.md is titled Giza docs and says how to read the documents
  written while the app was Bennu.
- CLAUDE.md gains the rule: name the app Giza, never name Bennu outside a
  comment, and never rename a mantra/ or bennu/ derivation tag.
- docs/scripts/brand-audit.sh --check, run by check (brandAudit) and by the CI
  budgets job, fails on Bennu anywhere in composeApp, iosApp, testing or the
  gradle scripts except in a comment or a "bennu/ tag. It catches the strings
  a merge from Bennu brings in, which giza-rename.sh cannot word.
- The plan gains the twelve bennu/ tags, missed when it was written.

jvmTest: 1643 run, 0 failed, 2 skipped. compileDebugKotlinAndroid, m3Audit and
brandAudit pass.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Kgothatso NgakoandClaude Opus 5.5 committed 2026-11-18 10:53:17 +02:00
1 parent 4f3f0da3ca
commit 5b92b83869
16 files changed
+164 -24

No files matched your search

+6 -1
View File
@@ -1,9 +1,14 @@
# curare docs
# Giza docs
Notes on the parts of this app whose behaviour is not recoverable by reading the
code alone — where the reasoning lives in a protocol, a failure mode that is
silent, or a decision that looked arbitrary and was not.
Most of them were written while the app was Bennu, before the fork, and they say so where it
matters: a decision taken in Bennu was taken in Bennu. Source paths in them point at
`mobi/giza`. Strings spelled `bennu/…` in their formulas are derivation tags that the fork kept
on purpose ([giza-rebrand.md](./giza-rebrand.md)).
| document | covers |
|---|---|
| [shared-key-ceremony.md](./shared-key-ceremony.md) | ChillDKG over NIP-17: the rounds, the approval gates, the chat transcript, participant ordering |
+1
View File
@@ -50,6 +50,7 @@ one more: Giza has to stay interoperable with Bennu.
|---|---|
| `mantra/chilldkg/host-key/v1`, `mantra/shared-key/tweak/v1` | They are inputs to a hash. Renaming them derives a different DKG host key and different tweaks from the same seed. A Bennu seed restored in Giza would then lose every group key it holds. |
| `MARMOT_ADMIN_GROUP_PATH` (`9420/0/0`) | Same reason. It is part of the derivation. |
| the twelve `bennu/…` tags: `bennu/group-wallet/account/v1`, `…/guardian/v1`, `…/guardian/child/v1`, `bennu/group-lightning/basepoints/v1`, the five `bennu/iceberg-dkg/…/v1`, `bennu/iceberg/pool/v1`, `bennu/member-wallet/id/v1` and `…/possession/v1` | **Missed when this plan was first written, and found while building Phase 4.** They are hash and HMAC inputs, exactly like `mantra/`: every group wallet address, guardian leaf, group Lightning basepoint, Iceberg ceremony and member wallet id is derived through one of them. They look like brand strings and are not. Phase 4 adds a note beside each so that a later sweep for "bennu" leaves them alone, and Phase 6's guard allowlists them. |
| nostr kinds, tag names, `d`-tag schemes | They are the protocol. A Giza member and a Bennu member have to read each other's events. |
| `wss://ephemeral.mantra.press` | It is a running relay, not a brand string. It is replaced when a Giza relay exists (see Phase 6). |
| `aux.db`, Phoenix's `*.preferences_pb` names | They are internal to each app's sandbox and nobody reads them. Renaming them would only add to every merge from Bennu. |
+1 -1
View File
@@ -132,7 +132,7 @@ has one share. Do what those helpers do, by hand, through `TweakCache` and
| more than one wallet per group is possible later | BIP44's `account'` |
| a member can check, alone, that no script path is hidden in the address | otherwise one member can propose an address with a back door and nobody can tell |
| addresses rotate, and change is told apart from payment | address reuse is a privacy leak for a treasury, and a signer has to see where the money goes |
| a watch-only tool can follow the wallet | a treasurer, an auditor or a member's Sparrow should not need Bennu to see the balance |
| a watch-only tool can follow the wallet | a treasurer, an auditor or a member's Sparrow should not need Giza to see the balance |
| everything is a pure function of what every member already holds | [Rederive rather than persist](./shared-key-derivation.md#what-it-produces) |
### The path
+1 -1
View File
@@ -157,7 +157,7 @@ testing/regtest/regtest.sh up
```
```bash
BENNU_REGTEST=1 ./gradlew :composeApp:jvmTest --tests '*GroupLightningRegtestJvmTest'
GIZA_REGTEST=1 ./gradlew :composeApp:jvmTest --tests '*GroupLightningRegtestJvmTest'
```
| step | what happens | result |
@@ -216,7 +216,7 @@ old proposer are impossible, which is the safe direction.
**About a day, plus the measurement.**
- The regtest run (`testing/regtest/regtest.sh up`, then
`BENNU_REGTEST=1 ./gradlew :composeApp:jvmTest --tests '*GroupLightningRegtestJvmTest'`) re-runs
`GIZA_REGTEST=1 ./gradlew :composeApp:jvmTest --tests '*GroupLightningRegtestJvmTest'`) re-runs
end to end; its force-close step now exercises the deferred revocation against a real eclair.
- The app's JVM suite and the fork's suite pass.
- **Measure how long ACINQ's LSP waits for `revoke_and_ack`** before this ships to a real group:
+65
View File
@@ -0,0 +1,65 @@
#!/usr/bin/env bash
#
# Where the name Bennu may still appear in Giza: docs/giza-rebrand.md, Phase 6.
#
# docs/scripts/brand-audit.sh lists the lines that break the rule
# docs/scripts/brand-audit.sh --check and exits 1 if there are any
#
# The rule, in the parts that build or ship (composeApp, iosApp, testing and the gradle
# scripts): Bennu may be named in a comment, and in a `bennu/` derivation tag,
# and nowhere else. The tags are hash inputs Giza shares with Bennu, so they stay spelled
# as they are (giza-rebrand.md, "What does not carry the name"). A comment can explain the
# fork. Anything else -- a string a person reads, a client tag, an identifier, a package --
# is a leftover.
#
# Prose (README.md, CLAUDE.md, docs/ and the Markdown under testing/) is not checked: it
# explains the fork, and docs/ records decisions taken while the app was Bennu.
#
# Why it exists: a merge from Bennu (Phase 9) brings Bennu's new strings with it, and
# docs/scripts/giza-rename.sh renames code, not words. This is what fails the build when
# one of them would otherwise ship.
#
# Needs only bash and git, like m3-audit.sh, so the CI budgets job can run it.
set -uo pipefail
cd "$(dirname "${BASH_SOURCE[0]}")/../.." || exit 1
CHECK=0
[[ "${1:-}" == "--check" ]] && CHECK=1
violations=$(
git grep -niI 'bennu' -- \
composeApp iosApp testing settings.gradle.kts build.gradle.kts \
| awk '
{
# path:line:text -- the text may itself contain colons.
path = $0; sub(/:.*/, "", path)
text = $0; sub(/^[^:]*:[^:]*:/, "", text)
code = text; sub(/^[ \t]+/, "", code)
}
# A derivation tag: the one place the name is protocol.
text ~ /"bennu\// { next }
# Comments in Kotlin and Gradle scripts: //, /* and KDoc continuation lines.
path ~ /\.(kt|kts)$/ && (code ~ /^\/\// || code ~ /^\/\*/ || code ~ /^\*/) { next }
# Comments in YAML, shell and HOCON (the regtest stack).
path ~ /\.(yml|yaml|sh|conf)$/ && code ~ /^#/ { next }
# Markdown under testing/ -- the regtest README -- is prose, like docs/.
path ~ /\.md$/ { next }
{ print }
'
)
count=0
[[ -n "$violations" ]] && count=$(printf '%s\n' "$violations" | wc -l)
echo "Bennu outside comments and derivation tags: $count"
if (( count > 0 )); then
printf '%s\n' "$violations" | sed 's/^/ /'
fi
if (( CHECK && count > 0 )); then
echo "Name it Giza, or, if it is protocol shared with Bennu, say so in a comment." >&2
exit 1
fi
exit 0