Area
contracts/compliance/src/lib.rs (register_kyc, is_kyc_registered)
Problem
register_kyc (lib.rs:181-200) adds a KYC hash but there is no matching revoke_kyc. Once set, is_kyc_registered returns true forever, and verify_compliance/verify_disclosure will keep accepting proofs against that KYC hash indefinitely. The compliance contract's whole purpose is regulatory/AML gating — if a user is later sanctioned, a KYC record is found fraudulent, or a credential needs to expire, the admin currently has no on-chain way to invalidate it.
Proposed change
Add an admin-gated revoke_kyc(kyc_hash: BytesN<32>) that clears the storage entry (or flips a status enum instead of a bare bool, if a richer lifecycle is wanted later), and emit a KycRevokedEvent matching the existing KycRegisteredEvent pattern.
Acceptance Criteria
Open your PR against the dev branch, not main. All active development merges into dev.
Discuss this issue / coordinate work: join the DShield contributor Telegram group: https://t.me/+SiGHH24No9U2MDJk
Area
contracts/compliance/src/lib.rs (
register_kyc,is_kyc_registered)Problem
register_kyc(lib.rs:181-200) adds a KYC hash but there is no matchingrevoke_kyc. Once set,is_kyc_registeredreturnstrueforever, andverify_compliance/verify_disclosurewill keep accepting proofs against that KYC hash indefinitely. The compliance contract's whole purpose is regulatory/AML gating — if a user is later sanctioned, a KYC record is found fraudulent, or a credential needs to expire, the admin currently has no on-chain way to invalidate it.Proposed change
Add an admin-gated
revoke_kyc(kyc_hash: BytesN<32>)that clears the storage entry (or flips a status enum instead of a bare bool, if a richer lifecycle is wanted later), and emit aKycRevokedEventmatching the existingKycRegisteredEventpattern.Acceptance Criteria
revoke_kycadded, admin-gated, tested (revoke then re-verify fails withKycNotRegistered)KycRevokedEventemittedjust test,pnpm test,cargo test, ornargo testas applicable) pass locally and in CIcargo testoutput showing a revoked KYC hash rejected) — required before this can be merged.Open your PR against the
devbranch, notmain. All active development merges intodev.Discuss this issue / coordinate work: join the DShield contributor Telegram group: https://t.me/+SiGHH24No9U2MDJk