  Over a field of characteristic 0, every ring of invariants of any finite
group is Cohen-Macaulay. This is not true for fields of positive
characteristic. We consider permutation representations and their invariant
rings over fields $\mathbb{F}_p$ of prime order. We give an efficient algorithm
which for any given permutation representation, determines those primes $p$ for
which the invariant ring over $\mathbb{F}_p$ is Cohen-Macaulay. Extensions to
subgroups of reflection groups other than the symmetric group are indicated.
