BRIDGEPORT - (AP) -- A U.S. Navy sailor has been sentenced to a year in prison for taking photos of classified areas inside a nuclear attack submarine while it was in port in Connecticut.

Kristian Saucier, of Arlington, Vermont, was sentenced Friday in federal court in Bridgeport.

Saucier pleaded guilty in May to unauthorized detention of defense information.

He also must serve six months of home confinement.

Saucier compared his case to Democratic presidential nominee Hillary Clinton's use of a private email server when she was secretary of state. The FBI declined to charge Clinton for her handling of classified information while using the server.

Saucier took six photos inside the USS Alexandria in 2009 when it was in Groton. The photos were on a phone that was found at a waste transfer station in Connecticut.