Take b = 2.

b^(n-1) mod n = 1.

797 is prime.

b^((n-1)/797)-1 mod n = 4747721, which is a unit, inverse 3435848.

97 is prime.

b^((n-1)/97)-1 mod n = 2399131, which is a unit, inverse 5752844.

(97 * 797) divides n-1.

(97 * 797)^2 > n.

n is prime by Pocklington's theorem.