MCPcopy Create free account
hub / github.com/PolyhedraZK/ExpanderCompilerCollection / VerifyCircuitFile

Function VerifyCircuitFile

ecgo/rust/wrapper/wrapper.go:235–245  ·  view source on GitHub ↗
(circuitFilename string, witness []byte, proof []byte, configId uint64)

Source from the content-addressed store, hash-verified

233}
234
235func VerifyCircuitFile(circuitFilename string, witness []byte, proof []byte, configId uint64) bool {
236 initCompilePtr()
237 bytesFn := []byte(circuitFilename)
238 cf := C.ByteArray{data: (*C.uint8_t)(C.CBytes(bytesFn)), length: C.uint64_t(len(bytesFn))}
239 defer C.free(unsafe.Pointer(cf.data))
240 wi := C.ByteArray{data: (*C.uint8_t)(C.CBytes(witness)), length: C.uint64_t(len(witness))}
241 defer C.free(unsafe.Pointer(wi.data))
242 pr := C.ByteArray{data: (*C.uint8_t)(C.CBytes(proof)), length: C.uint64_t(len(proof))}
243 defer C.free(unsafe.Pointer(pr.data))
244 return C.verify_circuit_file(verifyCircuitFilePtr, cf, wi, pr, C.uint64_t(configId)) != 0
245}

Callers 1

VerifyFileFunction · 0.92

Calls 1

initCompilePtrFunction · 0.85

Tested by

no test coverage detected