Clarify error message in the case of pre TLS clients
Move state logic, fix erroneous log messages, remove redundent code