public final class PasscodeEncryptionSupport extends Object
Nest Passcode Encryption スキームを使用してパスコードを暗号化および復号するためのユーティリティ メソッド。
定数の概要
int | kPasscodeEncryptionConfig1_TEST_ONLY | パスコード暗号化構成 1(テスト専用) 注: この暗号化構成はテスト専用であり、完全性や機密性は提供されません。 |
int | kPasscodeEncryptionConfig2 | パスコード暗号化構成 2 |
フィールドの概要
public static final byte[] | kPasscodeEncKeyDiversifier | パスコードの暗号化と認証の鍵の導出に使用される鍵ダイバーシファイア。 |
public static final byte[] | kPasscodeFingerprintKeyDiversifier | パスコード指紋鍵の導出に使用される鍵ダイバーシファイア。 |
パブリック コンストラクタの概要
パブリック メソッドの概要
static String |
decryptPasscode(byte[] encryptedPasscode, byte[] encKey, byte[]
authKey, byte[] fingerprintKey)
Nest Passcode Encryption スキームを使用して暗号化されたパスコードを復号します。
|
static byte[] |
encryptPasscode(int config, int keyId, long nonce, String passcode,
byte[] encKey, byte[] authKey, byte[] fingerprintKey)
Nest パスコード暗号化スキームを使用してパスコードを暗号化します。
|
static int |
getEncryptedPasscodeConfig(byte[] encryptedPasscode)
暗号化されたパスコードから構成タイプを抽出します。
|
static byte[] |
getEncryptedPasscodeFingerprint(byte[] encryptedPasscode)
暗号化されたパスコードから指紋を抽出します。
|
static int |
getEncryptedPasscodeKeyId(byte[] encryptedPasscode)
暗号化されたパスコードから鍵 ID を抽出します。
|
static long |
getEncryptedPasscodeNonce(byte[] encryptedPasscode)
暗号化されたパスコードから nonce 値を抽出します。
|
static boolean |
isSupportedPasscodeEncryptionConfig(int config)
指定されたパスコード暗号化構成がサポートされているかどうかを判断します。
|
継承されたメソッドの概要
定数
public static final int kPasscodeEncryptionConfig1_TEST_ONLY
パスコード暗号化構成 1(テスト専用)注: この暗号化構成はテスト専用であり、完全性や機密性は提供されません。Config 1 は開発ビルドでのみ利用できます。
定数値: 1
public static final int kPasscodeEncryptionConfig2
パスコード暗号化構成 2
定数値: 2
フィールド
public static final byte[] kPasscodeEncKeyDiversifier
パスコードの暗号化と認証の鍵の導出に使用される鍵ダイバーシファイア。
public static final byte[] kPasscodeFingerprintKeyDiversifier
パスコード指紋鍵の導出に使用される鍵ダイバーシファイア。
パブリック コンストラクタ
public PasscodeEncryptionSupport ()
パブリック メソッド
public static String decryptPasscode (byte[] encryptedPasscode, byte[] encKey, byte[] authKey, byte[] fingerprintKey)
Nest Passcode Encryption スキームを使用して暗号化されたパスコードを復号します。
パラメータ
encryptedPasscode | |
---|---|
encKey | |
authKey | |
fingerprintKey |
public static byte[] encryptPasscode (int config, int keyId, long nonce, String passcode, byte[] encKey, byte[] authKey, byte[] fingerprintKey)
Nest パスコード暗号化スキームを使用してパスコードを暗号化します。
パラメータ
config | |
---|---|
keyId | |
nonce | |
パスコード | |
encKey | |
authKey | |
fingerprintKey |
public static int getEncryptedPasscodeConfig (byte[] encryptedPasscode)
public static byte[] getEncryptedPasscodeFingerprint (byte[] encryptedPasscode)
public static int getEncryptedPasscodeKeyId (byte[] encryptedPasscode)
public static long getEncryptedPasscodeNonce (byte[] encryptedPasscode)
public static boolean isSupportedPasscodeEncryptionConfig (int config)
指定されたパスコード暗号化構成がサポートされているかどうかを判断します。
パラメータ
config |
---|