AI Initiative logoAI Initiative
Reading room / Manthan

Manthan Testnet Incident Response Runbook (T-338)

Manthan Testnet Incident Response Runbook (T-338). Covers Severity definitions; On-call contacts (AWS production fills in); Procedures; charter-refresh.

Deployment / operations method; execution not repeated
This is the retained source text, not a new validation of its claims. Numerical results and comparative claims require the accompanying source review before public reuse.

Read the connected case study or article →

Not explicitly stated in source · Date not established

Provenance, authorship and editorial notes

Manthan Testnet Incident Response Runbook (T-338)

Id

manthan-herald-protocol-services-testnet-incident-response-runbook

Project

Manthan

Source path

manthan/herald-protocol/services/testnet/incident-response/runbook.md

Source sha256

3b4b40193aea58684602778d8fb90a9f0a2dc3cfbc04ff154fe4f0370ee9a20d

Local copy sha256

3b4b40193aea58684602778d8fb90a9f0a2dc3cfbc04ff154fe4f0370ee9a20d

Repo head

3a94084024a3434cef331fecac91c2c3b43f0313

Date
Not recorded
Date basis

Original publication date not established; Git revision date retained separately.

Author

Not explicitly stated in source

Author basis

Unknown; Git committer not substituted for document author.

Last source commit

8b75d1b0157c20a0a463f0e31008ef9f73099beb

Last source commit date

2026-06-08T07:40:14Z

Document status

Deployment / operations method; execution not repeated

Summary

Manthan Testnet Incident Response Runbook (T-338). Covers Severity definitions; On-call contacts (AWS production fills in); Procedures; charter-refresh.

Topics
  • Operating the system
  • Severity definitions
  • On-call contacts (AWS production fills in)
  • Procedures
Theme

Operating the system

Priority

reference

Related ids

No entries recorded.

Evidence concerns
  • Recovered source text is preserved verbatim. Assertions, comparisons, commands and results belong to its original context; they were not re-executed or externally re-verified during this corpus review.
Word count

1479

Bytes

11020

Source relative

herald-protocol/services/testnet/incident-response/runbook.md

Remote mirror

manthan/herald-protocol/services/testnet/incident-response/runbook.md

Full text preserved

True

Manthan Testnet Incident Response Runbook (T-338)

Per Manthan T-338. Concrete operational procedures for the most common testnet incidents. AWS production deployment uses these procedures verbatim with the operator-specific contact list filled in at the top.

Severity definitions

SeverityDescriptionResponse
SEV-1Log integrity affected (key compromise, fork detected, Charter stale)Page on-call within 15 minutes; mitigation within 4 hours
SEV-2Availability >1h affected (peer collapse, verifier flooding)Page on-call within 1 hour; mitigation within 24 hours
SEV-3Operational disruption without integrity impactSlack alert; resolve within 5 business days

On-call contacts (AWS production fills in)


Procedures

charter-refresh

Trigger: alert ManthanCharterStaleSoon or ManthanCharterStale.

Symptom: Charter signed >11 months ago; verifiers will reject the Herald's attestations after 12 months.

Procedure:

1. Open the node's filled-in Charter at services/testnet/nodes/<node>/charter.md.
2. Review every section (§1-§9). Change anything that has drifted (witness identities, contact addresses, regulatory relationships, COI declarations).
3. Increment the Charter version in §1.
4. Restart the node — it re-reads the Charter, re-signs at startup, and serves the new signed Charter at /charter.
5. Verify: curl https://<node>/charter | jq .signed_at — should be the current Unix timestamp.
6. Verify: manthan_charter_age_seconds metric drops to <60 within 1 minute.
7. Notify auditors via the contact email in §9.

Time: ~30 minutes including review.


peer-collapse

Trigger: alert ManthanPeerCollapse (peer count <2 for >5min).

Symptom: Node has lost gossip connectivity to most peers.

Procedure:

1. Check the node's /healthz and /readyz endpoints — confirm the node itself is alive.
2. Try connecting from another machine to the node's wss:// MWP port. If the connection itself fails, the issue is network (security groups, ALB health checks).
3. List the current peer set: curl http://<node>/metrics | grep manthan_peer_count.
4. Try connecting outbound to each peer in the bootstrap seed list:
``bash
for peer_endpoint in $(jq -r '.seeds[].endpoint' deploy/bootstrap-seed-list.json); do
wscat -c "$peer_endpoint" -x "ping" || echo "FAILED: $peer_endpoint"
done
`
5. If specific peers are unreachable: contact their operator (per their Charter §9). Track in incident registry.
6. If all peers are unreachable: the network has partitioned. Restore by:
- Verifying DNS for
*.testnet.local (testnet) or the production domain
- Verifying TLS certificate validity (production: ACM cert renewal)
- Verifying VPC security groups allow
wss://` ingress on the MWP port

Time: 30-60 minutes for connectivity issues; longer if peer-side outage.


verifier-failures

Trigger: alert ManthanRepeatedVerifierFailures (quarantine rate >0.5/sec for 5min).

Symptom: Sustained envelope quarantine rate. Either an adversary is flooding bad signatures or a peer's library has a bug.

Procedure:

1. Sample the quarantined envelopes:
``bash
sqlite3 services/testnet/nodes/<node>/data/ledger.sqlite \
"SELECT id, from_sigil, ts, state_ts FROM envelopes WHERE state='quarantined' ORDER BY state_ts DESC LIMIT 100;"
`
2. Group by
from_sigil to find the offending peer.
3. If one peer is responsible:
- Eject the peer from the gossip ring (set its
manthan_peer_count for that sigil to 0 by closing the session).
- Notify the peer's operator via their Charter §9 contact.
- File an incident at
/incidents.
4. If multiple peers are responsible: investigate whether the local node has a bug (run
npm run typecheck` and unit tests).
5. If neither: it's a coordinated attack. Escalate to SEV-1; consider emergency Bestiary listing of the offending sigils.

Time: 1-4 hours.


rate-limit

Trigger: alert ManthanRateLimitSaturation (drop rate >1/sec sustained for 10min).

Symptom: Either legitimate traffic exceeds the rate cap or a peer is flooding.

Procedure:

1. Check manthan_envelopes_received_total rate. If it's high but legitimate: raise rateLimitEnvelopesPerMin in the GossipRuntime config.
2. If it's a flood: identify the source peer and follow the verifier-failures ejection procedure.
3. Document the resolution in /incidents.

Time: 15-30 minutes.


ledger-quarantine

Trigger: alert ManthanLedgerCorruption (any quarantined envelopes present).

Symptom: Some envelope landed in quarantined state.

Procedure:

1. Inspect the quarantined envelopes (see verifier-failures procedure step 1).
2. If the quarantine was correct (verification truly failed), document and close.
3. If the quarantine was a false positive (e.g., a peer's pubkey was rotated and the local resolver was stale), update the resolver and selectively un-quarantine via:
``bash
sqlite3 ledger.sqlite "UPDATE envelopes SET state='verified', state_ts=strftime('%s','now') WHERE id='<id>' AND state='quarantined';"
`
4. Restart the node so its
seenIds` rebuild reflects the corrected state.

Time: 30-60 minutes.


readiness

Trigger: alert ManthanReadinessFail (/readyz non-200 for >2min).

Symptom: Node is alive but not ready. Common causes:

Procedure:

1. Check curl http://<node>/readyz — response body identifies the failing check.
2. db: fail → ledger corruption. Restore from backup (see data-restore procedure below).
3. key: fail → operator key file missing or unreadable. Restore from key backup; mode 0600.
4. charter: fail → Charter file missing or expired. Run charter-refresh.

Time: 15-60 minutes.


liveness

Trigger: alert ManthanLivenessLost (/healthz non-200 for >1min).

Symptom: Process is dead or hung.

Procedure:

1. Check process status: systemctl status manthan-node (systemd) or ecs:DescribeTasks (AWS).
2. Inspect logs for crash reason:
- OOM → raise instance size (AWS) or set Node --max-old-space-size.
- Uncaught exception → file a bug; restart pod via systemd/ECS task replacement.
- Hung event loop → SIGKILL the process; investigate post-mortem.
3. If repeated: rollback to the previous deployment (see rollback procedure).

Time: 5-30 minutes for restart; longer for root-cause investigation.


rollback (T-338 explicit)

Trigger: new deployment introduces SEV-1/2 issues; need to revert.

Procedure:

1. Stop accepting new envelopes: scale down to 0 instances via aws ecs update-service --desired-count 0 (production) or kill the testnet process (dev).
2. Restore ledger snapshot:
- AWS production: ledger persistence is on EBS-backed EFS. Restore from the latest backup snapshot via aws ec2 describe-snapshots → aws ec2 restore-snapshot-from-recycle-bin.
- Localhost testnet: restore the SQLite file from the manual hourly backup (see data-backup procedure).
3. Redeploy the previous image version:
``bash
aws ecs update-service --cluster manthan-testnet \
--service genesis-alpha --task-definition manthan-node:<previous-revision>
`
4. Verify rollback complete:
/healthz returns 200, /readyz ok, ledger integrity check passes.
5. Document: create an incident report at
/incidents` with the rollback rationale.

Time: 15-60 minutes for AWS rollback.


key-compromise

Trigger: suspected operator-key compromise (alert from KMS access logs, observed forged signatures, or external notification).

Procedure:

1. Stop signing immediately: scale node to 0; revoke IAM access to the KMS key.
2. Issue herald_compromise envelope: sign with the recovery key declared in the LOTS §2.3.
3. Publish at compromise URL: <node>/compromise per LOTS §9.
4. Issue revoke_attestation envelopes for all attestations issued in the suspected compromise window.
5. Plan emergency molt: schedule a new Ed25519 keypair generation with the 24-hour cool-off rule per [EXT §1].
6. Notify peers and downstream verifiers via the contact list in Charter §9.
7. Forensic investigation: preserve logs, KMS audit trail, ledger state.

This is a SEV-1 incident. Time-to-contain: 4 hours. Time-to-recover: 1-7 days.


Data backup and restore

data-backup

Cadence:

AWS production:

data-restore

# Stop the node first
systemctl stop manthan-node-genesis-alpha   # or scale ECS to 0

# Restore from the latest hourly snapshot
cp /backup/genesis-alpha/$(ls -t /backup/genesis-alpha/ | head -1)/ledger.sqlite \
   services/testnet/nodes/genesis-alpha/data/ledger.sqlite

# Decrypt operator key from backup
openssl aes-256-cbc -d -in operator.key.json.enc \
  -out services/testnet/nodes/genesis-alpha/data/operator.key.json
chmod 600 services/testnet/nodes/genesis-alpha/data/operator.key.json

# Restart and verify
systemctl start manthan-node-genesis-alpha
curl local-service/readyz

After-action items (for every SEV-1/2 incident)

1. Post-mortem within 14 days, published at /incidents/<incident-id>.
2. Identify root cause + contributing factors.
3. Identify what monitoring or process failed (the alert that should have fired earlier).
4. File follow-up tickets to prevent recurrence.
5. Update this runbook if the procedure was unclear or wrong.


AWS production deployment checklist

Before this runbook is operational on AWS, verify:


— Manthan testnet runbook v1, 2026-05-06.

Continue exploring