ORLANDO, Fla. — The Department of Homeland Security is agreeing to share citizenship information with the U.S. Census Bureau as part of President Donald Trump's order to collect data on who is a citizen following the Supreme Court's rejection of a citizenship question on the 2020 Census form.

Trump's order is being challenged in federal court, but meanwhile, the Department of Homeland Security two weeks ago announced the agreement in a report. It said the agency would share administrative records to help the Census Bureau determine the number of citizens and non-citizens in the U.S., as well as the number of immigrants in the U.S. illegally.

Information to be shared includes personally identifiable data, the Homeland Security document says. Federal law prohibits the Census Bureau from releasing personally identifiable data, and the bureau says in its fact-sheet on privacy, “Your answers can only be used to produce statistics — they cannot be used against you in any way.”

The Census Bureau has promised the data will be kept for no more than two years, and will then be destroyed, according to the agreement. The data will be used to help the Census Bureau create a model estimating the likelihood that each person in the U.S. is a citizen, non-citizen or an immigrant in the country without legal permission.

Among the information Homeland Security will provide is a person's alien identification number, country of birth and date of naturalization or naturalization application. The department is awaiting word on whether it will be allowed to release information on asylum and refugee applicants, which typically is prohibited from being disclosed.

Because a person's citizenship status can change often over time, the citizenship data provided by Homeland Security will likely be inaccurate, said Andrea Senteno, an attorney for the Mexican American Legal Defense and Education Fund, one of the civil rights groups challenging Trump's order in federal court in Maryland.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

“The information out there over whether someone is a non-citizen or what type of immigrant status they may be is going to have a lot of holes in it,” Senteno said.

The Homeland Security document acknowledges risks that the Census Bureau will assign an inaccurate immigration status to someone, that people won't be able to correct mistakes about themselves and that Homeland Security information will be linked inaccurately to data from other sources used by the Census Bureau.

“Linking records between datasets is not likely to be 100% accurate," the Homeland Security document notes.

Trump ordered the Census Bureau to collect citizenship information through administrative records from federal agencies and the 50 states after the Supreme Court ruled against his administration last summer by deciding that a citizenship question wouldn't be allowed on this spring's 2020 Census questionnaire.

The administration had said the question was being added to aid in enforcement of the Voting Rights Act, which protects minority voters' access to the ballot box. But Chief Justice John Roberts joined the court's four more liberal members in saying the administration's current justification for the question “seems to have been contrived.”

Opponents of the citizenship question had argued it would scare off immigrants, Hispanics and others from participating in the once-a-decade headcount. The 2020 Census will help determine how many congressional seats each state gets as well as the distribution of $1.5 trillion in federal funds.

The federal lawsuit challenging Trump's order to collect the citizenship data claims that the data gathering is motivated by “a racially discriminatory scheme" to reduce the political power of Latinos and increase the representation of non-Latino whites.

As part of the order, the U.S. Census Bureau has asked state drivers' license bureaus for records, but so far only Nebraska has agreed to cooperate.

Gathering the citizenship data would give the states the option to design state and legislative districts using voter-age citizen numbers instead of the total population, Trump said in the order. The U.S. Constitution specifies that congressional districts should be based on how many people — not citizens — live there. But it's murkier for many state legislative districts. Opponents fear that using just citizen figures would make legislative districts more Republican-leaning and less diverse.

“Whether that approach is permissible will be resolved when a state actually proposes a districting plan based on the voter-eligible population,” Trump's order said. “But because eligibility to vote depends in part on citizenship, states could more effectively exercise this option with a more accurate and complete count of the citizen population."