The order was filed more than six months after the government announced reaching an accord with the bank.

Both sides argued Gleeson didn’t have the power to approve or reject the terms they came to, the judge said in his order.

'A pending criminal case is not window dressing', Gleeson wrote. 'Nor is the court, to borrow a famous phrase, a potted plant. By placing a criminal matter on the docket of a federal court, the parties have subjected their DPA to the legitimate exercise of the court’s authority'.

HSBC was accused of failing to monitor more than $670bn in wire transfers and more than $9.4bn in purchases of U.S. currency from HSBC Mexico, allowing for money laundering, prosecutors said.