TsgcWebSocketClientProperties › TLSOptions

TLSOptions Property

Configura certificados, versão de TLS, ALPN, IOHandler e outros detalhes de conexão segura usados quando o TLS está habilitado.

Sintaxe

property TLSOptions: TsgcWSTLS_Options read FTLSOptions write SetTLSOptions;

Valor Padrão

Observações

Acessível apenas quando TLS é True. As subpropriedades incluem RootCertFile, CertFile, KeyFile, Password, VerifyCertificate, VerifyDepth, Version (de tlsUndefined até tls1_3), ALPNProtocols e IOHandler (iohOpenSSL ou iohSChannel). As configurações específicas do OpenSSL ficam em OpenSSL_Options e as específicas do SChannel em SChannel_Options.

Exemplo


oClient := TsgcWebSocketClient.Create(nil);
oClient.URL := 'wss://www.esegece.com:2053';
oClient.TLSOptions.Version := tls1_2;
oClient.TLSOptions.VerifyCertificate := true;
oClient.TLSOptions.RootCertFile := 'cacert.pem';
oClient.Active := true;

Voltar para Propriedades