Automated test coverage for the Confidential Transfer feature (XLS-0096), grouped by the transactor, invariant, or cross-feature interaction each test exercises with 561 tests.
| Category | Test Count |
|---|---|
| Transactor — Convert | 72 |
| Transactor — Send | 69 |
| Transactor — MergeInbox | 31 |
| Transactor — ConvertBack | 30 |
| Transactor — Clawback | 30 |
| Issuance Lifecycle | 41 |
| Crypto | 44 |
| Hardening | 36 |
| Adversarial / Security | 45 |
| Invariants | 41 |
| Batch / Composition | 18 |
| Delegation | 12 |
| Cross-Feature | 63 |
| Bug Hunt | 29 |
| Total | 561 |
Transactor — Convert
- Test Confidential MPT convert basic
- Test Confidential MPT convert without tfMPTCanPrivacy flag
- Test Confidential MPT convert partial amount
- Test Confidential MPT convert multiple times with available balance
- Test Confidential MPT convert multiple times without ignoring holder elgamal public key
- Test Confidential MPT convert multiple times with insufficient balance
- Test Confidential MPT convert account is individual account locked
- Test Confidential MPT convert account is globally locked
- Test Confidential MPT convert with auditor enabled and auditor encrypted amount
- Test Confidential MPT convert with auditor same as issuer
- Test Confidential MPT convert with auditor enabled separately after issuer
- Test Confidential MPT convert with different issuer elgamal public key
- Test Confidential MPT convert holder and issuer encrypted amounts different
- Test Confidential MPT convert with auditor enabled but no auditor encrypted amount
- Test Confidential MPT convert with auditor not enabled but with auditor encrypted amount
- Test Confidential MPT convert with auditor enabled and using issuer for auditor encrypted amount
- Test Confidential MPT convert with auditor enabled and using holder for auditor encrypted amount
- Test Confidential MPT convert with no issuer elgamal public key
- Test Confidential MPT convert set privacy flag and issuer elgamal public key separately after MPT Issuance create
- Test Confidential MPT convert set privacy flag and issuer elgamal public key in same transaction after MPT Issuance create
- Test Confidential MPT convert existing account set privacy flag when oa greater than zero
- Test Confidential MPT convert new account after set privacy flag when oa greater than zero
- Test Confidential MPT convert set privacy flag when oa equals zero
- Test Confidential MPT convert set privacy flag by holder when oa greater than zero
- Test Confidential MPT convert set privacy flag by holder when oa equals zero
- Test Confidential MPT convert with cannot mutate privacy flag
- Test Confidential MPT convert with cannot mutate privacy flag and set privacy flag
- Test Confidential MPT convert with cannot mutate privacy flag and set privacy flag again
- Test Confidential MPT convert holder without elgamal public key
- Test Confidential MPT convert non existent account
- Test Confidential MPT convert account with no MPT balance
- Test Confidential MPT convert account with no MPT object
- Test Confidential MPT convert with MPT lock flag set
- Test Confidential MPT convert with can lock flag but not locked
- Test Confidential MPT convert without tfMPTCanTransfer flag
- Test Confidential MPT convert with clawback flag
- Test Confidential MPT convert from issuer account
- Test Confidential MPT convert from account who is another issuer
- Test Confidential MPT convert zero amount account as issuer with balance
- Test Confidential MPT convert zero amount account as issuer with no balance
- Test Confidential MPT convert account as third party without MPT object
- Test Confidential MPT convert MPT amount more than holder balance
- Test Confidential MPT convert MPT amount in fraction
- Test Confidential MPT convert MPT amount zero
- Test Confidential MPT convert MPT amount negative
- Test Confidential MPT convert negative MPT amount
- Test Confidential MPT convert no holder encrypted amount
- Test Confidential MPT convert no issuer encrypted amount
- Test Confidential MPT convert no auditor encrypted amount when auditor set
- Test Confidential MPT convert with auditor encrypted amount but auditor not set
- Test Confidential MPT convert with receiver field
- Test Confidential MPT convert with destination field
- Test Confidential MPT convert with invalid MPT Issuance id
- Test Confidential MPT convert MPT amount missing
- Test Confidential MPT convert maximum amount
- Test Confidential MPT convert auditor key mismatch
- Test Confidential MPT convert invalid ciphertext format
- Test Confidential MPT convert invalid zkp
- Test Confidential MPT convert multiple accounts
- Test Confidential MPT convert change auditor
- Test Confidential MPT convert and delete holder
- Test Confidential MPT convert with multisign with disabling master key
- Test Confidential MPT convert with multisign without disabling master key
- Test Confidential MPT convert minimum amount
- Test Confidential MPT convert invalid elgamal key format
- Test Confidential MPT convert elgamal key wrong length
- Test Confidential MPT convert auditor encrypted amount encrypts wrong value
- Test Confidential MPT convert issuer key rotation impact when coa is non zero
- Test Confidential MPT convert issuer key rotation impact when coa is zero
- Test Confidential MPT convert identity point elgamal key
- Test Confidential MPT convert blinding factor wrong length
- Test Confidential MPT convert zero amount on existing confidential balance
Transactor — Send
- Test Confidential MPT send to destination account basic
- Test Confidential MPT send partial amount
- Test Confidential MPT send multiple times
- Test Confidential MPT send source destination swap
- Test Confidential MPT send with one drop in inbox
- Test Confidential MPT send without source account merging inbox
- Test Confidential MPT send without bob having mptoken
- Test Confidential MPT send with bob having zero mpt
- Test Confidential MPT send with bob having nonzero MPT but no coa
- Test Confidential MPT send to destination account having zero confidential balance
- Test Confidential MPT send zero amount to bob
- Test Confidential MPT send source confidential balance is zero after convert
- Test Confidential MPT send to self
- Test Confidential MPT send source does not exist
- Test Confidential MPT send source does not have mptoken
- Test Confidential MPT send source is locked
- Test Confidential MPT send destination is nonexistent account
- Test Confidential MPT send destination is locked
- Test Confidential MPT send with globally locked
- Test Confidential MPT send more than available coa
- Test Confidential MPT send invalid MPT Issuance id
- Test Confidential MPT send issuer sends to holder
- Test Confidential MPT send holder sends to issuer
- Test Confidential MPT send sender encrypted amount missing
- Test Confidential MPT send sender encrypted amount invalid
- Test Confidential MPT send destination encrypted amount missing
- Test Confidential MPT send destination encrypted amount invalid
- Test Confidential MPT send issuer encrypted amount missing
- Test Confidential MPT send with auditor basic success
- Test Confidential MPT send with auditor missing auditor encrypted amount
- Test Confidential MPT send with auditor invalid auditor encrypted amount
- Test Confidential MPT send without auditor but with auditor encrypted amount
- Test Confidential MPT send without auditor unexpected auditor amount
- Test Confidential MPT send with auditor verify decryption
- Test Confidential MPT send with auditor multiple sends
- Test Confidential MPT send from multiple accounts
- Test Confidential MPT send with zkproof missing
- Test Confidential MPT send with invalid zkproof value
- Test Confidential MPT send with amount commitment missing
- Test Confidential MPT send with invalid amount commitment value
- Test Confidential MPT send with balance commitment missing
- Test Confidential MPT send with invalid balance commitment value
- Test Confidential MPT send multiple times in sequence
- Test Confidential MPT send version increment
- Test Confidential MPT send incorrect version
- Test Confidential MPT send stale proof rejection
- Test Confidential MPT send mismatched ciphertexts
- Test Confidential MPT send and MPT Issuance destroy source account having zero confidential balance
- Test Confidential MPT send and delete mptoken on destination account before merging inbox
- Test Confidential MPT send second account as sender
- Test Confidential MPT send to different accounts with same version
- Test Confidential MPT send first merge after convert merge convert
- Test Confidential MPT send with multisign without disabling master key
- Test Confidential MPT send with multisign with disabling master key
- Test Confidential MPT send with multisign insufficient signatures
- Test Confidential MPT send with regular key master enabled
- Test Confidential MPT send with regular key disabled master
- Test Confidential MPT send fractional amount
- Test Confidential MPT send negative amount
- Test Confidential MPT send and public payment to same destination
- Test Confidential MPT send and public payment to different destinations
- Test Confidential MPT send without merge
- Test Confidential MPT send with require auth and destination unauthorized
- Test Confidential MPT send to destination with deposit auth
- Test Confidential MPT send to destination with deposit auth and preauth
- Test Confidential MPT send to destination requiring credential without providing
- Test Confidential MPT send with nonexistent credential
- Test Confidential MPT send with expired credential
- Test Confidential MPT send without tfMPTCanTransfer flag
Transactor — MergeInbox
- Test Confidential MPT merge inbox basic
- Test Confidential MPT merge inbox after partial convert
- Test Confidential MPT merge inbox account does not exist
- Test Confidential MPT merge inbox account does not have mptoken
- Test Confidential MPT merge inbox with no confidential balance
- Test Confidential MPT merge inbox with various token balance
- Test Confidential MPT merge inbox account is issuer
- Test Confidential MPT merge inbox convert twice then merge
- Test Confidential MPT merge inbox account is individual account locked
- Test Confidential MPT merge inbox account is globally locked
- Test Confidential MPT merge inbox invalid MPT Issuance id
- Test Confidential MPT merge inbox missing MPT Issuance id
- Test Confidential MPT merge inbox by third party
- Test Confidential MPT merge inbox empty
- Test Confidential MPT merge inbox conver and merge multiple times
- Test Confidential MPT merge inbox enczero determinism
- Test Confidential MPT merge inbox enczero validation
- Test Confidential MPT merge inbox and destroy mptoken without merge inbox
- Test Confidential MPT merge inbox and destroy mptoken after merge inbox
- Test Confidential MPT merge inbox with maximum value
- Test Confidential MPT merge inbox rapid state changes
- Test Confidential MPT merge inbox with mixed public confidential balance
- Test Confidential MPT merge inbox at minimum xrp reserve
- Test Confidential MPT merge inbox with require auth flag
- Test Confidential MPT merge inbox idempotency empty inbox
- Test Confidential MPT merge inbox determinism across accounts
- Test Confidential MPT merge inbox balance conservation
- Test Confidential MPT merge inbox decrypt verification
- Test Confidential MPT merge inbox with multisign with disabled master key
- Test Confidential MPT merge inbox version increments by one
- Test Confidential MPT merge inbox cb in amount field mismatch adversarial
Transactor — ConvertBack
- Test Confidential MPT convert back entire confidential balance
- Test Confidential MPT convert back partial confidential balance
- Test Confidential MPT convert back without merging inbox
- Test Confidential MPT convert back with balance in inbox and spending
- Test Confidential MPT convert back with balance only in inbox
- Test Confidential MPT convert back with no balance in both inbox and spending
- Test Confidential MPT convert back account does not exist
- Test Confidential MPT convert back account does not have mptoken
- Test Confidential MPT convert back account is issuer
- Test Confidential MPT convert back invalid mptokenissuanceid
- Test Confidential MPT convert back mptamount greater than spending balance
- Test Confidential MPT convert back mptamount invalid values
- Test Confidential MPT convert back zero amount
- Test Confidential MPT convert back mptamount missing
- Test Confidential MPT convert back holder encrypted amount missing
- Test Confidential MPT convert back holder encrypted amount invalid
- Test Confidential MPT convert back issuer encrypted amount missing
- Test Confidential MPT convert back issuer encrypted amount invalid
- Test Confidential MPT convert back blinding factor missing
- Test Confidential MPT convert back blinding factor invalid
- Test Confidential MPT convert back zkproof missing
- Test Confidential MPT convert back zkproof invalid
- Test Confidential MPT convert back balance commitment missing
- Test Confidential MPT convert back balance commitment invalid
- Test Confidential MPT convert back with auditor encrypted amount no auditor set
- Test Confidential MPT convert back no auditor encrypted amount with auditor set
- Test Confidential MPT convert back with auditor encrypted amount and auditor set
- Test Confidential MPT convert back account locked
- Test Confidential MPT convert back and destroy mptoken and delete accounts
- Test Confidential MPT convert back encrypted balance delta equals public balance delta
Transactor — Clawback
- Test Confidential MPT clawback with tfMPTCanClawback set
- Test Confidential MPT clawback after partial convert
- Test Confidential MPT clawback public mpt
- Test Confidential MPT clawback without tfMPTCanClawback flag
- Test Confidential MPT clawback non issuer
- Test Confidential MPT clawback holder missing
- Test Confidential MPT clawback holder nonexistent
- Test Confidential MPT clawback third party holder
- Test Confidential MPT clawback MPT amount zero
- Test Confidential MPT clawback from holder with zero confidential balance
- Test Confidential MPT clawback MPT amount exceeds balance
- Test Confidential MPT clawback MPT amount less than balance
- Test Confidential MPT clawback zkproof missing
- Test Confidential MPT clawback zkproof invalid
- Test Confidential MPT clawback MPT Issuance id missing
- Test Confidential MPT clawback MPT Issuance id invalid
- Test Confidential MPT clawback without privacy flag
- Test Confidential MPT clawback without issuer encryption key
- Test Confidential MPT clawback multiple holders
- Test Confidential MPT clawback holder equals issuer
- Test Confidential MPT clawback with inbox and spending
- Test Confidential MPT clawback from source after send
- Test Confidential MPT clawback from destination after send
- Test Confidential MPT clawback public balance with regular clawback while confidential setup exists
- Test Confidential MPT clawback dual public and confidential workflow
- Test Confidential MPT clawback and delete account
- Test Confidential MPT clawback with auditor
- Test Confidential MPT clawback holder account individually locked before clawback
- Test Confidential MPT clawback tokens globally locked before clawback
- Test Confidential MPT clawback invariant coa decreases
Issuance Lifecycle
- Test Issuance set set confidential when coa gt zero is tecNO PERMISSION
- Test Issuance set clear confidential bit is unrecognized returns temINVALID FLAG
- Test Issuance set set confidential when cannot mutate is tecNO PERMISSION
- Test Issuance set replace issuer key is tecNO PERMISSION
- Test Issuance set replace auditor key surfaces as temMALFORMED
- Test Issuance set keys when confidential not enabled is tecNO PERMISSION
- Test Issuance set keys with enable in same tx succeeds
- Test Issuance set keys with unrecognized clear bit is temINVALID FLAG
- Test Issuance set re register issuer key after coa gt zero is tecNO PERMISSION
- Test Issuance set set confidential via mutable flag sets lsf flag
- Test Issuance set confidential mutate with holder field is temMALFORMED
- Test Issuance set keys with holder field is temMALFORMED
- Test Issuance set confidential with nonzero transfer fee is tecNO PERMISSION
- Test Issuance set enable privacy and nonzero transfer fee same tx temBAD TRANSFER FEE
- Test MPT Issuance create privacy flag without issuer key
- Test MPT Issuance create issuer key without privacy flag
- Test MPT Issuance create auditor key without privacy flag
- Test MPT Issuance create invalid issuer elgamal key
- Test MPT Issuance create invalid auditor elgamal key
- Test MPT Issuance create coa initialized to zero
- Test MPT Issuance set remove auditor key with active supply
- Test MPT Issuance set non issuer privacy settings
- Test MPT Issuance create privacy flag with nonzero transfer fee
- Test MPT Issuance set auditor key without issuer key
- Test MPT Issuance destroy with nonzero confidential outstanding amount
- Test Privacy enabled at creation cannot be disabled by any clear bit
- Test Privacy enabled via mutable flag post creation then clear attempt returns temINVALID FLAG
- Test Privacy frozen off via tfMPTCannotMutatePrivacy blocks all later enables
- Test Re enable privacy on already enabled Issuance is idempotent
- Test All six capability flags one way under confidential issuance
- Test Enabling privacy post creation via mutableflags enables all confidential transactors
- Test Authorize lifecycle failed unauthorize does not decrement coa
- Test Authorize lifecycle unauthorize after full round trip succeeds
- Test Authorize lifecycle unauthorize when other holder has cb succeeds
- Test Authorize lifecycle reauthorize after unauthorize yields fresh mptoken
- Test Authorize lifecycle issuer unauthorize blocks subsequent sends
- Test Authorize lifecycle authorize destroyed Issuance returns object not found
- Test Issuer can create confidential MPT with canclawback without account flag
- Test Issuer can confidential clawback without account flag
- Test Setting asfAllowTrustLineClawback after MPT Issuance returns tecOWNERS
- Test Issuance without tfMPTCanClawback rejects confidential clawback even with account flag
Crypto
- Test Crypto wrapper generate keypair returns correctly sized hex
- Test Crypto wrapper generate keypair is non deterministic
- Test Crypto wrapper generate blinding factor is correctly sized and nondeterministic
- Test Crypto wrapper encrypt decrypt round trip
- Test Crypto wrapper decrypt with wrong privkey does not silently succeed
- Test Crypto wrapper decrypt amount outside range returns rc minus 1
- Test Crypto wrapper decrypt at exact range bounds inclusive
- Test Crypto wrapper elgamal round trip is homomorphic consistent
- Test Crypto wrapper same plaintext distinct blinding yields distinct ciphertexts
- Test Crypto wrapper encrypt with explicit blinding factor is deterministic
- Test Crypto wrapper pedersen commitment is deterministic in inputs
- Test Crypto wrapper pedersen commitment differs on different amount
- Test Crypto wrapper encrypt with wrong sized pubkey raises valueerror
- Test Crypto wrapper decrypt with wrong sized privkey raises valueerror
- Test Crypto wrapper encrypt with wrong sized blinding factor raises valueerror
- Test Crypto wrapper pedersen commitment with wrong sized bf raises valueerror
- Test Default range decrypts small amount
- Test Narrow range decrypts value within range
- Test Below range returns failure
- Test Above range returns failure
- Test Boundary low and high both decrypt
- Test Inverted range returns failure
- Test Zero excluded when range low gt zero
- Test Auditor decrypts real ciphertext with explicit range end to end
- Test Auditor decrypts initial convert balance to actual amount
- Test Auditor view decreases correctly after sender sends
- Test Auditor view increases correctly after receiver merges
- Test Auditor aggregate view equals Issuance confidential outstanding
- Test Auditor view unchanged across repeated rerandomization sends
- Test Auditor view zeros after full convert back
- Test Rerand destination inbox differs from tx ciphertext
- Test Rerand destination issuer mirror differs from tx ciphertext
- Test Rerand destination auditor mirror behavior
- Test Rerand sender spending balance is not rerandomized
- Test Rerand sender issuer mirror is not rerandomized
- Test Rerand multiple sends end to end decryption
- Test Rerand two consecutive sends produce different inbox deltas
- Test Rerand destination inbox changes under zero value send
- Test Rerand version counter increments once per send
- Test Rerand destination inbox and issuer mirror stay in lockstep per send
- Test Rerand send to self is rejected at preflight and does not mutate state
- Test Rerand two different senders to same destination compose correctly
- Test Rerand does not break issuer clawback path after send
- Test Rerand auditor mirror differs between two identical sends
Hardening
- Test Send to destination requiring dest tag fails
- Test Send to destination requiring dest tag with tag succeeds
- Test Send with dest tag and auditor succeeds
- Test Send when destination authorized but never converted fails
- Test Send when sender authorized but never converted fails
- Test Send receiver confidential version unchanged
- Test Convert zero amount from individually frozen account fails
- Test Convert zero amount from globally frozen Issuance fails
- Test Convert zero amount from unauthorized account fails
- Test Holder unauthorize with nonzero confidential balance fails
- Test Issuance set rotate existing issuer encryption key fails
- Test Issuance set add auditor after holders have confidential balance fails
- Test Create with privacy locked off then enable attempt fails
- Test Create with invalid mutable flag bit fails
- Test Midflight auditor cannot be retrofitted after issuer key already set
- Test Midflight set require auth after holders have cb freezes unallowlisted
- Test Midflight change domain id strands holder not in new domain
- Test Midflight per holder lock blocks holder unauthorize
- Test Crash send all zero zkproof
- Test Crash send all ones zkproof
- Test Crash send random garbage zkproof
- Test Crash send bit flipped zkproof
- Test Crash send zero amount commitment
- Test Crash send zero balance commitment
- Test Crash send zero sender encrypted amount
- Test Crash send swapped sender dest ciphertexts
- Test Crash convert all zero zkproof
- Test Crash convert back all zero zkproof
- Test Crash clawback all zero zkproof
- Test Crash send rapid fire garbage proofs no corruption
- Test Acctdel holder with active cb s blocks account delete
- Test Acctdel holder with unmerged inbox blocks account delete
- Test Acctdel issuer with active confidential outstanding blocks
- Test Acctdel orphan mptoken after Issuance destroy full cleanup chain
- Test Acctdel issuer after destroy with outstanding orphan holders succeeds
- Test Acctdel stuck holder after issuer unauthorize with cb present
Adversarial / Security
- Test Adversarial duplicate send txn
- Test Adversarial stale send proof after merge
- Test Adversarial reuse convert proof after state change
- Test Adversarial reuse convert back proof after state change
- Test Adversarial two sends exceed balance same ledger
- Test Adversarial send and convert back same balance same ledger
- Test Adversarial send vs clawback race same ledger
- Test Adversarial valid ec point wrong value
- Test Adversarial send amount commitment aliased to balance commitment
- Test Adversarial swap holder and issuer encrypted amounts
- Test Adversarial zero byte zkproof
- Test Adversarial proof for different statement
- Test Adversarial point on wrong curve
- Test Adversarial identity element as ciphertext
- Test Adversarial all zero blinding factor
- Test Adversarial range proof negative modular
- Test Adversarial nonce reuse across sends
- Test Adversarial wrong holder key in send
- Test Adversarial holder amount encrypted under issuer key
- Test Adversarial issuer amount encrypted under holder key
- Test Adversarial valid proof wrong account signature
- Test Adversarial key hijacking first convert
- Test Adversarial auditor amount wrong key
- Test Adversarial auditor amount different value
- Test Adversarial stale auditor key after rotation
- Test Adversarial range proof near uint64 overflow
- Test Adversarial cb in amount tampered
- Test Adversarial convert back tampered amount exceeds proof
- Test Adversarial send from inbox without merge
- Test Adversarial convert then immediate convert back same ledger
- Test Adversarial clawback from destroyed mptoken
- Test Adversarial clawback after holder converts back to zero
- Test Adversarial send with extra unknown fields
- Test Adversarial send all required fields missing
- Test Adversarial holder encrypted amount wrong byte length
- Test Adversarial issuer encrypted amount truncated
- Test Adversarial zkproof truncated
- Test Adversarial zkproof padded with extra bytes
- Test Adversarial confidential state persists across operations
- Test Adversarial two sends canonical order
- Test Adversarial replay with new sequence
- Test Adversarial cross type zkp replay
- Test Adversarial non issuer clawback valid zkp
- Test Adversarial third party merge inbox valid zkp
- Test Adversarial enable privacy on existing transfer fee Issuance reverse mutex
Invariants
- Test Inv send increments version when spending changes
- Test Inv convert creates consistent encrypted fields
- Test Inv send preserves encrypted field coexistence
- Test Inv convert token conservation holder and issuer side
- Test Inv send does not modify public mptamount at either end
- Test Inv send does not modify Issuance outstandingamount
- Test Inv clawback decreases coa and oa by identical amount
- Test Clawback under global lock no invariant
- Test Convert back under global lock returns teclocked
- Test Inv coa never exceeds oa through chain
- Test Inv send with tampered amount commitment rejected leaves coa unchanged
- Test Inv full clawback zeros holder cb and removes their coa contribution
- Test Inv full convert back chain leaves no orphan confidential state
- Test Convert with zero amount asymmetric behavior probe
- Test Convert back with zero amount returns temBAD AMOUNT
- Test Clawback with zero amount returns temBAD AMOUNT
- Test Send to self returns temMALFORMED
- Test Convert with amount exceeding public balance returns tecINSUFFICIENT FUNDS
- Test Two issuances independent version counters
- Test Two issuances independent coa accounting
- Test Two issuances independent auditor decryption
- Test Account delete blocked when alice has cb on one of two issuances
- Test Convert back on Issuance a does not affect balance on b
- Test Clawback on Issuance a does not affect balance on b
- Test scenario A send with auditor all zero zkproof rejected
- Test scenario A send with auditor random garbage zkproof rejected
- Test scenario A send with auditor bit flipped zkproof rejected
- Test scenario A send with auditor truncated zkproof rejected
- Test scenario B convert MPT amount as string above 2 pow 32 succeeds
- Test scenario B convert MPT amount as int above 2 pow 32 is rejected
- Test scenario B convert two holders summing above 2 pow 32 keeps coa correct
- Test scenario B Issuance create with maximum amount at 2 pow 63 minus 1
- Test scenario B Issuance create with maximum amount above 2 pow 63 is rejected
- Test scenario C convert back from inbox only no spending is rejected
- Test scenario C send from inbox only no spending is rejected
- Test scenario C merge inbox after inbox only state promotes value to spending
- Test scenario D send after issuer unauthorizes sender fails
- Test scenario E clawback after issuer unauthorizes holder succeeds
- Test scenario F three holder full chain conserves total value
- Test scenario F two Issuance concurrent chains remain isolated
- Test scenario H zero amount convert registers holder key and enables inbound send
Batch / Composition
- Test Batch confidential MPT two sends with stale proof allornothing
- Test Batch confidential MPT independent send with one failing
- Test Batch confidential MPT convert then merge inbox allornothing
- Test Batch delegated send missing permission allornothing
- Test Batch delegated send with delegate as outer needs no batch signer
- Test Batch delegated send with delegate as outer with batch signer
- Test Batch confidential MPT two chained sends same sender allornothing
- Test Batch confidential MPT send then convert back same sender allornothing
- Test Batch confidential MPT three chained sends same sender allornothing
- Test Batch confidential MPT chained send wrong predicted ciphertext fails
- Test Batch only one with two valid chained sends executes first only
- Test Batch only one first send to unconverted fails falls through to second
- Test Batch until failure first send commits then stale second fails
- Test Batch allornothing issuer lock then alice send rolls back both
- Test Batch independent three holders converts coa aggregate correct
- Test Batch allornothing inner revokes delegate then later inner uses it rolls back
- Test Batch two chained delegated sends from same delegator both commit
- Test Delegated send after delegator loses domain membership fails
Delegation
- Test Delegate confidential MPT send basic
- Test Delegate confidential MPT send missing permission
- Test Delegate confidential MPT convert
- Test Delegate confidential MPT merge inbox
- Test Delegate confidential MPT convert back
- Test Delegate confidential MPT clawback by issuer
- Test Delegate neg send perm only cannot convert back
- Test Delegate neg convert back perm only cannot send
- Test Delegate neg clawback with non issuer account rejected at preflight
- Test Delegate neg revoked permission blocks subsequent use
- Test Delegate neg self delegation rejected
- Test Delegate neg send with proof over delegate keys rejected
Cross-Feature
- Test Ticket based first convert succeeds when proof binds to ticket seq
- Test Ticket based send succeeds when proof binds to ticket seq
- Test Ticket based send with wrong seq in proof returns tecBAD PROOF
- Test Ticket based convert back succeeds when proof binds to ticket seq
- Test Ticket based send with nonzero sequence returns temSEQ AND TICKET
- Test Ticket based send with nonexistent ticket is rejected
- Test Ticket based send consumes ticket even on tecBAD PROOF
- Test Ticket based send with matching credential succeeds
- Test Escrow create with MPT locks only public balance
- Test Escrow finish credits destination public not CB
- Test Confidential send succeeds with active outgoing escrow
- Test Escrow create amount exceeding unlocked public returns tecINSUFFICIENT FUNDS
- Test Check create then cash on privacy MPT does not touch either side CB
- Test Convert amount capped by unlocked public not total owned
- Test Vault create with confidential enabled MPT succeeds
- Test Vault deposit preserves holder confidential state
- Test Vault deposit fails when holder has no public balance
- Test Vault withdraw preserves destination confidential state
- Test Vault pseudo mptoken has no confidential fields after deposit
- Test Vault confidential clawback independent of vault holdings
- Test Send at exactly 10x base fee succeeds
- Test Send at one drop below 10x base fee returns telINSUF FEE P
- Test First convert does not change holder owner count
- Test Issuance create then key register bumps issuer owner count by exactly 1
- Test Five confidential sends drain alice xrp by exactly 5x send fee
- Test Memo on confidential send does not affect proof
- Test Multi sig confidential send at exactly required fee succeeds
- Test Multi sig confidential send at one drop below required returns telINSUF FEE P
- Test Convert does not update sfOutstandingAmount
- Test Convert fee multiplier 10x bounds
- Test Merge inbox fee multiplier 10x bounds
- Test Convert back fee multiplier 10x bounds
- Test Clawback fee multiplier 10x bounds
- Test Send to deposit auth destination without preauth fails
- Test Send to deposit auth destination after direct preauth succeeds
- Test Send to deposit auth destination after unauth fails again
- Test Send to deposit auth destination with matching credential succeeds
- Test Send after credential deleted fails with nonexistent credential
- Test Send with third party credential id fails
- Test Send with unaccepted credential fails
- Test Send with duplicate credential ids fails
- Test Send with credential ids when destination has no deposit auth succeeds
- Test Credential based send with frozen destination fails with lock
- Test Failed credential based send does not credit destination inbox
- Test Credential based send credits all encrypted amounts when auditor present
- Test Issuance set domain id on Issuance without require auth fails
- Test Issuance set nonexistent domain id fails
- Test Confidential send in permissioned domain succeeds
- Test Pd payment to uncredentialed holder blocks funding
- Test Pd send when destination credential revoked blocks send
- Test Pd send when sender credential revoked blocks send
- Test Pd send after domain id added post convert succeeds for credentialed
- Test Pd clear domain id via zero sentinel revokes holder authorization
- Test Pd send with unaccepted destination credential blocks send
- Test Convert with reserve sponsor returns temINVALID FLAG
- Test Merge inbox with reserve sponsor returns temINVALID FLAG
- Test Send with reserve sponsor returns temINVALID FLAG
- Test Convert back with reserve sponsor returns temINVALID FLAG
- Test Clawback with reserve sponsor returns temINVALID FLAG
- Test Send with fee plus reserve flags returns temINVALID FLAG
- Test Send with zero sponsor flags returns temINVALID FLAG
- Test Send with sponsor equal account returns temMALFORMED
- Test Prefunded fee sponsorship for confidential send succeeds
Bug Hunt
- Test sum IssuerEncryptedBalance equals coa after multi hop
- Test IssuerEncryptedBalance zero after full clawback
- Test IssuerEncryptedBalance decrypts to expected after partial send
- Test stale version send rejected after intervening send
- Test convertback tampered MPT amount field rejected
- Test send balance commitment all zero bytes rejected
- Test send amount commitment all zero bytes rejected
- Test holder key immutable second convert with new key rejected
- Test convert with holder key equal to issuer key rejected
- Test first convert initializes spending to enczero and version zero
- Test second convert does not mutate spending or version
- Test issuer can re encrypt holder balance under new auditor key off chain
- Test enable auditor after convert send should not tefinternal
- Test mergeinbox on encrypted zero inbox version semantics
- Test stale send proof after clawback rejected
- Test zero amount convert registers key and accepts inbound
- Test send ciphertext under wrong key reaches bad proof not internal
- Test send swap ciphertexts from different amount proof rejected
- Test send to authorized but unconverted holder clean reject
- Test batch ct sends allornothing rolls back version on final failure
- Test freeze and send same ledger ordering is clean
- Test iss enc key reset after full clawback blocked pre reset
- Test convert with holder key not owned by account silent loss
- Test convert at coa boundary rejects cleanly not internal
- Test Add auditor after zero amount convert does not crash next convert
- Test Add auditor after convert convertback roundtrip blocked by gates
- Test Convert back amount within cb s plus cb in but exceeding cb s rejected
- Test Recipient merge between two sender sends does not break sender
- Test Clawback when holder has only unmerged inbox state reset correctly
Top comments (0)