This change fixes a bug with the KmipSession connection handling logic that would terminate the connection before actually receiving a termination from the client. The corresponding unit tests have been updated to reflect this fix.