Lines Matching refs:cleanup
104 "Unsupported hash algorithm (%"PRIu16")", cleanup, hashAlg); in iesys_cryptossl_hash_start()
109 "Unsupported hash algorithm (%"PRIu16")", cleanup, hashAlg); in iesys_cryptossl_hash_start()
113 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Error EVP_MD_CTX_create", cleanup); in iesys_cryptossl_hash_start()
119 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Errror EVP_DigestInit_ex", cleanup); in iesys_cryptossl_hash_start()
126 cleanup: in iesys_cryptossl_hash_start()
299 "Unsupported hash algorithm (%"PRIu16")", cleanup, hashAlg); in iesys_cryptossl_hmac_start()
304 "Unsupported hash algorithm (%"PRIu16")", cleanup, hashAlg); in iesys_cryptossl_hmac_start()
309 "Error EVP_MD_CTX_create", cleanup); in iesys_cryptossl_hmac_start()
314 "EVP_PKEY_new_mac_key", cleanup); in iesys_cryptossl_hmac_start()
320 "DigestSignInit", cleanup); in iesys_cryptossl_hmac_start()
331 cleanup: in iesys_cryptossl_hmac_start()
429 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "DigestSignFinal", cleanup); in iesys_cryptossl_hmac_finish()
434 cleanup: in iesys_cryptossl_hmac_finish()
575 "Could not allocate Big Number", cleanup); in iesys_cryptossl_pk_encrypt()
589 goto_error(r, TSS2_ESYS_RC_BAD_VALUE, "Illegal RSA scheme", cleanup); in iesys_cryptossl_pk_encrypt()
599 "Could not set exponent.", cleanup); in iesys_cryptossl_pk_encrypt()
604 "Could not allocate RSA key", cleanup); in iesys_cryptossl_pk_encrypt()
611 cleanup); in iesys_cryptossl_pk_encrypt()
616 "Could not create evp key.", cleanup); in iesys_cryptossl_pk_encrypt()
623 "Could not create rsa n.", cleanup); in iesys_cryptossl_pk_encrypt()
631 "Could not create rsa n.", cleanup); in iesys_cryptossl_pk_encrypt()
636 "Could not set rsa n.", cleanup); in iesys_cryptossl_pk_encrypt()
642 "Could not set rsa key.", cleanup); in iesys_cryptossl_pk_encrypt()
647 "Could not create evp context.", cleanup); in iesys_cryptossl_pk_encrypt()
652 "Could not init encrypt context.", cleanup); in iesys_cryptossl_pk_encrypt()
657 "Could not set RSA passing.", cleanup); in iesys_cryptossl_pk_encrypt()
663 "Could not duplicate OAEP label", cleanup); in iesys_cryptossl_pk_encrypt()
669 "Could not set RSA label.", cleanup); in iesys_cryptossl_pk_encrypt()
674 "Could not set hash algorithm.", cleanup); in iesys_cryptossl_pk_encrypt()
680 "Could not determine ciper size.", cleanup); in iesys_cryptossl_pk_encrypt()
685 "Encrypted data too big", cleanup); in iesys_cryptossl_pk_encrypt()
691 "Could not encrypt data.", cleanup); in iesys_cryptossl_pk_encrypt()
696 cleanup: in iesys_cryptossl_pk_encrypt()
726 "Create big num from byte buffer.", cleanup); in tpm_pub_to_ossl_pub()
733 "Create big num from byte buffer.", cleanup); in tpm_pub_to_ossl_pub()
739 "Create point.", cleanup); in tpm_pub_to_ossl_pub()
747 "Set affine coordinates", cleanup); in tpm_pub_to_ossl_pub()
752 "The TPM point is not on the curve", cleanup); in tpm_pub_to_ossl_pub()
755 cleanup: in tpm_pub_to_ossl_pub()
828 "Create group for curve", cleanup); in iesys_cryptossl_get_ecdh_point()
834 "Create ec key", cleanup); in iesys_cryptossl_get_ecdh_point()
838 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Set group", cleanup); in iesys_cryptossl_get_ecdh_point()
842 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Generate ec key", cleanup); in iesys_cryptossl_get_ecdh_point()
846 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Get public key", cleanup); in iesys_cryptossl_get_ecdh_point()
851 "Ephemeral public key is on curve",cleanup); in iesys_cryptossl_get_ecdh_point()
856 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Create bignum", cleanup); in iesys_cryptossl_get_ecdh_point()
860 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Create bignum", cleanup); in iesys_cryptossl_get_ecdh_point()
866 "Get affine x coordinate", cleanup); in iesys_cryptossl_get_ecdh_point()
871 "Write big num byte buffer", cleanup); in iesys_cryptossl_get_ecdh_point()
876 "Write big num byte buffer", cleanup); in iesys_cryptossl_get_ecdh_point()
884 goto_if_error(r, "Convert TPM pub point to ossl pub point", cleanup); in iesys_cryptossl_get_ecdh_point()
890 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Create point.", cleanup); in iesys_cryptossl_get_ecdh_point()
896 "ec point multiplication", cleanup); in iesys_cryptossl_get_ecdh_point()
903 "Get affine x coordinate", cleanup); in iesys_cryptossl_get_ecdh_point()
908 "Write big num byte buffer", cleanup); in iesys_cryptossl_get_ecdh_point()
916 goto_if_error(r, "Error marshaling", cleanup); in iesys_cryptossl_get_ecdh_point()
919 cleanup: in iesys_cryptossl_get_ecdh_point()
979 cleanup); in iesys_cryptossl_sym_aes_encrypt()
984 "AES encrypt called with wrong algorithm.", cleanup); in iesys_cryptossl_sym_aes_encrypt()
990 "Initialize cipher context", cleanup); in iesys_cryptossl_sym_aes_encrypt()
995 "Initialize cipher operation", cleanup); in iesys_cryptossl_sym_aes_encrypt()
998 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Set key and iv", cleanup); in iesys_cryptossl_sym_aes_encrypt()
1003 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Encrypt update", cleanup); in iesys_cryptossl_sym_aes_encrypt()
1007 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Encrypt final", cleanup); in iesys_cryptossl_sym_aes_encrypt()
1011 cleanup: in iesys_cryptossl_sym_aes_encrypt()
1058 "AES encrypt called with wrong algorithm.", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1070 "AES algorithm not implemented.", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1076 "Initialize cipher context", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1083 "Initialize cipher operation", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1087 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Set key and iv", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1092 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Encrypt update", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1096 goto_error(r, TSS2_ESYS_RC_GENERAL_FAILURE, "Encrypt final", cleanup); in iesys_cryptossl_sym_aes_decrypt()
1100 cleanup: in iesys_cryptossl_sym_aes_decrypt()