/test/xts/acts/security/crypto_framework_napi_BasicTest/src/ |
H A D | crypto_framework_asym_key_test.cpp | 114 static OH_Crypto_ErrCode Rsa_PubkeyEncode(OH_CryptoAsymKeyGenerator *ctx, OH_CryptoPubKey *pubKey, OH_CryptoKeyPair **dupKeyPair) in Rsa_PubkeyEncode() argument 118 ret = OH_CryptoPubKey_Encode(pubKey, CRYPTO_PEM, "PKCS1", &retBlob); in Rsa_PubkeyEncode() 130 static OH_Crypto_ErrCode Ecc_PubkeyEncode(OH_CryptoAsymKeyGenerator *ctx, OH_CryptoPubKey *pubKey, OH_CryptoKeyPair **dupKeyPair) in Ecc_PubkeyEncode() argument 134 ret = OH_CryptoPubKey_Encode(pubKey, CRYPTO_DER, "X509|COMPRESSED", &retBlob); in Ecc_PubkeyEncode() 146 static OH_Crypto_ErrCode PubkeyEncode(OH_CryptoAsymKeyGenerator *ctx, OH_CryptoPubKey *pubKey, OH_CryptoKeyPair **dupKeyPair) in PubkeyEncode() argument 150 ret = OH_CryptoPubKey_Encode(pubKey, CRYPTO_DER, nullptr, &retBlob); in PubkeyEncode() 162 static OH_Crypto_ErrCode Ecc_GetEncode(OH_CryptoPubKey *pubKey, Crypto_DataBlob *value) in Ecc_GetEncode() argument 164 OH_Crypto_ErrCode ret = OH_CryptoPubKey_GetParam(pubKey, CRYPTO_ECC_FP_P_DATABLOB, value); in Ecc_GetEncode() 168 static OH_Crypto_ErrCode Rsa_GetEncode(OH_CryptoPubKey *pubKey, Crypto_DataBlob *value) in Rsa_GetEncode() argument 170 OH_Crypto_ErrCode ret = OH_CryptoPubKey_GetParam(pubKey, CRYPTO_RSA_N_DATABLO in Rsa_GetEncode() 174 GetEncode(const char *name, OH_CryptoPubKey *pubKey, Crypto_DataBlob *value) GetEncode() argument 220 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_P() local 312 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(dupKeyPair); HWTEST_F() local 342 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(dupKeyPair); HWTEST_F() local 369 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 414 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 464 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 496 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 529 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 556 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local [all...] |
H A D | crypto_framework_verify_test.cpp | 618 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); in HWTEST_P() local 619 ASSERT_EQ(OH_CryptoPubKey_GetParam(pubKey, CRYPTO_RSA_N_DATABLOB, &n), CRYPTO_SUCCESS); in HWTEST_P() 626 ASSERT_EQ(OH_CryptoVerify_Init(verify, pubKey), CRYPTO_SUCCESS); in HWTEST_P() 679 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); in HWTEST_P() local 684 ASSERT_EQ(OH_CryptoVerify_Init(verify, pubKey), CRYPTO_SUCCESS); in HWTEST_P() 745 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); in HWTEST_P() local 750 ASSERT_EQ(OH_CryptoVerify_Init(verify, pubKey), CRYPTO_SUCCESS); in HWTEST_P() 789 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); in HWTEST_P() local 794 ASSERT_EQ(OH_CryptoVerify_Init(verify, pubKey), CRYPTO_SUCCESS); in HWTEST_P() 849 OH_CryptoPubKey *pubKey in HWTEST_P() local 907 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 942 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 985 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1027 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1068 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1110 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1148 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1187 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1231 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair_B); HWTEST_F() local 1274 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1317 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1359 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1403 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1456 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair_B); HWTEST_F() local 1520 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1585 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1641 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1685 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1728 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local 1774 OH_CryptoPubKey *pubKey = OH_CryptoKeyPair_GetPubKey(keyPair); HWTEST_F() local [all...] |
/test/xts/acts/security/cryptoFramework/js_api_test_oh40/entry/src/ohosTest/js/test/ |
H A D | AsyGetKeySpecBySpec.test.js | 58 let pk = keyPair.pubKey.getAsyKeySpec(
62 let n = keyPair.pubKey.getAsyKeySpec(
95 let p = keyPair.pubKey.getAsyKeySpec(
99 let q = keyPair.pubKey.getAsyKeySpec(
103 let g = keyPair.pubKey.getAsyKeySpec(
107 let pk = keyPair.pubKey.getAsyKeySpec(
144 let p = callbackKeyPair.pubKey.getAsyKeySpec(
148 let a = callbackKeyPair.pubKey.getAsyKeySpec(
152 let b = callbackKeyPair.pubKey.getAsyKeySpec(
156 let gx = callbackKeyPair.pubKey [all...] |
H A D | AsyKeyGeneratorBySpecTwo.test.js | 131 .then((pubKey) => {
132 console.log("pubKey" + pubKey);
255 * @tc.name RSA pubKey generation prikey failed
|
/test/xts/acts/security/cryptoFramework/js_api_test_oh40/entry/src/ohosTest/js/test/utils/asymmetric/ |
H A D | publicAsymmetricPromise.js | 28 var pubKey;
34 pubKey = rsaKeyPair.pubKey;
35 let encodedPubKey = pubKey.getEncoded();
159 async function initVerify(verifyGenerator, pubKey) {
162 .init(pubKey)
206 async function generateAsySecret(generator, priKey, pubKey) {
209 .generateSecret(priKey, pubKey)
240 globalRsaKeyPair.pubKey,
301 let encodedPubKey = rsaKeyPair.pubKey [all...] |
H A D | publicAsymmetricCallback.js | 29 var pubKey;
37 pubKey = rsaKeyPair.pubKey;
38 let encodedPubKey = pubKey.getEncoded();
39 console.log("[Callback]: pubKey.getAlgorithm= " + pubKey.algName);
40 console.log("[Callback]: pubKey.getEncoded= " + encodedPubKey.data);
41 console.log("[Callback]: pubKey.getFormat= " + pubKey.format);
157 async function initVerify(verifyGenerator, pubKey) {
[all...] |
/test/xts/acts/security/cryptoFramework/js_api_test_one/entry/src/ohosTest/js/test/utils/asymmetric/ |
H A D | publicAsymmetricCallback.js | 32 var pubKey;
40 pubKey = rsaKeyPair.pubKey;
41 let encodedPubKey = pubKey.getEncoded();
42 console.log("[Callback]: pubKey.getAlgorithm= " + pubKey.algName);
43 console.log("[Callback]: pubKey.getEncoded= " + encodedPubKey.data);
44 console.log("[Callback]: pubKey.getFormat= " + pubKey.format);
160 async function initVerify(verifyGenerator, pubKey) {
[all...] |
H A D | publicAsymmetricPromise.js | 28 var pubKey;
34 pubKey = rsaKeyPair.pubKey;
35 let encodedPubKey = pubKey.getEncoded();
36 console.log("[Promise]: pubKey.getAlgorithm= " + pubKey.algName);
37 console.log("[Promise]: pubKey.getEncoded= " + encodedPubKey.data);
38 console.log("[Promise]: pubKey.getFormat= " + pubKey.format);
157 async function initVerify(verifyGenerator, pubKey) {
[all...] |
/test/xts/acts/security/certificate_framework/js_api_test_one/entry/src/ohosTest/js/test/utils/certificate/ |
H A D | publicCertificateCallback.js | 116 async function verifyX509Cert(certInstance, pubKey) {
118 certInstance.verify(pubKey, (err) => {
132 var pubKey;
variable 137 pubKey = gInstance.getPublicKey();
138 expect(pubKey != null).assertTrue();
141 pubKey = crlVerifyPubKeyHex;
143 pubKey = flag;
146 return verifyX509Cert(gInstance, pubKey);
444 async function verifyX509Crl(crlInstance, pubKey) {
446 crlInstance.verify(pubKey, (er [all...] |
H A D | publicCertificatePromise.js | 451 let pubKey = convertKeyPair.pubKey;
454 pubKey = flag;
456 pubKey = convertKeyPair.priKey;
459 return globalCrlInstance.verify(pubKey);
|
/foundation/communication/dsoftbus/core/adapter/huks/src/ |
H A D | softbus_rsa_encrypt.c | 131 uint8_t pubKey[HKS_RSA_KEY_SIZE_4096] = { 0 }; in SoftBusGetPublicKey() local 132 struct HksBlob publicKeyBlob = { HKS_RSA_KEY_SIZE_4096, pubKey }; in SoftBusGetPublicKey() 151 (void)memset_s(pubKey, sizeof(pubKey), 0, sizeof(pubKey)); in SoftBusGetPublicKey() 154 (void)memset_s(pubKey, sizeof(pubKey), 0, sizeof(pubKey)); in SoftBusGetPublicKey() 250 static int32_t DataToPublicKey(const uint8_t *bufKey, int32_t bufKeyLen, RSA **pubKey) in DataToPublicKey() argument 255 if (bufKey == NULL || bufKeyLen < 0 || pubKey in DataToPublicKey() [all...] |
/test/xts/acts/security/huks/huks_napi_BasicTest/src/ |
H A D | huks_signverify_rsa_test_common.cpp | 78 uint8_t pubKey[OH_HUKS_RSA_KEY_SIZE_1024] = {0}; in HksRsaSignVerifyTestNormalCase() local 79 struct OH_Huks_Blob publicKey = {OH_HUKS_RSA_KEY_SIZE_1024, pubKey}; in HksRsaSignVerifyTestNormalCase() 141 uint8_t pubKey[OH_HUKS_RSA_KEY_SIZE_1024] = {0}; in HksRSASignVerifyTestAbnormalCase() local 142 struct OH_Huks_Blob publicKey = {OH_HUKS_RSA_KEY_SIZE_1024, pubKey}; in HksRSASignVerifyTestAbnormalCase()
|
H A D | huks_signverify_ed25519_test.cpp | 110 uint8_t pubKey[OH_HUKS_CURVE25519_KEY_SIZE_256] = {0}; in HWTEST_F() local 111 struct OH_Huks_Blob publicKey = {OH_HUKS_CURVE25519_KEY_SIZE_256, pubKey}; in HWTEST_F()
|
H A D | huks_signverify_ecc_test_common.cpp | 66 uint8_t pubKey[OH_HUKS_ECC_KEY_SIZE_521] = {0}; in HksEccSignVerifyTestNormalCase() local 67 struct OH_Huks_Blob publicKey = {OH_HUKS_ECC_KEY_SIZE_521, pubKey}; in HksEccSignVerifyTestNormalCase()
|
H A D | huks_signverify_dsa_test.cpp | 105 uint8_t pubKey[DSA_COMMON_SIZE] = {0}; in HksDsaSignVerifyTestNormalCase() local 106 struct OH_Huks_Blob publicKey = {DSA_COMMON_SIZE, pubKey}; in HksDsaSignVerifyTestNormalCase()
|
H A D | huks_signverify_sm2_test.cpp | 248 uint8_t pubKey[OH_HUKS_MAX_KEY_SIZE] = {0}; in HksSm2SignVerifyTestRun() local 249 struct OH_Huks_Blob publicKey = {OH_HUKS_MAX_KEY_SIZE, pubKey}; in HksSm2SignVerifyTestRun()
|
/test/xts/acts/security_lite/huks/common/ |
H A D | hks_test_aes.c | 294 static void ExportPubKey(const struct HksBlob *alias, struct HksBlob *pubKey) in ExportPubKey() argument 296 HKS_TEST_ASSERT(HksExportPublicKey(alias, NULL, pubKey) == 0); in ExportPubKey() 299 static void ImportPubKey(const struct HksBlob *alias, const struct HksBlob *pubKey) in ImportPubKey() argument 301 HKS_TEST_LOG_I("Test_Import pubKey!\n"); in ImportPubKey() 326 HKS_TEST_ASSERT(HksImportKey(alias, paramSet, pubKey) == 0); in ImportPubKey()
|
H A D | hks_test_curve25519.c | 201 uint8_t pubKey[32] = {0}; in TestExportImportEd25519SignVerify() local 203 struct HksBlob pubKeyInfo = { pubKeyLen, pubKey }; in TestExportImportEd25519SignVerify()
|
/third_party/node/test/parallel/ |
H A D | test-tls-peer-certificate.js | 119 assert.strictEqual(peerCert.pubKey, undefined);
|
/foundation/communication/bluetooth_service/services/bluetooth/stack/src/smp/ |
H A D | smp_tool.h | 186 void SMP_GetPublicKeyX(const uint8_t *pubKey, uint8_t *x, uint8_t length);
|
H A D | smp_tool.c | 956 void SMP_GetPublicKeyX(const uint8_t *pubKey, uint8_t *x, uint8_t length) in SMP_GetPublicKeyX() argument 959 x[index] = pubKey[length - 0x01 - index]; in SMP_GetPublicKeyX()
|
/test/xts/acts/security/huks/security_huks_reformed_test/huks_hmac_callback_BasicTest/entry/src/ohosTest/js/test/HMAC/ |
H A D | SecurityHuksImportJsunit.test.js | 980 console.error(`promise: generate pubKey failed, code: ${e.code}, msg: ${e.message}`);
|