The SpaceX Falcon 9 rocket and Crew Dragon capsule stand upright on the launchpad at NASA’s Kennedy Space Center ahead of the Demo-2 launch.

Elon Musk’s SpaceX denounced a subpoena from the Department of Justice for its corporate hiring records, saying in a court filing that the investigation by the federal agency’s Immigrant and Employee Rights unit “is the very definition of government overreach.”

“SpaceX draws the line at IER’s overreaching attempt to bootstrap that lone, frivolous charge into the wide-ranging (and expanding) pattern-or-practice investigations the agency is now pursuing,” the company, represented by lawyers from Akin Gump Strauss Hauer & Feld, wrote in the response.

The strong response comes as SpaceX’s first public comment on the DOJ’s investigation, which has been for months looking into whether the space company discriminates against applicants from foreign countries in its hiring.

SpaceX’s fight against the DOJ’s subpoena will be heard by a California federal judge later this month.

The DOJ has declined CNBC’s request for comment on its investigation, while SpaceX has not responded to multiple requests for comment.

An investigation into hiring practices

The federal agency’s Immigrant and Employee Rights unit launched a probe last year, after Fabian Hutter, a SpaceX job applicant, complained to the government that the company discriminated against him.

In an earlier interview with CNBC, Hutter said he believes SpaceX decided not to hire him after he answered a question about his citizenship status last March for a technical strategy associate position.

Hutter holds dual citizenship in Austria and Canada but is a lawful permanent U.S. resident, according to court records filed in U.S. District Court for the Central District of California.

But the DOJ unit is not only investigating the complaint, but also said it “may explore whether [SpaceX] engages in any pattern or practice of discrimination” barred by federal law.

Investigators in October issued a subpoena demanding that SpaceX provide information and documents related to its hiring and employment eligibility verification processes, to which SpaceX has not fully complied.

The company’s lawyers argue that the DOJ’s probe is overbearing given the original complaint.

“No matter how generously ‘relevance’ is construed in the context of administrative subpoenas, neither the statutory and regulatory authority IER relies on, nor the Fourth Amendment to the U.S. Constitution, permits IER to rifle through SpaceX’s papers on a whim and absent reasonable justification,” SpaceX said.

“And even if IER could somehow belatedly justify its current investigations, IER’s subpoena is excessively overbroad. IER’s application for an order to comply with the subpoena should be denied,” the company added.

Hiring policies in place

SpaceX is allowed to hire noncitizens who have a green card under U.S. International Traffic in Arms Regulations.

Those rules say that only Americans or noncitizens with a U.S. green card can have physical or digital access to items on the U.S. Munitions List, which consists of defense-related equipment, software and other material.

SpaceX noted that it currently employs more than 9,500 people, “including hundreds of non-U.S. citizens.”

In its response to the subpoena, the company detailed its side of the interview process with Hutter, highlighting that his resume “clearly stated that he was a dual Austrian and Canadian national.”

He was among “hundreds” of applicants for the position and one of seven who advanced to a phone screening, the company said.

Doug Tallmadge, a SpaceX employee, had Hutter confirm his citizenship status in the interview, the firm said.

Tallmadge “did not ask” further about Hutter’s citizenship in a follow-up interview, SpaceX added.

SpaceX says Tallmadge was “unimpressed” with the applicant’s responses in the second interview, writing in an assessment that it was “unclear” what motivation Hutter had for wanting to work on the company’s Starlink project.

The company did not hire Hutter or anyone else for the position and said it eliminated the role.

Federal Judge Michael Wilner is expected to hear the case on the morning of March 18.

The judge hinted in a previous filing that SpaceX could find it difficult to block the subpoena, referencing a prior decision he made in an unrelated case. In that other case, Wilner flatly rejected a company’s arguments against complying with a subpoena for hiring information.

Read SpaceX’s full response below:

– CNBC’s Dan Mangan contributed to this report.