Of course, "Envoys" had that little reference to Boimler knowing who Section 31 are, but I'm okay with just ignoring that as a cartoonish exaggeration that's not binding on canon.
Boimler went to the Academy from 2375 to 2379, so he joined just as the Dominion War was closing down (probably one of a large group of patriotic Federationists who signed up during the Dominion War, and its likely that the Academy lowered its TNG-era prerequisites to admit a larger contingent of citizens). I think its likely that Section 31 was exposed and blamed (rightfully) for the Founder virus and there part in ending the war. Starfleet (proper) and the Federation don't want that on their conscience, and they have a perfectly acceptable rogue organization to shove the atrocities onto.
So Boimler would've been learning about the recently exposed (and defrocked) Section 31 and still talking about them four years later, even if they had slipped into the shadows in the meantime. Heck, he may have studied under Academy Professor Miles O'Brien, who we all know spent the better part of an afternoon rummaging through a Section 31 agent's subconscious. O'Brien might be even more willing to talk about Section 31 and their mistakes to the next generation of Starfleet recruits, and they can't "stop him" or "take him out" because he's an untouchable Dominion War hero.