A Sudanese judge formally indicted former president Omar al-Bashir on charges of possessing illicit foreign currency and corruption on Saturday.

Questioned in court for the first time, Bashir said that he had received $25 million from Saudi Crown Prince Mohammed bin Salman, as well as funds from other sources, but that he had not received or used the money for his own benefit.

A lawyer for Bashir said that his client denied the charges against him and that witnesses for the defense would be presented at the next hearing.

The judge denied a request for bail and said a decision on the duration of Bashir’s detention would be taken at a hearing on Sept. 7.

Sudan’s military ousted and arrested Bashir in April after months of protests across the country. His prosecution is seen as a test of how far military and civilian authorities now sharing power will go to counter the legacy of his 30-year rule.

Bashir was also charged in May with incitement and involvement in the killing of protesters. He has been indicted by the International Criminal Court in The Hague on charges of masterminding genocide in Sudan’s Darfur region.

A police detective told the court earlier this month that Bashir had acknowledged receiving millions from Saudi Arabia.