Although Eliot Ness and his high profile raids are popularly linked with the downfall of Chicago Outfit head Al Capone, it was actually the more anodyne work of IRS accountants/tax agents like Frank Wilson that actually resulted in Capone's conviction and imprisonment on tax evasion charges.
This movie is loosely based on Frank Wilson's story.
The film deviates from noir storylines by avoiding the true bleakness of real life events.
In real life although Capone was convicted and later sent to Alcatraz, the organization that he inherited and built thrived without him, growing to wield national influence, including in Hollywood and Las Vegas.
Capone's conviction did not prove that good would win over evil. It just showed that mobsters needed to pay their taxes and keep a lower public profile, a valuable lesson that Capone's successors took to heart.
Nevertheless The Undercover Man still effectively used noir elements of claustrophobic corruption and frustration with the law. Although everyone at the time would have recognized the Capone story, this movie set its tale in an unnamed city. As Tolkien did with Sauron, the film keeps its Big Bad (Capone) off screen for 99% of the story.