Yep, it's the anal glands! There is nothing quite like the smell of "butt juice"

as my DH calls it. It is enough to make me want to jump out of a running vehicle when on the road with Neo!
The best way to deal with this is let the vet do it, because the inexperienced or rough hands can do more damage than good.