The NSA has tried to backdoor Linux three times (2016)
reddit.com
reddit.com
Assuming Linus was being serious and not facetious, I would say that's one attempt. And if the NSA really wanted Linus to backdoor his kernel, I imagine they would have approached him in-person and asked (as they have been known to do), so I'm not convinced that the two other attempts were them either.
I don't assume all NSA spies are smart enough to think like that and sometimes NSA code may be a dead-giveaway, but I do assume that at least some of them are, for the more important/bigger backdoor projects.
You can also look at NSA's history with IPSec, or the more recent Simon & Speck situation, where they pushed forward their own design that at first glance might seem fine, but if you tried to push them on the details, they would stonewall you.
The NSA made design alterations to DES to make it more resistant to DCA. However they didn’t publish those design decisions because they would reveal the existence of the technique, which at the time was applicable to many other ciphers including nearly all Soviet ciphers.
The NSA didn’t backdoor DES the key shortening and the addition of parity bits was an attempt to make it more resilient to DCA while making it only slightly more susceptible to brute force attacks.
It’s also important to note that DES was a 1970’s cipher which survived long enough to be relevant, even a 1080ti would take 2 or more days to crack a single DES key and its considerably more powerful than likely all the super computers in the world combined in say 1983.
The NSA isn’t your friend for sure but they know exactly what they are doing.