public func importSecrets(jsonRecoverySecrets: String, exportPassphrase: String, newSecretsFile: String, newPassphrase: String) throws -> String
let jsonRecoverySecrets = "{}" // exported jsonRecoverySecrets
let exportPassphrase = "wZdcycVuexvmgt7aMkaeA_2_ioCKrw!B"
let newSecretsFile = "secrets.db"
let newPassphrase = "d3hxNyoiAP@Lm!D7Qpo_hghdpgyc_r39"
do {
let tssNodeID = try importSecrets(
jsonRecoverySecrets: jsonRecoverySecrets,
exportPassphrase: exportPassphrase,
newSecretsFile: newSecretsFile,
newPassphrase: newPassphrase
)
print("TSS Node ID: \(tssNodeID)")
} catch {
print("Error: \(error)")
}
Parameters
The passphrase-encrypted JSON data of Secrets, created by the Export Secrets operations.
The passphrase used to decrypt the imported JSON data of Secrets.
The file path where the new Secrets will be stored.
A passphrase for encrypting the new Secrets. It must be at least 16 characters long.
Response
The TSS Node ID of the newly created Secrets.