All that the NSA needs is a security hole. They can generate them by submitting reasonable code whose misbehavior is hard to spot, like http://www.underhanded-c.org/, or by searching for holes that already exist in the wild. And if you wind up putting a proprietary driver into your computer and they got a hole in the driver, you do even better.
Given the NSA's resources and the rate at which groups like Project Zero find bugs, they certainly have multiple ways in to any system that they want.