"Gen. Alexander's just done a phenomenal job," Hagel told Foreign Policy. "He is one individual who is capable of doing that job the way he did it at a very difficult time, and he deserves great credit."
Hagel also said that the NSA has been doing a great service to the country and has been operating within the law.
"Everything our intelligence community has been doing has been within the scope of the law," Hagel said. "It's a dangerous world. Intelligence is critically important, it saves lives, it is as critical a component of our national security as anything."