Cacti with long and relatively fat spines are not the worst to handle. You may get a few pricks, but they soon heal. Cacti with lots of very thin "hairs" (e.g. many Opuntias) are much worse, because the hairs break off and stay in your skin until your skin naturally renews itself!
Get some industrial gloves, for example those used by builders. Gloves intended for household cleaning etc are not much use, because sharp spines just pierce through them.
Cloth is also fairly useless, unless you have a thick "fleece" that is too thick for the spines to pierce right through it.
The best way is to work out how to touch the cactus as little as possible. For example you can lay the pot on its side on a bench and remove the pot, keeping the soil around the root ball pretty much intact. Then handle the plant as much as possible by the roots. Moving the plant about without getting "attacked" is not a big problem so long as you don't have to support its whole weight, so work with it resting on a bench or in a pot (so you can hold the pot, not the plant.) It's quite possible to repot a cactus with the plant and pot horizontal, not vertical, and then turn it vertically to make the final adjustments. Unlike most plants, cacti aren't floppy, and pieces don't easily break off!