DerivedController

@objc public class DerivedController : NSObject

DerivedController is the interface to interact with DerivedKit and perform derived credential operations. This allows the user to authenticate, sign, and decrypt data.

  • Retrieves the instance of the Derived Controller

    Returns

    The instance of the derived controller

    Declaration

    Swift

    public static func getInstance() -> DerivedController!
  • Sets the URL scheme for the app

    Parameter

    Parameter scheme: The URL Scheme to callback the app

    Declaration

    Swift

    public final func setScheme(scheme: String)

    Parameters

    scheme

    The URL Scheme to callback the app

  • Invoked from the App Delegate method to handle the derived credential callback

    Parameter

    Parameter url: The URL of the callback containing the data for the path

    Parameter

    Parameter sourceApplication: Optional source application, unused presently

    Returns

    A bool indicating if the url was handled

    Declaration

    Swift

    public func handleOpenUrl(url: NSURL, sourceApplication: String? = nil) -> Bool

    Parameters

    url

    The URL of the callback containing the data for the path

    sourceApplication

    Optional source application, unused presently

    Return Value

    A bool indicating if the url was handled

  • Prompts the user to login the derived credential app

    Parameter

    Parameter viewController: The parent view controller to prompt the user to install the derived credential app

    Declaration

    Swift

    public func promptToInstallApp(viewController: UIViewController)
  • Requests the user to sign a specific piece of data

    Parameter

    Parameter caPath: The CA path to down select a credential with

    Parameter

    Parameter data: data to be signed

    Parameter

    Parameter algorithm: the hashing algorithm to sign the data with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func sign(withCA caPath: String?, data: NSData, algorithm: DerivedHashingAlgorithm, callback: DerivedCredentialDataCallback)

    Parameters

    caPath

    The CA path to down select a credential with

    data

    data to be signed

    algorithm

    the hashing algorithm to sign the data with

    callback

    Callback to process the result from the app

  • Requests the user to sign a specific piece of data

    Parameter

    Parameter caPath: The CA path to down select a credential with

    Parameter

    Parameter data: data to be signed

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func sign(withCA caPath: String?, data: NSData, callback: DerivedCredentialDataCallback)

    Parameters

    caPath

    The CA path to down select a credential with

    data

    data to be signed

    callback

    Callback to process the result from the app

  • Requests the user to sign a specific piece of data

    Parameter

    Parameter data: data to be signed

    Parameter

    Parameter algorithm: the hashing algorithm to sign the data with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func sign(data data: NSData, algorithm: DerivedHashingAlgorithm, callback: DerivedCredentialDataCallback)

    Parameters

    data

    data to be signed

    algorithm

    the hashing algorithm to sign the data with

    callback

    Callback to process the result from the app

  • Requests the user to sign a specific piece of data

    Parameter

    Parameter data: data to be signed

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func sign(data data: NSData, callback: DerivedCredentialDataCallback)

    Parameters

    data

    data to be signed

    callback

    Callback to process the result from the app

  • Requests the credentials from the Derived app

    Parameter

    Parameter caPath: The optional CA path to down select a credential with

    Parameter

    Parameter withData: data to request be signed by DerivedKit

    Parameter

    Parameter usingAlgorithm: the hashing algorithm to sign the data with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func authenticate(withCA caPath: String?, withData data: NSData?, usingAlgorithm algorithm: DerivedHashingAlgorithm, callback: DerivedCredentialCallback)

    Parameters

    caPath

    The optional CA path to down select a credential with

    withData

    data to request be signed by DerivedKit

    usingAlgorithm

    the hashing algorithm to sign the data with

    callback

    Callback to process the result from the app

  • Requests the credentials from the Derived app

    Parameter

    Parameter caPath: The optional CA path to down select a credential with

    Parameter

    Parameter algorithm: the hashing algorithm to sign the data with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func authenticate(withCA caPath: String?, usingAlgorithm algorithm: DerivedHashingAlgorithm, callback: DerivedCredentialCallback)

    Parameters

    caPath

    The optional CA path to down select a credential with

    algorithm

    the hashing algorithm to sign the data with

    callback

    Callback to process the result from the app

  • Requests the credentials from the Derived app

    Parameter

    Parameter caPath: The optional CA path to down select a credential with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func authenticate(withCA caPath: String?, callback: DerivedCredentialCallback)

    Parameters

    caPath

    The optional CA path to down select a credential with

    callback

    Callback to process the result from the app

  • Requests the credentials from the Derived app

    Parameter

    Parameter algorithm: the hashing algorithm to sign the data with

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func authenticate(withHashingAlgorithm algorithm: DerivedHashingAlgorithm, callback: DerivedCredentialCallback)

    Parameters

    algorithm

    the hashing algorithm to sign the data with

    callback

    Callback to process the result from the app

  • Requests the credentials from the Derived app

    Parameter

    Parameter callback: Callback to process the result from the app

    Declaration

    Swift

    public func authenticate(callback: DerivedCredentialCallback)

    Parameters

    callback

    Callback to process the result from the app