API Documentation Integration MsecSdk
|
Abstract base class for Msec SDK client implementations. More...
Public Member Functions | |
virtual void | Init (IMsecSdkListener listener, MsecSdkConfig config) |
Initializes the Msec SDK client with a listener and configuration. More... | |
abstract DomainCertificateVerificationResult | VerifyDomainCertificate (string domain, int port) |
Verifies the certificate of a specified domain and port. More... | |
abstract string | GetOTPCode (double timestamp) |
Retrieves an OTP (One-Time Password) code based on a timestamp. More... | |
abstract void | RegisterCallbacks () |
Registers callbacks for the SDK. More... | |
Protected Member Functions | |
void | LogDebug (object message) |
Logs a debug message if debug mode is enabled. More... | |
void | LogError (object message) |
Logs an error message if debug mode is enabled. More... | |
Protected Attributes | |
IMsecSdkListener | listener |
The listener for receiving SDK callbacks. More... | |
MsecSdkConfig | config |
The configuration settings for the SDK. More... | |
Abstract base class for Msec SDK client implementations.
This class provides a foundation for platform-specific Msec SDK clients (e.g., Android, iOS). It implements the IMsecSdkClient interface and defines common functionality such as initialization, logging, and abstract methods to be overridden by derived classes.
|
pure virtual |
Retrieves an OTP (One-Time Password) code based on a timestamp.
Abstract method to be implemented by derived classes to generate a platform-specific OTP code.
timestamp | The timestamp used to generate the OTP code. |
Implements MsecUnitySdk.IMsecSdkClient.
Implemented in MsecUnitySdk.iOS.MsecSdkClient, MsecUnitySdk.DummyMsecSdkClient, and MsecUnitySdk.Android.MsecSdkClient.
|
inlinevirtual |
Initializes the Msec SDK client with a listener and configuration.
Stores the provided listener and config for use in derived classes. This method can be overridden to add platform-specific initialization logic.
listener | The listener to receive SDK callbacks. |
config | The configuration settings for the SDK. |
Implements MsecUnitySdk.IMsecSdkClient.
Reimplemented in MsecUnitySdk.iOS.MsecSdkClient, and MsecUnitySdk.Android.MsecSdkClient.
|
inlineprotected |
Logs a debug message if debug mode is enabled.
Checks the config's Debug flag and logs the message to the Unity console if true.
message | The message to log. |
|
inlineprotected |
Logs an error message if debug mode is enabled.
Checks the config's Debug flag and logs the error message to the Unity console if true.
message | The error message to log. |
|
pure virtual |
Registers callbacks for the SDK.
Abstract method to be implemented by derived classes to set up platform-specific callback mechanisms.
Implemented in MsecUnitySdk.iOS.MsecSdkClient, MsecUnitySdk.DummyMsecSdkClient, and MsecUnitySdk.Android.MsecSdkClient.
|
pure virtual |
Verifies the certificate of a specified domain and port.
Abstract method to be implemented by derived classes to perform platform-specific certificate verification.
domain | The domain name to verify (e.g., "google.com"). |
port | The port number to check (e.g., 443 for HTTPS). |
Implements MsecUnitySdk.IMsecSdkClient.
Implemented in MsecUnitySdk.iOS.MsecSdkClient, MsecUnitySdk.DummyMsecSdkClient, and MsecUnitySdk.Android.MsecSdkClient.
|
protected |
The configuration settings for the SDK.
Stores the MsecSdkConfig instance passed during initialization, controlling options like debug mode.
|
protected |
The listener for receiving SDK callbacks.
Stores the IMsecSdkListener instance passed during initialization to handle events like violations or performance data.