示例#1
0
func verify(xml string, certManager C.xmlSecKeysMngrPtr) bool {
	cXml := C.CString(xml)

	defer C.free(unsafe.Pointer(cXml))
	verification := C.verify(certManager, cXml)
	if verification == 0 {
		return true
	} else {
		return false
	}
}
示例#2
0
文件: openssl.go 项目: liudch/gocoin
// Verify ECDSA signature
func EC_Verify(pkey, sign, hash []byte) int {
	return int(C.verify(unsafe.Pointer(&pkey[0]), C.uint(len(pkey)),
		unsafe.Pointer(&sign[0]), C.uint(len(sign)), unsafe.Pointer(&hash[0])))
}