Click or drag to resize

WebSocketServer Properties

The WebSocketServer type exposes the following members.

Properties
  NameDescription
Public propertyAllowObjectDecoding

Deprecated. Use get_var and put_var parameters instead.

If true, the PacketPeer will allow encoding and decoding of object via GetVar(Boolean) and PutVar(Object, Boolean).

Warning: Deserialized objects can contain code which gets executed. Do not use this option if the serialized object comes from untrusted sources to avoid potential security threats such as remote code execution.

(Inherited from PacketPeer.)
Public propertyBindIp

When not set to * will restrict incoming connections to the specified IP address. Setting bind_ip to 127.0.0.1 will cause the server to listen only to the local host.

Public propertyCaChain

When using SSL (see PrivateKey and SslCertificate), you can set this to a valid X509Certificate to be provided as additional CA chain information during the SSL handshake.

Public propertyDynamicObject
Gets a new DynamicGodotObject associated with this instance.
(Inherited from Object.)
Public propertyEncodeBufferMaxSize

Maximum buffer size allowed when encoding Variants. Raise this value to support heavier memory allocations.

The PutVar(Object, Boolean) method allocates memory on the stack, and the buffer used will grow automatically to the closest power of two to match the size of the Variant. If the Variant is bigger than encode_buffer_max_size, the method will error out with .

(Inherited from PacketPeer.)
Public propertyNativeInstance (Inherited from Object.)
Public propertyPrivateKey

When set to a valid CryptoKey (along with SslCertificate) will cause the server to require SSL instead of regular TCP (i.e. the wss:// protocol).

Public propertyRefuseNewConnections

If true, this NetworkedMultiplayerPeer refuses new connections.

(Inherited from NetworkedMultiplayerPeer.)
Public propertySslCertificate

When set to a valid X509Certificate (along with PrivateKey) will cause the server to require SSL instead of regular TCP (i.e. the wss:// protocol).

Public propertyTransferMode (Inherited from NetworkedMultiplayerPeer.)
Top
See Also