Primality proof for n = 5842037431:
Take b = 2.
b^(n-1) mod n = 1.
103 is prime.
b^((n-1)/103)-1 mod n = 3156376229, which is a unit, inverse 2943989098.
97 is prime.
b^((n-1)/97)-1 mod n = 3073569831, which is a unit, inverse 4442220496.
89 is prime.
b^((n-1)/89)-1 mod n = 4774961049, which is a unit, inverse 346071677.
(89 * 97 * 103) divides n-1.
(89 * 97 * 103)^2 > n.
n is prime by Pocklington's theorem.