TsgcWebSocketServer_HTTPAPIProperties › BindingOptions

BindingOptions Property

Fine-tunes how URL reservations and SSL certificates are registered with the http.sys driver at start-up.

Syntax

property BindingOptions: TsgcWSBindings_Options_HTTPAPI read FBindingOptions write SetBindingOptions;

Default Value

ConfigureSSLCertificate=True

Remarks

When ConfigureSSLCertificate is True (the default) the server automatically reserves the URL and attaches the SSL certificate identified by SSLOptions.Hash every time Active is set to True — this requires the process to run with administrative privileges. Set it to False if you have already registered the URL and bound the certificate externally (for example with netsh http add urlacl and netsh http add sslcert); the server will then start without requesting elevation. The property only affects the activation sequence — runtime behavior is identical either way.

Example


oServer := TsgcWebSocketServer_HTTPAPI.Create(nil);
oServer.Host := '127.0.0.1';
oServer.Port := 443;
oServer.SSL := true;
oServer.SSLOptions.Hash := 'CERTIFICATE_HASH';
// URL and certificate already registered with netsh: skip the admin-only step
oServer.BindingOptions.ConfigureSSLCertificate := false;
oServer.Active := true;

Back to Properties