send common certificate sets in the client hello

This commit is contained in:
Marten Seemann
2016-12-03 21:01:31 +07:00
parent 44303fcd4b
commit 63f2faec85
6 changed files with 59 additions and 0 deletions

View File

@@ -11,6 +11,7 @@ import (
// CertManager manages the certificates sent by the server
type CertManager interface {
SetData([]byte) error
GetCommonCertificateHashes() []byte
GetLeafCert() []byte
GetLeafCertHash() (uint64, error)
VerifyServerProof(proof, chlo, serverConfigData []byte) bool
@@ -50,6 +51,10 @@ func (c *certManager) SetData(data []byte) error {
return nil
}
func (c *certManager) GetCommonCertificateHashes() []byte {
return getCommonCertificateHashes()
}
// GetLeafCert returns the leaf certificate of the certificate chain
// it returns nil if the certificate chain has not yet been set
func (c *certManager) GetLeafCert() []byte {