The Cunning Man was, a thousand years ago, an Omnian witch-finder, who had become infatuated with (and 'fascinated by') a powerful, young witch (as revealed by Eskarina Smith), a situation of opposites that he could not reconcile. That witch, however, knew how evil the Cunning Man was. She was eventually burnt to death - not coincidentally by his co-religionists, but as she was being burned she reached through her bars and held him to her, trapping the Cunning Man in the fire as well. He survived, but his mind snapped. After his death, years later, The Cunning Man became a demonic spirit of pure hatred, able to corrupt other minds with suspicion and hate.
This spirit seems to do a perpetual tour of the Multiverse, appearing at random intervals of a few human generations to spread fear and loathing, hatred and mob violence against targets of convenience, like Witches. On Discworld, he appears as a man (or humanoid shape) dressed in black clothing with a wide-brimmed black hat. There are no eyes in the featureless black face, only holes that lead all the way through to the back of the head, and the black-clad black body casts no shadow in direct sunlight. When he encounters the objects of his aggression, he attacks them with fulminating vituperation; otherwise, he operates in the subliminal domain, persuading the general population toward suspicion, hatred and violence against the objects of his own rage: Witches. The Cunning Man functions as a demonic spirit of pure rage, specifically against witches. He hates them simply for existing, and infects others with his hatred. His presence in the vicinity can be detected by those with knowledge of magic by his 'smell' (simply for lack of a better description). His hatred is so intense that it surrounds him like an aura and the minds of others, not knowing how to classify it, catalogue it as a foul stench of rot, powerful enough to turn the stomach.
Rather like the Hiver, the spirit of the Cunning Man is capable of occupying a human body to carry out his agenda. It searches out the malicious as, in the words of Mrs Proust, "poison will go where poison's welcome". In I Shall Wear Midnight, he takes the body of the depraved killer, Macintosh, from the Tanty in Ankh-Morpork, and drives it to the Chalk in search of Tiffany Aching; like the young Witch he had become infatuated with a millennium ago, Tiffany is the leading witch of her generation, and the Cunning Man is motivated by, both, his desire to be united with the object of his infatuation (needing a powerful witch to fill the role), and by his own desire to possess a witch's power (by taking a witch as a host), something that Eskarina Smith describes that, should it ever happen, would be, to the Cunning Man's mind, something akin to a wedding.
Poisoning people against witches is quite easy to accomplish as they, by their nature, focus on doing the right rather than the popular thing (which is probably why the witch that the Cunning Man had fallen infatuated with didn't use her magic to try to escape at the risk of hurting innocents), and are thus always at risk of a backlash. The Cunning Man’s poison complicates Tiffany’s dealings with the dying Baron of the Chalk, his son, Roland, and Roland’s new fiancée, the Lady Letitia Keepsake, and many other people whose respect she has come to take for granted. Despite the fact that the vitriol stirred up against her leads to her imprisonment (in the dungeon of the castle, with the goats) she manages, with (or perhaps despite) the help of the Nac Mac Feegle, to face the Cunning Man, without requiring the help of veteran witches Granny Weatherwax and Nanny Ogg (who would have had to kill her if the Cunning Man succeeded in possessing her).
Tiffany, fortunately, knows why the hare runs into the fire; the Cunning Man's cunning does not go that far. As Granny Weatherwax did many years before ( who also was once a young witch, but now still a powerful one), Tiffany destroys the latest manifestation of the Cunning Man; he will, sadly, be back.
The Cunning Man is possibly based on the Roundworld historical figure Heinrich Kramer, a German Inquisitor, although there has been a long tradition of the phrase "Cunning folk" in parts of England and Wales. Certain Christian theologians and Church authorities believed that the cunning folk, being practitioners of "low magic", were in league with the Devil and as such were akin to the more overtly Satanic and malevolent witches. Partly due to this, laws were enacted across England, Scotland and Wales that often condemned cunning folk and their magical practices, but there was no widespread persecution of them akin to the Witch Hunt, largely because most common people firmly distinguished between the two: witches were seen as being harmful and cunning folk as useful.