Class AuthToken
- Namespace
- Coherence.Connection
- Assembly
- Coherence.Auth.dll
public static class AuthToken
- Inheritance
-
AuthToken
Fields
LocalDevelopmentSecret
This secret is used during local development only! There is no security threat with this value leaking anywhere.
public const string LocalDevelopmentSecret = "local-development"
Field Value
Methods
Custom(string, ConnectionType, string)
Creates a custom authentication token for a given user that can be used for authentication when connecting to a self-hosted replication server. Secret must match the secret passed to the replication server executable.
public static string Custom(string playUserId, ConnectionType connectionType, string secret)
Parameters
playUserIdstringconnectionTypeConnectionTypesecretstring
Returns
ForLocalDevelopment(ConnectionType)
Creates an authentication token with a random User ID that can be used for authentication when connecting to a local (development) replication server.
public static string ForLocalDevelopment(ConnectionType connectionType)
Parameters
connectionTypeConnectionType
Returns
Remarks
DO NOT USE IN PRODUCTION - AUTHENTICATION WILL FAIL
ForLocalDevelopment(string, ConnectionType)
Creates an authentication token for a given user that can be used for authentication when connecting to a local (development) replication server.
public static string ForLocalDevelopment(string playUserId, ConnectionType connectionType)
Parameters
playUserIdstringconnectionTypeConnectionType
Returns
Remarks
DO NOT USE IN PRODUCTION - AUTHENTICATION WILL FAIL