President Barack Obama salutes a US Marine on the White House lawn, on March 30, 2012. The US president is the commander-in-chief of the American armed forces.
The Marine Corps on Wednesday discharged a sergeant for criticizing President Barack Obama on Facebook.
Officials said Sgt. Gary Stein will be given an other-than-honorable discharge for violating Pentagon policy limiting speech of service members, The Associated Press reported.
More from GlobalPost: Marine sergeant faces dismissal over anti-Obama Facebook posts
The San Diego-area Marine has served nearly 10 years in the Marine Corps. He has said he was exercising his free-speech rights.
The discharge will mean he loses all military benefits, according to the AP.
Stein is accused of undermining "good order and discipline" by posting comments critical of the commander-in-chief on a number of Facebook pages. According to the Los Angeles Times, he called Obama a coward and an enemy and urged people to vote against him in this year's election.
More from GlobalPost: Michelle Obama accepts invitation to Marine Corps ball
He also stated he would not follow orders from the president if he considered them "unlawful."
Military prosecutors said Stein posted pictures of movie posters altered to feature the president's face, including one for "Jackass" and another for "The Incredibles" which he changed to read "The Horribles," the AP reported.
A federal judge on April 14 denied a request to block military discharge proceedings against Stein, ABC News reported.
Under US military law, uniformed personnel are forbidden from talking "contemptuously" of their superiors, or from speaking publicly for or against a political candidate or cause.
We want to hear your feedback so we can keep improving our website, theworld.org. Please fill out this quick survey and let us know your thoughts (your answers will be anonymous). Thanks for your time!