func NewCertFromFile(filename string) (*Cert, error) {
	_, err := os.Stat(filename)
	if os.IsNotExist(err) {
		return nil, ErrCertNotFound
	}
	cFilename := C.CString(filename)
	defer C.free(unsafe.Pointer(cFilename))
	cert := C.zcert_load(cFilename)
	return &Cert{
		zcertT: cert,
	}, nil
}
NewCertFromFile Load loads a Cert from files
package goczmq
import "C"
import (
	"fmt"
	"os"
	"unsafe"
)
type Cert struct {
	zcertT *C.struct__zcert_t
}
func NewCert() *Cert {
	return &Cert{
		zcertT: C.zcert_new(),
	}
}
func NewCertFromKeys(public []byte, secret []byte) (*Cert, error) {
	if len(public) != 32 {
		return nil, fmt.Errorf("invalid public key")
	}
	if len(secret) != 32 {
		return nil, fmt.Errorf("invalid private key")
	}
	return &Cert{
		zcertT: C.zcert_new_from(
			(*C.byte)(unsafe.Pointer(&public[0])),
			(*C.byte)(unsafe.Pointer(&secret[0]))),
	}, nil
}