Photon Server API

Public Member Functions | Protected Member Functions | Properties | List of all members
Photon.Common.Authentication.AuthTokenFactory Class Reference

Public Member Functions

void Initialize (string secret, TimeSpan expirationtime)
 
virtual AuthenticationToken CreateAuthenticationToken (IAuthenticateRequest authRequest, AuthSettings authSettings, string userId, Dictionary< string, object > authCookie)
 
AuthenticationToken CreateAuthenticationToken (string userId, IAuthenticateRequest authRequest)
 Create a renewed Authentication Token on Master server - to be validated on GS More...
 
virtual string EncryptAuthenticationToken (AuthenticationToken token, bool renew)
 
virtual string CreateEncryptedAuthenticationToken (IAuthenticateRequest authRequest, AuthSettings authSettings, string userId)
 
virtual string CreateEncryptedAuthenticationToken (IAuthenticateRequest authRequest, AuthSettings authSettings, string userId, Dictionary< string, object > customParameter)
 
virtual bool DecryptAuthenticationToken (string authTokenEncrypted, out AuthenticationToken authToken)
 

Protected Member Functions

virtual void SetupToken (AuthenticationToken token)
 

Properties

ICryptoProvider CryptoProvider [get]
 
byte[] SharedKey [get]
 
TimeSpan ExpirationTime [get, set]
 

Member Function Documentation

◆ CreateAuthenticationToken() [1/2]

virtual AuthenticationToken Photon.Common.Authentication.AuthTokenFactory.CreateAuthenticationToken ( IAuthenticateRequest  authRequest,
AuthSettings  authSettings,
string  userId,
Dictionary< string, object >  authCookie 
)
inlinevirtual

◆ CreateAuthenticationToken() [2/2]

AuthenticationToken Photon.Common.Authentication.AuthTokenFactory.CreateAuthenticationToken ( string  userId,
IAuthenticateRequest  authRequest 
)
inline

Create a renewed Authentication Token on Master server - to be validated on GS

Parameters
userId
authRequest
Returns

◆ CreateEncryptedAuthenticationToken() [1/2]

virtual string Photon.Common.Authentication.AuthTokenFactory.CreateEncryptedAuthenticationToken ( IAuthenticateRequest  authRequest,
AuthSettings  authSettings,
string  userId 
)
inlinevirtual

◆ CreateEncryptedAuthenticationToken() [2/2]

virtual string Photon.Common.Authentication.AuthTokenFactory.CreateEncryptedAuthenticationToken ( IAuthenticateRequest  authRequest,
AuthSettings  authSettings,
string  userId,
Dictionary< string, object >  customParameter 
)
inlinevirtual

◆ DecryptAuthenticationToken()

virtual bool Photon.Common.Authentication.AuthTokenFactory.DecryptAuthenticationToken ( string  authTokenEncrypted,
out AuthenticationToken  authToken 
)
inlinevirtual

◆ EncryptAuthenticationToken()

virtual string Photon.Common.Authentication.AuthTokenFactory.EncryptAuthenticationToken ( AuthenticationToken  token,
bool  renew 
)
inlinevirtual

◆ Initialize()

void Photon.Common.Authentication.AuthTokenFactory.Initialize ( string  secret,
TimeSpan  expirationtime 
)
inline

◆ SetupToken()

virtual void Photon.Common.Authentication.AuthTokenFactory.SetupToken ( AuthenticationToken  token)
inlineprotectedvirtual

Property Documentation

◆ CryptoProvider

ICryptoProvider Photon.Common.Authentication.AuthTokenFactory.CryptoProvider
get

◆ ExpirationTime

TimeSpan Photon.Common.Authentication.AuthTokenFactory.ExpirationTime
getset

◆ SharedKey

byte [] Photon.Common.Authentication.AuthTokenFactory.SharedKey
get