WASHINGTON — President Donald Trump signed a memo Friday that bans any new transgender men or women from joining the military, but also leaves it to Secretary of Defense Jim Mattis to determine the fates of transgender service members currently in uniform.

Trump's directive also covers the Department of Homeland Security, to include the Coast Guard. 

The presidential memo, which Trump has transmitted to the Pentagon, contained three major guidelines.

First, it directed that the Pentagon maintain a ban on any new accessions of transgender personnel into the military. Second, it halted the use of any Pentagon or Department of Homeland Security funds for sex reassignment surgery. Third, it directed Mattis to determine whether transgender personnel currently in uniform should be allowed to stay.

A senior administration official who briefed reporters late Friday on the contents of the memo said Trump directed Mattis to use the criteria of a transgender service member’s impact on military effectiveness, lethality, unit cohesion and impact on budgetary resources.

But the official could not describe how a service member should be evaluated, for example, for his or her impact on the budget.

Pentagon officials did not provide any additional information Friday.

"The Department of Defense has received formal guidance from the White House in reference to transgender personnel serving in the military. More information will be forthcoming," Pentagon spokeswoman Dana White said in a statement.

There are some exceptions to the ban on funding for sex reassignment surgery. Payments will continue when there is determined to be an “exception to protect the health of an individual that has already begun the course of treatment,” the official said.

Mattis has until March 2018 to grant exceptions to the funding ban and also to determine the fate of transgender personnel now serving, the White House said.

It was not clear what the ban on accessions would mean for a small number of transgender cadets who have either graduated from or are currently enrolled in the service academies.

Advocacy groups are already blasting Trump’s decision.

"The president’s order to remove transgender service members from the United States armed forces and deny them health care is nothing less than a purge,” said Matt Thorn, executive director of OutServe-SLDN, in a statement.

OutServe-SLDN is the largest non-profit, legal services, advocacy and policy organization dedicated to bringing about full LGBT equality to America's military, the group says on its website.

Thorn went on to call the memo “a discriminatory attack on the people who have volunteered their lives for the defense of the country.”

The group said it plans to file a federal lawsuit to challenge the policy change.

The president signed the memo one month after announcing in three tweets his plan to change the military’s transgender policy.

At the time, the announcement came as a shock to the “vast majority” of Pentagon leaders who had no idea the policy change was coming, a government official said.