tools/header_generation/create_hdr_common.c
/***************************************************************************
 * Function	:	calculate_signature
 * Arguments	:	NONE
 * Return	:	SUCCESS or FAILURE
 * Description	:	Calculate Signature over Image Hash
 ***************************************************************************/
Function     :       calculate_signature
Arguments    :       NONE
Return       :       SUCCESS or FAILURE
Description  :       Calculate Signature over Image Hash
Function : calculate_signature Arguments : NONE Return : SUCCESS or FAILURE Description : Calculate Signature over Image Hash
int calculate_signature(void)
{
	int ret;
	ret = crypto_rsa_sign(gd.img_hash, SHA256_DIGEST_LENGTH,
		gd.rsa_sign, &gd.rsa_size, gd.pri_fname[gd.srk_sel - 1]);
	if (ret != SUCCESS)
		printf("Error in Signing\n");
	return ret;
}
int calculate_signature ( void ) { int ret ; ret = crypto_rsa_sign ( gd . img_hash , SHA256_DIGEST_LENGTH , gd . rsa_sign , & gd . rsa_size , gd . pri_fname [ gd . srk_sel - 1 ] ) ; if ( ret != SUCCESS ) printf ( " \n " ) ; return ret ; }
Function     :       calculate_signature
 Arguments    :       NONE
 Return       :       SUCCESS or FAILURE
 Description  :       Calculate Signature over Image Hash
Function : calculate_signature Arguments : NONE Return : SUCCESS or FAILURE Description : Calculate Signature over Image Hash