|In the 12th century, someone, e.g. Averroes, began to circulate the theory that Moses, Jesus, and Muhammad were three "impostors", each of their respectively founded religion: Judaism, Christianity, and Islam; in the 18th century, hoax treatises, e.g. using Spinoza publications, and responses, e.g. by Voltaire, to the hoax treatises began to appear.|
Theory | View
The view that each of the three great religious leaders had tricked their followers and were not an agent of the divine traces to the publications of: Averroes (c.1180), Frederick II (c.1235), Pietro Pomponazzi (c.1510), and the Anon Theophrastus (c.1659). 
Book | Treatise
In c.1190, Simon of Tournai (1130-1201) was accused of having penned a treatise on the three impostors. (Ѻ)
In 1239, Pope Gregory IX, without offering any evidence of any kind, asserted that Frederick II (c.1235) penned a book entitled Treatise on The Three Impostors, in which he denounced the three prophets. 
In c.1560, Bernardino Ochino (1487-1564) was charged with being the "author" of the Three Impostors Treatise. (Ѻ)
In c.1615, Lucilio Vanini was purported to have brought to light again the book entitled Of the Three Impostors. 
In 1719, a book titled The Life and Spirit of Spinoza contained the “three impostors legend” outlined in the second half the book. 
In 1770, Voltaire, published a response to the hoax treatise entitled Epistle to the Author of the Book of the Three Impostors (Épître à l'Auteur du Livre des Trois Imposteurs) (Ѻ), which contains one of his best-known quotations, "If god didn't exist, it would be necessary to invent him."
The following are related quotes:
“Frederick II, this pestilent king, a scorpion spitting out poison from the stinger of his tail, has notably and openly stated that—in his own words—the whole world has been fooled by three imposters, Jesus Christ, Moses, and Muhammad, two of whom died honorably, while Jesus himself died on the cross. Moreover, he has dared to affirm, or rather, he has fraudulently claimed, that all those who believe that a virgin could give birth to the god who created nature, and all the rest, were fools. And Fredrick has aggravated the heresy by this insane assertion, according to which no one can be born without having been conceived by the prior intercourse of a man and woman; he also claims that people ought to believe nothing that cannot be proven by the strength and reason of nature.”— Pope Gregory IX (1239), address to monarchs
1. Hecht, Jennifer M. (2003). Doubt: A History: The Great Doubters and Their Legacy of Innovation from Socrates and Jesus to Thomas (pgs. 332-33). HarperOne.
2. Minois, Georges. (2009). The Atheist’s Bible: the Most Dangerous Book that Never Existed (translator: Lys Weiss). University of Chicago Press, 2012.
3. (a) Arpe, Peter F. (1712). An Apology for Julius Caesar Vanini, a Neapolitian (Apologia pro Julio Caesare Vanino, Neapolitano). Philalethes.
(b) Durand, David. (1714). The Life of Lucilio (alias Julius Caesar) Vanini: Burnt for Atheism at Toulouse with an abstract of his writings being the sum of the atheistical doctrine taken from Plato, Aristotle, Averroes, Cardano and Pomponazzius's philosophy with a confutation of the same; and Mr. Bayle's arguments in behalf of Vanini completely answered (Amz) (pg. 101-02). Publisher, 1730.
● Andersen, Abraham (1997). The Treatise of the Three Imposters and the Problem of the Enlightenment. A New Translation of the Traité des Trois Imposteurs (1777 Edition). Rowman & Littlefield, 2000.
● Treatise on the Three Impostors – Wikipedia.