How to send plain text ScSslClient
I want to start using ScSslClient to connect to my ICS component SslWSocketServer. Connection happens successfully. Issue is when I send some data it shows as junk (unicode characters) at the Server Side. Kindly let me know if I am sending text wrongly.
- procedure TForm1.Button1Click(Sender: TObject);
- var
- wStr:String ;
- begin
- ScSSLClient1.Connect ;
- ScSSLClient1.IsSecure := True;
- wStr:='Test Data over the Socket' ;
- ScSSLClient1.WriteBuffer( wStr,length(wStr)) ;
- Application.ProcessMessages ;
- ScSSLClient1.Disconnect ;
- end;
- object ScSSLClient1: TScSSLClient
- HostName = 'localhost'
- Port = 1111
- SecurityOptions.AllowLoadCRLByHttp = False
- SecurityOptions.DisableCRLValidation = True
- SecurityOptions.TrustSelfSignedCertificate = True
- end