I've seen this happen a few times but the one with the most notoriety is the South Park episode "Trapped in the Closet". That's the episode where they basically make fun of Scientology.
Both because of Scientology's litigious nature and the fact that some of the things in the episode come from copyrighted Scientology materials of contentious origin (namely Xenu), they end the episode with Stan taunting Scientology to sue him
Followed immediately by the closing credits, where every single name is either "John Smith" or "Jane Smith"
Part of the gag here of course is that Scientology can't sue the makers of South Park if they don't know who they are. Even Matt Parker & Trey Stone's names are replaced.
Is this just a gag or does this sort of thing afford any actual legal protection? It's not like it's a big secret who works on South Park and it's not like it would be difficult to figure out who worked on most of the episodes in that season, but does the fact that their names aren't actually attached to the episode have any actual legal basis?
As far as I can tell the Church of Scientology has never pursued any legal action against the creators of the show or Comedy Central outside of just generally not being a fan of the episode so either it worked as a legal tactic or Scientology didn't want to keep it in the limelight any more than necessary.
But I've also read that one of the old reasons actors in pornography often use pseudonyms is for legal protection - it's not unprecedented apparently to be arrested because you've run afoul of some obscure decency law somewhere (it also gives them a bit of an escape hatch should they want to leave the adult industry and move on to an anonymous rest of their lives)
Can using fake names or pseudonyms in the credits really protect you from legal troubles?