During some recent American Congressional testimony, the NSA (National Security Agency) revealed that it had worked with Microsoft on security aspects of its recently released Windows 7 operating system. This caused a flurry of media attention, as various advocacy groups again raised suspicions that the NSA was possibly threatening the liberties of Americans by doing something secret that would somehow cause some kind of harm down the road. The bad stuff never seems to happen, but all that secrecy makes anything possible. This is especially true if you can get in front of a TV camera and announce some frightening possibility that no one can double check. The fact is, that the NSA is best qualified to point out to software manufacturers where weaknesses might be in software that communicates with the Internet. This is nothing new. For example, earlier this year, it was revealed that the NSA worked with the U.S. Air Force and Microsoft to develop a special version of Windows XP that had over 600 operating system settings shut down or modified so that hackers have a harder time penetrating air force network security. Some of it was simple stuff, like ensuring that the highest level password (the admin password, which gives you access to everything) can never be the same as a lower level (user) password. The system is also modified to have passwords expire every sixty days, forcing users to create new ones. NSA also assisted in preparing a special version of Windows 7, which the air force will begin to issue over the next year.
The NSA specializes in code breaking (cryptography) and SIGINT (Signals Intelligence). Since so much government work is done via the Internet, the NSA has developed expertise in protecting secrets in that arena, and methods for gaining access to what other nations are trying to hide. The NSA has been very successful doing what it does, since it was established over half a century ago. Before that, the predecessors of the NSA successfully cracked Japanese and German codes during, and before, World War II.
Because of the nature of its work (developing techniques for uncovering other nations secrets), the NSA cannot issue press releases announcing new successes. This would often let the enemy know they had a vulnerability the NSA was exploiting (and likely lead to that vulnerability being eliminated.)
But many older successes (where the methods used are no longer very secret) are now known. For example, during the Cuban Missile Crises of 1962, when Russia secretly (the NSA didn't catch it) moved ballistic missiles to Cuba, the NSA did successfully track the readiness of Soviet missile, naval and ground forces through the late 1962 events. This played a major role in avoiding an escalation to nuclear war, and defusing the situation.
In 1968, the NSA detected the communist preparations for the Tet Offensive. However, president Johnson, military commanders and the CIA discounted this warning, believing that the communists would not attempt such a suicidal attack. The communists did, took heavy losses, and suffered a major defeat, but scored a propaganda victory when the U.S. media declared Tet a communist victory.
In early 1975, the NSA detected North Vietnamese preparations for a conventional (infantry and tank divisions) invasion of South Vietnam. Again, American leaders discounted this as too aggressive (partly because the North Vietnamese had signed a peace treaty pledging to not do that sort of thing.) Again, communist duplicity and boldness resulted in victory.
In 1982, the NSA detected an unprecedented (since 1962) rise in the alert (readiness for combat) levels of Soviet ballistic missiles and conventional forces. This was a panic attack, based on misinterpreted information, within the Soviet leadership. The NSA warning enabled the U.S. to defuse the situation safely. There have been many similar NSA successes since the 1980s, but these are kept secret because the methods used are still effective, as long as the enemy doesn't know what you are doing.
One of the most underestimated of the intelligence agencies, the NSA still devotes most of its efforts to collecting and interpreting "signals intelligence" (messages sent regularly by radio, telephone, Internet and so on) information. More importantly, NSA develops ciphers (methods to encode secret American messages) and decipher the secret codes of other nations. The United States has always been very good at breaking codes, but doing that is only useful if the other guy doesn't know you have broken his codes. The NSA was established in 1952 as a secret agency, and it was decades before the government officially admitted that it existed. Thus all the secrecy at NSA is a long time custom within the organization.