The administration’s attorneys determined that only parents who had been in the United States since Jan. 1, 2010, and had a qualifying child as of Nov. 19 would receive a temporary reprieve. (Ross D. Franklin/AP)

As senior Obama administration officials worked behind the scenes for months this year to develop the legal rationale for deferring the deportation of millions of undocumented immigrants, there was one group they wanted to include that presented particular problems: the parents of “dreamers.”

The dreamers, in the eyes of many advocates, were an especially sympathetic group, children who had been brought into the country illegally and had been granted temporary relief under the president’s 2012 Deferred Action for Childhood Arrivals program, or DACA. Now these advocates were saying the parents deserved similar relief as well.

The administration sought a way to include them, but lawyers from the Department of Homeland Security, the Justice Department and the White House examined the legal arguments and decided against it.

“We looked at this pretty hard,” one senior administration official said in an interview last week, speaking on the condition of anonymity to discuss internal ad­ministration deliberations. “We hoped to come up with a rationale that would work but concluded that we couldn’t.”

A lawyer briefed on the administration’s internal debate said that when it came to that category, “some of the policy people were pushing too hard to do things the lawyers thought were questionable.” Ultimately, the lawyers won.

The decision to exclude the parents of dreamers — along with all agricultural workers and H-1B visa seekers — from President Obama’s executive actions announced Nov. 20 highlights the legal and political challenges the administration is navigating as it aims to curb the ongoing deportation of illegal immigrants. The president has faced criticism from all sides on the issue, with conservatives accusing him of giving amnesty to lawbreakers and immigration advocates decrying what they see as excessive deportations.

Operating in an arena that is typically shielded from judicial review, federal government lawyers have tried to broaden the number of people who can stay in the United States while shying away from the kind of overreach that could give Congress grounds to overrule the policy.

The executive-action changes have drawn sharp rebukes from GOP lawmakers. In a recent interview, Rep. Paul Ryan (R-Wis.) called the move “an act of nullification” that oversteps the president’s authority. But some of the finer legal distinctions drawn by the administration aim to blunt that criticism and keep the policy in place.

The administration’s legal reasoning for its actions is laid out in a 33-page memo issued Nov. 19 by the Justice Department’s Office of Legal Counsel — a road map to the choices Obama’s deputies made along the way as they navigated contested legal terrain.

At the heart of the administration’s justification is the idea of prosecutorial discretion. The memo is full of references to historical and judicial precedents intended to bolster the idea that the president had some discretion in deciding which illegal immigrants should be expelled from the country and which should be protected from deportation, but it also acknowledges that the sustainability of such a policy rests in the political arena.

“And because the exercise of enforcement discretion generally is not subject to judicial review . . . neither the Supreme Court nor the lower federal courts have squarely addressed its constitutional bounds,” states the memo. “Rather, the political branches have addressed the proper allocation of enforcement authority through the political process.”

There was broad agreement among Obama’s lawyers that he had the authority to expand the deferred program to parents of U.S. citizens and legal permanent residents. David Rivkin, a senior legal official in the Reagan and George H.W. Bush administrations, called that unanimity and lack of debate “stunning.”

In a prime-time address on Thursday President Obama announced his plan to use his executive authority on immigration policy, protecting millions of illegal immigrants from deportation. (AP)

“The reason you go to the Office of Legal Counsel is because it’s a difficult issue, because there are disagreements among agencies and departments,” Rivkin said. “It’s an indication of the fact that the OLC opinion was made to order.”

But David Strauss, a constitutional-law expert at the University of Chicago, said the process played out exactly as it should have. “It’s the way conversations often go between lawyers and clients,’’ he said. “The client says: ‘Here’s something I’d like to do. I think it’s appropriate. What do you think?’ And if the lawyer says, ‘I’m sorry, you can’t do it,’ the client says, ‘Okay, that’s why they hired you.’ ’’

Both of Obama’s previous actions, and some undertaken by past presidents of both parties, offered a partial legal basis for the administration’s action. Presidents dating to Dwight D. Eisenhower have granted relief to immigrants who otherwise would have been vulnerable to deportation. Republicans, however, argue that those actions were on a much smaller scale.

In terms of prioritizing which immigrants should be removed from the country, Congress had already placed criminals at the top of the list. In addition, it had recognized that there is a humanitarian justification for keeping families together — this serves as part of the basis for why the relatives of legal immigrants get a higher priority in terms of their visa applications. So both of those directives made it easier for government lawyers to make the parents of U.S. citizens and legal permanent residents eligible for a deferral.

More broadly, on multiple occasions in the past, the government has allowed individuals out of compliance with U.S. immigration rules — including thousands of foreign students who were stranded here after Hurricane Katrina in 2005 and relatives of those killed in the 9/11 attacks — to stay in the country.

But the administration’s lawyers also made some arbitrary distinctions as they ruled which parents would be eligible for the new deferral program. They determined that only parents who had been in the country since Jan. 1, 2010, and had a qualifying child as of Nov. 19 would be granted a temporary reprieve, a similar time requirement to DACA applicants, who also have to have been in the country for at least five years to be eligible for a deferral.

And while they did not start with a specific number of people who would be eligible for deferrals, they also worked to ensure that the program didn’t encompass numbers that it would look as if the president was defying Congress outright. The memo notes that “while the potential size of the program is large, it is nevertheless only a fraction of the approximately 11 million undocumented aliens who remain.”

“We looked at what was within appropriate prosecutorial discretion and then did a tire kick to see where this would end up,” said the senior administration official.

In the case of parents of DACA children, the memo provides two primary reasons for denying them preferential status. First, even though DACA recipients are not being deported at the moment, “they unquestionably lack lawful status in the United States.” Second, doing so “would represent a significant departure from deferred action programs that Congress has implicitly approved in the past.”

Marketa Lindt, a partner at Sidley Austin who serves as national secretary of the American Immigration Lawyers Association, said in an interview Tuesday that the decision to exclude this group reflected the fact that “it’s a category that’s hard to sell politically.”

“There’s no legal bar that I can think of to that provision,” she said. “If the executive branch has the authority to give work benefits to people who arrive at a certain age, there’s no different legal foundation to giving the benefits to the parents of those people.”

Two other groups — agricultural workers and highly skilled foreigners seeking H-1B visas — are left out of the program. Senior administration officials said that one could make an economic, rather than humanitarian, case for keeping them in the country, but that would again mark a change from previous deferred-action programs.

While Rivkin said he thought deferred action for illegal immigrants “is not a bad policy exercise,’’ he found the way the administration went about it to be “utterly and totally illegal. . . . This is not prosecutorial discretion, it is the president rewriting the law.’’

Walter Dellinger, a Washington lawyer who served as U.S. solicitor general in the Clinton administration, strongly disagreed. “I never had any doubt that the president has significant discretionary authority over setting deportation priorities. This authority flows from acts of Congress,’’ said Dellinger, who added that he thought the Office of Legal Counsel opinion was “very carefully reasoned.’’

One of the provisions the Justice Department lawyers included, which they also pushed for during the creation of the 2012 program, was to make clear that federal immigration officials would still have the option of deporting individuals who might otherwise qualify for a deferral. The memo states that the new policy “provides for case-by-case determinations about whether an individual alien’s circumstances warrant the expenditure of removal resources, employing a broad standard that leaves ample room for the exercise of individual discretion by enforcement officials.”

“I think of it as a group that is entitled to apply, but I don’t consider it a group that’s entitled to relief,” said the senior administration official.

That legal uncertainty, Lindt said, has already deterred many people from applying for a deferral under DACA and will probably have the same impact on this newly eligible group.

“It’s very much the case that people will be very nervous about coming forward,” she said.

Even with these legal distinctions, administration officials remain confident that plenty of people will apply under the new program. They noted that even though the latest executive action does not specifically aid farmworkers and dreamer parents, a significant percentage of those individuals would still be eligible to apply for a deferral because they happen to be parents of a U.S. citizen or legal permanent resident. The administration is also still reviewing whether there are ways to expand the H-1B visa program.