Snares are cable nooses often hung along fences or over narrow pathways traveled by coyotes and foxes—pathways that might also be attractive to dogs. Once an animal's head and neck pass through, the cable cinches tight and the result is suffocation.
There are several things that can be done to release a dog from a snare. It's always a good idea to cover the dog's head to calm it and restrain it from biting you. The more an animal struggles in a snare the tighter the noose will get.
Try to relieve the tension on the snare by removing the stake or post to which it is attached or move the animal closer. A pair of lineman's pliers or heavy duty cable cutters could be lifesavers and might be a good thing to include in your hiking pack (a Leatherman-style tool or normal wire cutters will not be strong enough to cut through steel cable).
After the dog has been restrained, feel through its fur for the cable and use the diagonal pliers to cut the cable—this is not as easy as it sounds especially with a heavy gauge cable.
A second option is to find the locking device, a metal piece that keeps the snare from losing its loop, and push or pull back on this (the pliers can be useful for this as well). It may seem counterintuitive to pull back on the lock and the cable connected to it as it pulls the noose tighter, but once you've done this it will make it easier to loosen the snare.