One way to make squats safer is to use a Smith machine.