nova-attestation-verifier
SP2KZ109PC2HRFH8T37ZD8VAQF2DK38RTXQSBK80TSource Code
;; nova-attestation-verifier.clar
;; Verify off-chain data
;; CLARITY VERSION: 2
(define-map attestations
(buff 32) ;; data-hash
bool ;; verified
)
(define-public (verify-data (data-hash (buff 32)) (signature (buff 65)))
(begin
;; Sig check omitted
(map-set attestations data-hash true)
(ok true)
)
)
(define-read-only (is-verified (data-hash (buff 32)))
(default-to false (map-get? attestations data-hash))
)
Functions (2)
| Function | Access | Args |
|---|---|---|
| verify-data | public | data-hash: (buff 32 |
| is-verified | read-only | data-hash: (buff 32 |