diff --git a/cert/sign.go b/cert/sign.go index 3226b2dfd..a67fab0ef 100644 --- a/cert/sign.go +++ b/cert/sign.go @@ -78,7 +78,7 @@ func (t *TBSCertificate) Sign(signer Certificate, curve Curve, key []byte) (Cert // readyToSign checks all signing requirements that don't require us to cross-reference with a CA func (t *TBSCertificate) readyToSign() error { - if t.PublicKey == nil { + if len(t.PublicKey) == 0 { return fmt.Errorf("public key not set") }