A federal judge is demanding the IRS provide a more detailed explanation of what happened to the potentially thousands of missing emails of former agency official Lois Lerner.

Judge Emmet G. Sullivan on Thursday ordered the IRS to provide a new sworn declaration giving more details about Lerner’s computer troubles, just days after the IRS submitted several to the court as part of a case brought against the agency by a conservative watchdog group.

Sullivan said the IRS must provide the declaration from an official with the “authority to speak under oath for the agency” by August 22. IRS officials previously said under oath that Lerner’s emails were lost when her computer crashed, and technicians were unable to recover the drive’s data.

Sullivan said the explanation must include how the IRS attempted to retrieve the emails of Lerner, a central figure in the agency’s targeting of conservative groups, from alternative sources such as mobile devices. Sullivan also asked the IRS to explain in detail how the agency tracks hard drives when they are being serviced and provide information from an outside source to verify the agency’s policy regarding the destruction of hard drives.

Judicial Watch, which filed the Freedom of Information Act lawsuit against the IRS over the missing emails, said Thursday that it is clear that Sullivan agreed with their view that the declarations previously submitted by the IRS were inadequate.

“Today’s order confirms Judicial Watch’s read of this week’s IRS’ filings that treated as a joke Judge Sullivan’s order,” Tom Fitton, the president of Judicial Watch, said in a statement.

The declarations the IRS submitted Tuesday were from five IRS officials, including two who said they personally worked on the hard drive.

In the declarations, agency technology officials insisted they did everything they could to fix and recover data from the hard drive of Lerner. However, they said their efforts were fruitless, and some of Lerner's emails were lost.

Lerner, who has since retired, headed the IRS unit that reviews applications for tax-exempt status, when applications from Tea Party groups and other conservative organizations were held up for extra scrutiny.

The Associated Press contributed to this report.