소스 검색

tris: implement Committer

tls13
Filippo Valsorda 8 년 전
committed by Peter Wu
부모
커밋
ea17b0c225
1개의 변경된 파일11개의 추가작업 그리고 0개의 파일을 삭제
  1. +11
    -0
      handshake_server.go

+ 11
- 0
handshake_server.go 파일 보기

@@ -16,6 +16,10 @@ import (
"io"
)

type Committer interface {
Commit() error
}

// serverHandshakeState contains details of a server handshake in progress.
// It's discarded once the handshake has completed.
type serverHandshakeState struct {
@@ -268,6 +272,13 @@ Curves:
hs.hello.scts = hs.cert.SignedCertificateTimestamps
}

if committer, ok := c.conn.(Committer); ok {
err = committer.Commit()
if err != nil {
return false, err
}
}

if priv, ok := hs.cert.PrivateKey.(crypto.Signer); ok {
switch priv.Public().(type) {
case *ecdsa.PublicKey:


불러오는 중...
취소
저장