The Espionage Act of 1917 was a United States federal law that aimed to prohibit interference with military operations, support for U.S. enemies during wartime, and the promotion of insubordination in the military. This legislation arose during World War I, reflecting the government's desire to maintain national security and suppress dissenting opinions that could undermine the war effort.