Unlike in Greece, corruption is not a way of life in Spain. Most Spaniards go about their daily business without ever paying a bribe. But experts say that the concentration of power in the hands of regional and municipal officials and their ties to the local savings banks created ideal conditions for corruption in the construction boom years.

The danger is not over, they say. New sectors of commerce may soon take its place. For instance, Mr. Villoria writes in his draft paper, the health care system, now undergoing privatization, could easily take the place of construction in future scandals unless changes are made.

Already there is talk of overhauling the country’s party financing and transparency laws, increasing sentences for corruption and strengthening the independence of auditors. At the same time, many experts say more needs to be done to bolster an underfinanced judicial system, which allows many corruption cases to go unresolved for years.

One case in the Valencia region, involving allegations that a provincial governor, Carlos Fabra, tried to sell government approval of pesticides, was under investigation for nine years. The case passed through more than a half-dozen judges, as each was promoted or moved on. Such cases are not considered good for one’s career.

Few politicians under investigation resign or even step aside temporarily. Spanish columnists have had a field day recently noting that in Germany a politician resigned merely for plagiarism.

While he stayed in office, Mr. Fabra, who now faces trial, was the driving force behind a project that has become a symbol of wasteful spending — the $183 million airport in Castellón that has never managed to attract a single flight since it was inaugurated in 2011. A statue there, meant to honor Mr. Fabra, cost taxpayers about $500,000.

Justice has not moved swiftly in the La Muela case either. The town’s current mayor, María Soledad Aured de Torres, remembers the day in 2009 when 200 police officers surrounded Ms. Pinilla’s compound and her City Hall office, shutting down village business for hours.