program lock_symmetric

// Neptune Symmetric Address Lock Script
//
// A Symmetric address uses a 5-field secret (Digest-sized).
// This provides 320 bits of entropy vs 64 bits for a Generation
// address. The pattern is otherwise identical: divine the preimage,
// hash it, assert the digest matches.
//
// Public input:  kernel MAST hash (5 fields = 1 Digest)
// Secret input:  lock preimage (5 fields via divine5), lock hash (5 fields via divine5)
fn main() {
    // The expected lock digest โ€” committed in the UTXO via program hash.
    let lock_hash: Digest = divine5()
    // Prover supplies the 5-field preimage.
    let (s0, s1, s2, s3, s4) = divine5()
    // Hash preimage and verify.
    let computed: Digest = hash(s0, s1, s2, s3, s4, 0, 0, 0, 0, 0)
    assert_digest(computed, lock_hash)
    // Bind proof to this transaction.
    let _kernel: Digest = pub_read5()
}

Local Graph