A U.S. sailor who planned to give a journalist classified information about the Navy’s nuclear-powered warships and then defect to Russia, was recently sentenced to three years in prison, officials said Friday.

U.S. Navy Petty Officer 2nd Class Stephen Kellogg III pleaded guilty to two counts of espionage earlier this month and admitted to contacting Sevmash, a Russian shipbuilding enterprise. In an email to the ship maker, he wrote: “I am willing," the FBI said in a statement.

The 26-year-old also admitted to authorities that releasing the classified information could degrade the ability of nuclear-powered warships and cause injury to the United States, Jeff Houston of the Naval Criminal Investigative Service in an email to The Associated Press. As a nuclear electrician’s mate, Kellogg had access to information related to the capabilities, operations and maintenance of nuclear propulsion systems.

TRUMP WEIGHS PARDONS FOR SERVICEMEMBERS ACCUSED OF WAR CRIMES, AS FAMILIES AWAIT DECISION

Had the information became public, potential U.S. adversaries could have learned the capabilities and limitations of the United States’ nuclear-powered warships, a pre-trial statement said.

“This sailor’s attempts to disclose classified Navy nuclear propulsion information posed a significant threat to national security and endangered the lives of American service members,” FBI Special Agent in Charge Garrett Waugh.

Authorities learned of the plot after Kellogg was arrested on Aug. 27 for drunken disorderly conduct at a San Diego airport where a Delta Airlines employee stopped him from boarding a flight to New York.

He was being belligerent and had purchased a one-way ticket to visit a high school friend who works as a journalist, telling him he had a big story, court documents said. Kellogg joined the Navy in 2014 and served on the U.S.S. Carl Vinson from 2016 to 2018.

In July and August 2018, Kellogg search online for flights to Moscow and contact information for the Russian Consulate in San Diego, the FBI said.

CLICK HERE TO GET THE FOX NEWS APP

The FBI said Kellogg admitted to taking photographs of areas containing sensitive information about the Navy’s nuclear propulsion program on the ship. He then sent the photos to his father and girlfriend.

He will receive a reduction in rank and a dishonorable discharge, the FBI said.

The Associated Press contributed to this report.