The plea deal given to former CIA director David Petraeus, which will allow him to skip prison time despite leaking military secrets to his mistress and biographer Paula Broadwell, highlights a “profound double standard” in the Obama administration’s treatment of whistleblowers, a lawyer for an imprisoned government contractor wrote in a letter to federal prosecutors on Monday.

The Justice Department should immediately release former State Department contractor Stephen Kim from prison, wrote Abbe Lowell, who represents the whistleblower sentenced to 13 months for disclosing classified information about North Korea. His letter was provided to the New York Times by Kim’s sister, Yuri Lustenberger-Kim.

“The decision to permit General Petraeus to plead guilty to a misdemeanor demonstrates more clearly than ever the profound double standard that applies when prosecuting so-called ‘leakers’ and those accused of disclosing classified information for their own purposes,” Lowell wrote in his letter to Attorney General Eric Holder.

Kim was charged under the Espionage Act in 2010 for unauthorized disclosure of national defense information, as well as a separate count of making false statements, stemming from allegedly telling Fox News reporter James Rosen that North Korea was planning a nuclear bomb test in 2009.

In 2014, Kim pleaded guilty to one felony count of disclosing classified national defense information to an unauthorized person. According to Lowell’s letter, Kim’s legal team sought a plea deal with the Justice Department similar to the one that Petraeus was given, but were rejected by federal prosecutors.

“The reasons that you provided to refuse our misdemeanor offer were grounded in motive and lying to the FBI,” Lowell wrote. “There is no difference between the two cases in that respect. (If anything, General Petraeus’s motive was far less noble.)”