A Justice Department official on Friday defended the legality of a program to scoop up data from thousands of mobile phones as the secret operation came under scrutiny from lawmakers and caught the federal agency that regulates the nation’s airwaves by surprise.

The Justice Department, without formally acknowledging the existence of the program, defended the legality of the operation by the U.S. Marshals Service, saying the agency doesn’t maintain a database of everyday Americans’ cellphones.

The Wall Street Journal on Thursday revealed the program, in which Cessna aircraft are outfitted with devices—some known as "dirtboxes" to law-enforcement officials—that mimic cell towers of large telecommunications companies and trick cellphones into reporting identifying information in a hunt for criminal suspects. The technology enables investigators to scoop data from tens of thousands of phones in a single flight, collecting the number and general location, according to people familiar with the program.

On Friday, the Federal Communications Commission, which regulates the nation’s airwaves, said it had no idea about the program.

"We were not aware of this activity," said Kim Hart, a spokeswoman for the FCC, which licenses and regulates cell-service providers.

Click for more from WSJ.com