From the Document: "A legislative requirement for the offices of the U.S. government to be located in the District of Columbia dates to 1790. The applicable provisions have been codified in 4 U.S.C. 71 and 72. Although no definition of 'offices' is provided in Title 4, it appears that, at a minimum, the main offices of executive departments are required to be located in DC proper unless a statutory waiver is granted. The headquarters of the Department of Defense and the Central Intelligence Agency are located in Virginia, and the Nuclear Regulatory Commission is in Maryland. All these agencies received statutory exemptions from the location requirement. The U.S. Naval Security Station, which is located at Nebraska and Massachusetts avenues in northwest Washington, DC, and is also known as the Nebraska Avenue complex, is the initial home for the Department of Homeland Security (DHS)."
CRS Report for Congress, RS21390