mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
SimpleWebTransport: moved overrides down
This commit is contained in:
parent
1a915ccde7
commit
f10bc77195
@ -13,9 +13,6 @@ public class SimpleWebTransport : Transport, PortTransport
|
||||
public const string NormalScheme = "ws";
|
||||
public const string SecureScheme = "wss";
|
||||
|
||||
public override bool IsEncrypted => ClientConnected() && (clientUseWss || sslEnabled) || ServerActive() && sslEnabled;
|
||||
public override string EncryptionCipher => "TLS"; // not technically correct, but there's no good way to get the actual cipher. Especially in browser
|
||||
|
||||
[Tooltip("Protect against allocation attacks by keeping the max message size small. Otherwise an attacker might send multiple fake packets with 2GB headers, causing the server to run out of memory after allocating multiple large packets.")]
|
||||
public int maxMessageSize = 16 * 1024;
|
||||
|
||||
@ -147,6 +144,12 @@ public override void Shutdown()
|
||||
|
||||
string GetClientScheme() => (sslEnabled || clientUseWss) ? SecureScheme : NormalScheme;
|
||||
|
||||
public override bool IsEncrypted => ClientConnected() && (clientUseWss || sslEnabled) || ServerActive() && sslEnabled;
|
||||
|
||||
// Not technically correct, but there's no good way to get the actual cipher, especially in browser
|
||||
// When using reverse proxy, connection between proxy and server is not encrypted.
|
||||
public override string EncryptionCipher => "TLS";
|
||||
|
||||
public override bool ClientConnected()
|
||||
{
|
||||
// not null and not NotConnected (we want to return true if connecting or disconnecting)
|
||||
|
Loading…
Reference in New Issue
Block a user