One rather sophisticated rig described on Snopes.com has two parts. One is a snap-on card reader that fits over the ATM machine's real card reader. As your card is inserted into the ATM, it passes over the thief's reader first, and the digital info on the mag stripe is captured. A pinhole camera mounted in the seemingly-innocuous deposit envelope holder records your PIN. With this info, the criminal can make himself a duplicate card and help himself to the your account.
Another even more elaborate scam was operated by a gang uses a real ATM. They obtained 50 real ATMs, arranged so that they could be used for real transactions, then installed them in stores and other public places on both coasts. When people used one of these ATMs, the crooks obtained their card info and PIN, which they then used to make duplicate cards for withdrawls of their own.
Fortunately, such elaborate measures are rare so far in the electronic age, but it would behoove you to look around before you make a withdrawl. If you spot any camera lens other than the ATM machine's one, I'd drive away. I'd also grab the card reader and jiggle it a little to make sure it's not a fake. I'd also be very reluctant to use any ATM other than my bank's. Better to be cautious than sorry!