"Having" is the grammatically proper phrase. Gerunds make the phrase a noun phrase, while the bare verb makes it a verbal phrase, and "afraid of" usually takes a noun phrase. The "and" makes "afraid of" apply to both phrases.
He's afrad of [noun phrase] and [noun phrase]
He's afraid of being debunked in public and having his reputation ruined
Compare this to "afraid to" which takes a verbal phrase:
He's afraid to get debunked in public and have his reputation ruined.
I'm not exactly sure why I see the "and" makes it necessary to parallelize the phrases. Also I'd like to note that in this particular case, both seem decently natural, even if not 100% idiomatic. Nobody is going to notice anything odd if they hear these sentences, because they won't notice that you've essentially made the ungrammatical phrase "afraid of have ...".
However, for shorter sentences, it's way worse. For example, one colloquial phrase I've heard a few times is "going and getting".
Have you thought about going and getting your wisdom teeth removed.
In this case, because the phrase is so short, it's very obvious that "about" is applied to "getting you wisdom teeth removed", so replacing "getting" with "get" would sound very unnatural.
4I think you got it right, grammatically, but I would understand it as he's afraid of one thing: "being debunked in public and (consequently) having his reputation ruined". – Damkerng T. – 2015-11-14T00:42:27.357