TsgcWebSocketProxyServer › Eigenschappen › Specifications
Schakelt de WebSocket-protocolspecificaties in of uit die de proxy zal accepteren van downstream-clients.
property Specifications: TsgcWSSpecifications read GetSpecifications write SetSpecifications;
RFC6455=True, Hixie76=True
Houd RFC6455 ingeschakeld — dit is de standaard, aanbevolen WebSocket-specificatie. Hixie76 is een verouderd concept dat alleen nuttig is voor het ondersteunen van verouderde browsers zoals Safari 4.2; schakel het uit tenzij u die compatibiliteit specifiek nodig heeft. De handshake wordt per downstreamverbinding onderhandeld; als de client een specificatie aanvraagt die is uitgeschakeld, mislukt de handshake en wordt de verbinding geweigerd voordat de proxy de upstreamkoppeling naar de server opent die is geconfigureerd in Proxy.
oProxy := TsgcWebSocketProxyServer.Create(nil);
oProxy.Specifications.RFC6455 := true;
oProxy.Specifications.Hixie76 := false;
oProxy.Proxy.Host := 'upstream.example.com';
oProxy.Proxy.Port := 8080;
oProxy.Active := true;