Snake away contains napthalene which is ground up moth crystals. It should repel the dogs and cats away from it. Just to be safe, I would keep them away. As far as safety goes, it is a chemical and is not safe to eat or digest. It would make them sick.
We have never had a report of any issues with pets and Snake Away. Used as directed, it really is a good product and one of the few available for snake control.