// test openssl BIGNUM, without error checking // #include #include int main( void) { char line[BUFSIZ]; BIGNUM *x = BN_new(), *y = BN_new(); fgets( line, BUFSIZ, stdin); BN_hex2bn( &x, line); printf( "x = "); BN_print_fp( stdout, x); putchar('\n'); BN_add( y, x, x); printf( "y = "); BN_print_fp( stdout, y); putchar('\n'); } /* sample run: $ echo "0753" | ./p1 x = 753 y = EA6 $ */