SSLR-264 Fix bugs detected by integration tests