Your first option would be using special cat wipes. These products are designed specifically to wipe away feces and other substances off your cat's fur.
If you don't want to spend money on cat wipes, a warm wet cloth is a solid alternative. It'll have no trouble getting the substances off your cat's bum. But it's essential to wash it thoroughly after use or put it right into your washing machine.
Some cat owners find themselves preferring to use damp paper towels. These products will wipe down the area without much issue, but they offer a rougher feel. Your cat isn't going to enjoy the paper towel much.
Clipping the fur around your cat's bottom is a worthwhile alternative to wiping. For instance, feces can become matted and difficult to remove with a wipe or paper towel.
If the cat's bottom is massively messy and hardened, your only option is a cat bath. You'll want to soak their rear end in the water before trying to remove all the mess. But please, make sure to use cat-designed shampoo and put on some rubber gloves.