swift-tdsa-lib
The swift-tdsa-lib is used to write applications for iOS that serve as client participants in MPC protocols.
Getting Started
Cocoapods
You will need credentials for the Sepior Nexus server and the Sepior Gitlab repository.
Add the following to a .netrc file in your home directory:
machine nexus.sepior.net
login <NEXUS_USER>
password <NEXUS_PASSWORD>
Add these two lines to your Podfile:
source '[email protected]:sepior/specs.git'
and
pod 'swift-tdsa-lib', <VERSION>
Carthage
Create a JSON file with this content:
{
"[version]": "https://[username]:[password]@nexus.sepior.net/repository/sepior-tdsa-lib/com/sepior/tdsa/swift-tdsa-lib/[version]/swift-tdsa-lib-[version]zip"
}
And in your Cartfile add the following:
binary "[path_to_json_file]" ~> [version]
Main Classes
These are the main classes and interfaces used to integrate the library into an application.
TdsaClient
This interface contains all the high-level functionality of the MPC system. It has methods for key generation, signing, backup, emergency recovery, etc.
TdsaLibraryConfiguration
This class contains configuration data for the participant that the application implements. Things like session timeout, number of concurrent sessions, addresses, and public keys for the other participants are configured in this class. It also allows loading the configuration from a YAML file.
TdsaFactory
This is the factory class used to create an actual instance of TdsaClient using a TdsaLibraryConfiguration and an implementation of KeyStorage.
To summarize, the task of the integrator (for a client application) is to provide an implementation of KeyStorage and create an instance of TdsaLibraryConfiguration. These are used to obtain a TdsaClient from TdsaFactory.
Updated 18 days ago