I remember the early search engines of the Internet very well. The old Yahoo! directory. AltaVista. HotBot. Lycos. Suddenly they were driven into obscurity by Google, which literally overnight became a verb for "searching the Web."
It's quite plausible that the government realized early on that of all the search engines, Google had the secret sauce by which to quickly capture and organize the information of the world.
If so, not a bad deal for Sergey and Brin who get to skateboard down the corridors of their giant company with an unlimited amount of money to come up with silly stuff like Google Glasses and cars that drive by themselves.