API Documentation Integration MsecSdk
Public Member Functions | Properties | List of all members
MsecUnitySdk.iOS.MsecSdkClient Class Reference

iOS-specific implementation of the Msec SDK client. More...

Inheritance diagram for MsecUnitySdk.iOS.MsecSdkClient:
Inheritance graph
[legend]
Collaboration diagram for MsecUnitySdk.iOS.MsecSdkClient:
Collaboration graph
[legend]

Public Member Functions

override void Init (IMsecSdkListener listener, MsecSdkConfig config)
 Initializes the Msec SDK client for iOS. More...
 
override DomainCertificateVerificationResult VerifyDomainCertificate (string domain, int port)
 Verifies the SSL certificate of a domain on iOS. More...
 
override string GetOTPCode (double timestamp)
 Retrieves an OTP code using a timestamp on iOS. More...
 
override void RegisterCallbacks ()
 Registers native callbacks for the Msec SDK on iOS. More...
 

Properties

static MsecSdkClient Instance [get]
 Gets the singleton instance of the MsecSdkClient for iOS. More...
 

Additional Inherited Members

- Protected Member Functions inherited from MsecUnitySdk.BaseMsecSdkClient
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 inherited from MsecUnitySdk.BaseMsecSdkClient
IMsecSdkListener listener
 The listener for receiving SDK callbacks. More...
 
MsecSdkConfig config
 The configuration settings for the SDK. More...
 

Detailed Description

iOS-specific implementation of the Msec SDK client.

This class extends BaseMsecSdkClient to provide iOS-specific functionality for the Msec SDK, including native callback registration, certificate verification, and OTP generation via P/Invoke calls to the iOS native library. It uses a singleton pattern to ensure a single instance is used throughout the application.

Member Function Documentation

◆ GetOTPCode()

override string MsecUnitySdk.iOS.MsecSdkClient.GetOTPCode ( double  timestamp)
inlinevirtual

Retrieves an OTP code using a timestamp on iOS.

Calls the native msec_get_otp_code function via P/Invoke to get the OTP code from the iOS library.

Parameters
timestampThe timestamp used to generate the OTP code.
Returns
A string representing the OTP code, or an error message if the call fails.

Implements MsecUnitySdk.BaseMsecSdkClient.

◆ Init()

override void MsecUnitySdk.iOS.MsecSdkClient.Init ( IMsecSdkListener  listener,
MsecSdkConfig  config 
)
inlinevirtual

Initializes the Msec SDK client for iOS.

Extends the base Init method to perform iOS-specific initialization by calling the native msec_init function and registering callbacks.

Parameters
listenerThe listener to receive SDK callbacks.
configThe configuration settings for the SDK.

Reimplemented from MsecUnitySdk.BaseMsecSdkClient.

◆ RegisterCallbacks()

override void MsecUnitySdk.iOS.MsecSdkClient.RegisterCallbacks ( )
inlinevirtual

Registers native callbacks for the Msec SDK on iOS.

Sets up the violation, performance, and initialization callbacks by registering them with the native iOS library.

Implements MsecUnitySdk.BaseMsecSdkClient.

◆ VerifyDomainCertificate()

override DomainCertificateVerificationResult MsecUnitySdk.iOS.MsecSdkClient.VerifyDomainCertificate ( string  domain,
int  port 
)
inlinevirtual

Verifies the SSL certificate of a domain on iOS.

Calls the native msec_verify_domain_ssl_certificate function via P/Invoke to perform the verification.

Parameters
domainThe domain name to verify (e.g., "google.com").
portThe port number to check (e.g., 443 for HTTPS).
Returns
A DomainCertificateVerificationResult indicating the verification outcome.

Implements MsecUnitySdk.BaseMsecSdkClient.

Property Documentation

◆ Instance

MsecSdkClient MsecUnitySdk.iOS.MsecSdkClient.Instance
staticget

Gets the singleton instance of the MsecSdkClient for iOS.

Returns
The singleton instance of MsecSdkClient.

The documentation for this class was generated from the following file: