Lambda Legal and OutServe-SLDN, LGBTQ military advocacy groups, are suing the Defense Department over what they say is its “outdated” and “unconstitutional” policies involving HIV-positive service members.

“For over 30 years, the military has placed broad restrictions on the service of people living with HIV," says the lawsuit, filed Wednesday in U.S. District Court for the Eastern District of Virginia. "Military regulations prohibit the enlistment or commissioning of any individual living with HIV and place strict geographic limitations on the service of members who first test HIV positive while on active duty."

The Pentagon adopted a strict HIV policy in 1991, when AIDS was the No. 2 killer of men aged 25 to 44 in the U.S. The policy has been revised since, but not enough, according to Scott A. Schoettes, director of the HIV Project at Lambda Legal, which filed the suit on behalf of Nicholas Harrison, a sergeant in the District of Columbia Army National Guard who was denied an officer position.

“This is an instance of discrimination that has been longstanding, and it was finally time to make clear that we weren’t going to stand for this type of discrimination by our own government,” Schoettes told NBC News.

The suit, citing a military directive, says it is Defense Department policy to “deny eligibility for military service to persons with laboratory evidence of HIV infection for appointment, enlistment, preappointment, or initial entry training for military service.”

While the Defense Department declined to comment on the lawsuit, a spokeswoman said in an email to NBC News that active-duty service members with HIV are “evaluated and managed in the same manner as a service member with other chronic or progressive illnesses.” She also said the department's HIV policies "are evidence-based, medically accurate, and are reviewed regularly and updated."

The lawsuit also refers to a February Pentagon memorandum dubbed “Deploy or Get Out” by its critics. The memo states that “service members who have been non-deployable for more than 12 consecutive months, for any reason, will be processed for administrative separation.”

Schoettes said this policy will make it “next to impossible for people living with HIV to continue to serve.”

“The military considers by default everyone living with HIV non-deployable,” Schoettes explained, adding that the policy “could end up kicking out all of the people currently serving who are living with HIV.”

Sgt. Nicholas Harrison Salma Mohammed and Lambda Legal

Harrison, 41, joined the military when he was 23 and has served two tours of duty in the Middle East. He diagnosed with HIV in 2012, around the same time he passed the bar exam.

Harrison was confronted with the military’s HIV policy a few years later, when he was denied an officer position in the Judge Advocate General Corps, the division of the military that handles legal matters.

“I have always wanted to be an officer since I’ve been in the military,” the Oklahoma native told NBC News. “One of the values that’s been instilled in me is taking care of soldiers.”

Harrison said he was “very surprised” when he was not granted the opportunity to serve as a JAG officer and called the HIV policy “outdated,” saying it “doesn’t take into consideration current medical research.”

“There really isn’t any reason for someone who has this medical condition to be discriminated against in this society,” he added. “HIV isn’t what it was when it was first discovered in the ‘80s. It’s no longer a death sentence.”

Perry Halkitis, dean of the Rutgers University School of Public Health, agreed. He said the military’s HIV policies are still “rooted in the stigma of the ‘80s.”

“Decisions are being made about HIV that have nothing to do with the current state of science,” Halkitis told NBC News.

Harrison's lawsuit, which lists the Defense Department, Defense Secretary Jim Mattis and Army Secretary Mark Esper as defendants, seeks to have the Pentagon lift restrictions placed on service members because of their HIV status and commission Harrison as a JAG officer for the D.C. National Guard.

FOLLOW NBC OUT ON TWITTER, FACEBOOK AND INSTAGRAM