The prime minister of Spain on Wednesday testified as a witness at the country's national court in an ongoing corruption trial over his party's funding and denied any wrongdoing.

Mariano Rajoy said he had never received any secret bonuses nor had any knowledge of a slush fund that was allegedly used to finance the electoral campaigns of the ruling right-wing Popular Party, as well as to pay cash-in-hand bonuses and bribes and to renovate the party's Madrid headquarters.

"They're absolutely fake," Rajoy told the magistrates when asked about documents on which his initials appeared next to amounts of money that allegedly constituted under-the-table bonuses.

The documents _ known as the "Bárcenas Papers" after the PP's indicted ex-treasurer, Luis Bárcenas _ were published by daily El Pais in Jan. 2013 and showed handwritten ledgers detailing the alleged payment of unaccounted-for bonuses in cash ranging from 5,000-15,000 euros ($5,600-16,800) per month to high-ranking PP officials and businessmen between 1990-2009.

"Everything about me is false except some thing or other," Rajoy said of the information reported in 2013 concerning the Bárcenas affair.

When queried about cash handed over to the PP's treasury for its illegal funding, Rajoy said he had no knowledge of the matter.

"I've never heard anything about that," Rajoy said, adding that he had never been in charge of his party's finances.

"My responsibilities were political, not accounting-related," Rajoy claimed.

A month after the Bárcenas Papers were published, PP employees broke into Bárcenas' office at the party's headquarters and absconded with his two personal computers, according to the former treasurer's own account.

Bárcenas was put in pre-trial detention in June 2013 due to what judge Pablo Ruz of the National Court described as "a high risk of flight and to prevent the destruction of evidence."

A few weeks later, Bárcenas gave an exclusive interview to El Mundo newspaper while in prison in which he said that everything in the papers was true and that the PP had been illegally funding itself for 20 years.

He added that the party had been receiving opaque money from businessmen and he, as party treasurer, would later redistribute the cash among top party members and covertly pay for cost over-runs in electoral campaigns.

Bárcenas is now a subject of several proceedings, including the "Gürtel" macro-trial _ which includes Wednesday's hearing _ and the so-called "Bárcenas Case," in which 32 people, including the former mayor of Toledo and the ex-justice and interior minister, have been indicted.

The Gürtel case is the biggest political corruption scandal in Spanish history, resulting in an estimated loss to the public purse of at least 120 million euros.

The case derived its code name from Francisco Correa, a PP-linked businessman who was arrested in 2009 on suspicion of money laundering, bribery, influence peddling and tax evasion, among other charges.

The word "Gürtel" in German is a rough translation of the Spanish "Correa," which means "belt."

Correa was the alleged ringleader of a sprawling web of corruption that involved Spanish politicians and businessmen alike and was a close personal friend of former conservative Prime Minister José María Aznar's son-in-law, Alejandro Agag.

He also maintained close business and personal relationships with several mayors, city councilors and officials in regions governed by the PP, such as Valencia and Madrid, which allowed him to allegedly rig public bids for lucrative contracts and receive illegal commissions in exchange for his intercession.

As of July, more than 900 former and current PP officials had been convicted or were being investigated for corruption.

Every year, the Spanish treasury loses an estimated 88 billion euros due to public sector fraud and embezzlement.