diff --git a/ssl/test/runner/handshake_server.go b/ssl/test/runner/handshake_server.go index f3fd08ff9..73eac703c 100644 --- a/ssl/test/runner/handshake_server.go +++ b/ssl/test/runner/handshake_server.go @@ -588,10 +588,6 @@ func (hs *serverHandshakeState) sendSessionTicket() error { if err != nil { return err } - m.ticket = make([]byte, 16105+62) - for i := range m.ticket { - m.ticket[i] = 'A' - } hs.finishedHash.Write(m.marshal()) c.writeRecord(recordTypeHandshake, m.marshal()) diff --git a/ssl/test/runner/ticket.go b/ssl/test/runner/ticket.go index 70e91cfc0..519543b7b 100644 --- a/ssl/test/runner/ticket.go +++ b/ssl/test/runner/ticket.go @@ -173,7 +173,7 @@ func (c *Conn) decryptTicket(encrypted []byte) (*sessionState, bool) { return nil, false } ciphertext := encrypted[aes.BlockSize : len(encrypted)-sha256.Size] - plaintext := ciphertext + plaintext := make([]byte, len(ciphertext)) cipher.NewCTR(block, iv).XORKeyStream(plaintext, ciphertext) state := new(sessionState)