| 193 | } |
| 194 | |
| 195 | void Session::handshakeComplete(bool success) |
| 196 | { |
| 197 | endHandshake(); |
| 198 | |
| 199 | if(success) { |
| 200 | // If requested, take a copy of the session ID for later re-use |
| 201 | if(options.sessionResume) { |
| 202 | if(!sessionId) { |
| 203 | sessionId = std::make_unique<SessionId>(); |
| 204 | } |
| 205 | *sessionId = connection->getSessionId(); |
| 206 | } |
| 207 | } else { |
| 208 | debug_w("SSL Handshake failed"); |
| 209 | } |
| 210 | |
| 211 | if(options.freeKeyCertAfterHandshake && connection) { |
| 212 | connection->freeCertificate(); |
| 213 | } |
| 214 | } |
| 215 | |
| 216 | size_t Session::printTo(Print& p) const |
| 217 | { |
no test coverage detected