JOHANNESBURG — The “war room” for the African National Congress candidates running in local elections three years ago was an elaborate operation with new computers, wall monitors, lodging for volunteers and catered food three times a day.

But the A.N.C., the party in power for the 25 years since the end of apartheid, did not fund its own war room. A South African company named Bosasa paid for everything, including the wages of the so-called volunteers, according to recent testimony at a government inquiry on corruption.

Now as South Africans prepare to vote in a pivotal general election on May 8, the public does not know where the A.N.C. and the opposition parties raised the tens of millions of dollars needed to run rallies, print posters, buy television ads and perform myriad other tasks as part of their campaigns across a vast land of 57 million people.

Though South Africa has long been held up as a model of democratization, revelations at the inquiry indicate that the financing of its elections appears to be riddled with the same kind of corrupt practices that have consumed the nation in recent years.