A finishedHash calculates the hash of a set of handshake messages suitable for including in a Finished message.
| 170 | // A finishedHash calculates the hash of a set of handshake messages suitable |
| 171 | // for including in a Finished message. |
| 172 | type finishedHash struct { |
| 173 | client hash.Hash |
| 174 | server hash.Hash |
| 175 | |
| 176 | // Prior to TLS 1.2, an additional MD5 hash is required. |
| 177 | clientMD5 hash.Hash |
| 178 | serverMD5 hash.Hash |
| 179 | |
| 180 | // In TLS 1.2, a full buffer is sadly required. |
| 181 | buffer []byte |
| 182 | |
| 183 | version uint16 |
| 184 | prf prfFunc |
| 185 | } |
| 186 | |
| 187 | func (h *finishedHash) Write(msg []byte) (n int, err error) { |
| 188 | h.client.Write(msg) |
no outgoing calls
no test coverage detected