Petting was the act of stroking an animal, particularly a pet, with one's hand as a demonstration of affection.
In 2152, Doctor Phlox assured Jonathan Archer it was okay to pet Porthos while the dog was in isolation, provided he wore surgical gloves while doing so. (ENT: "A Night in Sickbay")