It might be conceivable that a cat could be allergic to something in a cat litter like fragrance. But get an infection from the litter? I don't believe so.
Now if the litterbox is full of feces, and a cat has an open sore, then infection might be something to think about. But they keep themselves so clean that it's not usually thought of as any sort of danger.
He's just cleaning himself- cats spend a huge percentage of their time grooming. Totally normal.
Once in a while a cat might get a nail bed infection or an ingrown claw, or a cut pad. Look at his feet- in the pads, extend all the nails, etc. If you don't see anything unusual then don't worry about it.