*cb);

 int BN_is_prime_fasttest_ex(const BIGNUM *p, int nchecks, BN_CTX *ctx,
                             int do_trial_division, BN_GENCB *cb);</code></pre>

<h1 id="DESCRIPTION">DESCRIPTION</h1>

<p>BN_generate_prime_ex2() generates a pseudo-random prime number of at least bit length <b>bits</b> using the BN_CTX provided in <b>ctx</b>. The value of <b>ctx</b> must not be NULL.</p>

<p>The returned number is probably prime with a negligible error. The maximum error rate is 2^-128. It&#39;s 2^-287 for a 51