[WIP] SSL session reuse

Should have tests.