The US Department of Justice called it "the largest foreign bribery case in history".

After Brazilian multinational Odebrecht admitted guilt in a cash-for-contracts corruption scandal in 12 nations, it vowed to change its ways.

But Brazil's authorities are still wrestling with an encrypted computer system used to run the firm's illicit payment system.

The federal police building in Curitiba, in the southern state of Parana, has hardly been out of the news. In June 2015, the now-convicted former chief executive, Marcelo Odebrecht, was brought here.

More recently, the HQ received former president Luis Inacio Lula da Silva, jailed for corruption on charges related to the wider Lava Jato (Car Wash) investigation based here.

Along one of the airy, tiled corridors, opposite a regular computer laboratory, there is a sealed room with a complex entry mechanism. It is insulated with concrete, like a bunker.

"This room is totally isolated from external communication - internet, phones. And entrance is restricted. Even me, as the manager, I'm not allowed to enter," says Fabio Salvador, the technical supervisor.

Inside, eight specialised police officers and a technical assistant from Odebrecht have worked since September to crack one of the company's computer systems, Mywebday.

Prosecutors 'speechless'

In the case brought by the US Department of Justice, with Brazil and Switzerland in December 2016, Odebrecht and its petrochemical subsidiary, Braskem, admitted bribery to the tune of $788m (£553m) and agreed a record-breaking fine of at least $3.5bn.

The construction giant paid off politicians, political parties, officials of state-owned enterprises, lawyers, bankers and fixers to secure lucrative contracts in Brazil and abroad.

Image copyright AFP Image caption Marcelo Odebrecht is serving out his jail term at home

Apart from being the largest international bribery case ever, the Odebrecht story has one component that makes it exceptional: this was a corporation that created a bespoke department to manage its crooked deals - something prosecutors in Brazil and the US had never seen before.

"In the Odebrecht case, there are many reasons for you to become speechless," says Deltan Dallagnol, lead prosecutor in Curitiba.

"How a company created a whole system only to pay bribes, and how many public agents were involved. This case implicated almost one-third of Brazil's senators and almost half of all Brazil's governors.

"One sole company paid bribes in favour of 415 politicians and 26 political parties in Brazil. It makes the Watergate scandal look like a couple of kids playing in a sandbox."

And the web of corruption had tentacles reaching to Africa and across the region.

The president of Peru was forced to resign last month in allegations related to Odebrecht. The vice-president of Ecuador is in prison.

Politicians and officials from 10 Latin American nations continue to fall under the Odebrecht bus.

Shadow budget

Odebrecht was not the original focus of prosecutors in Curitiba. Lava Jato, the corruption case that's enveloped Brazil - putting some of the rich and powerful, including ex-president Lula, behind bars - began in 2014 as a money-laundering investigation.

Image copyright AFP Image caption Other countries across Latin America have their own investigations into Odebrecht

Focus shifted to Petrobras, Brazil's state oil company, where top managers were appointed by political parties in power. Investigators uncovered evidence that a "cartel" of engineering corporations - including Odebrecht - was rigging bids and paying bribes to secure contracts at inflated prices.

Petrobras had become a colossal piggy bank for its executives, politicians and political parties to raid. It's estimated more than $2bn was paid in kickbacks, while Petrobras lost about $14bn through over-pricing while the scheme existed.

So in 2014, prosecutors began to investigate the most influential member of that cartel, Odebrecht.

The company's bribery department, known by the rather prosaic name of Division of Structured Operations, managed its own shadow budget.

In plea-bargain testimony, Marcelo Odebrecht told prosecutors that everyone at the top of the company knew that 0.5% to 2% of the corporation's income was moved off-the-books.

"We're talking about a company that billed 100bn reais a year. If we're talking about 2%, that's about 2bn reais," he said.

In other words, up to about $600m was committed to undeclared payments. Structured Operations paid bribes through a complex and often multi-layered network of shell companies and offshore finance.

In Brazil, cash was delivered by doleiros - black market dealers. Or by "mules", who travelled with shrink-wrapped bricks of banknotes concealed beneath their clothing. Brazilian politicians were usually paid in cash. Others had secret bank accounts.

Sleaze machine

This was organised crime - highly organised crime. All financial activity was systematised using two parallel, bespoke computer systems.

Image caption Operation Car Wash is fighting corruption in Brazil, the slogan says

The first allowed internal communication within Odebrecht and also with outside financial operators. The second - the one the Federal Police in Curitiba still cannot access completely - was used to make and process payment requests.

But none of this was known to the authorities in the early stages of the investigation. A breakthrough would seal the fate of the well-oiled sleaze machine at Odebrecht.

By 2015, there was enough evidence against the company to arrest the unco-operative chief executive, Marcelo Odebrecht. In early 2016, the Federal Police gained access to the Hotmail account of one of the Structured Operations executives.

They found emails related to financial transactions and a spreadsheet created by a secretary in the division, Maria Lucia Tavares. Her home was raided.

Stashed in a wardrobe were printouts from the Mywebday system itemising illicit payments. Tavares had made hard copies for her boss to look at, and then hidden them as the noose tightened at Odebrecht. Within the division, she was responsible for making payments.

"I didn't know who the recipients were. We used codenames, but I was never told who those people actually were, and I was never curious to find out," Tavares told prosecutors.

So Tavares was never interested in knowing the identities of Dracula, Sauerkraut and Viagra.

Evidence destroyed

Many of the politicians and officials given a nickname have been identified. But not all of them, says the police chief of Parana, Mauricio Valeixo.

"We're hoping to identify those we don't know. And for others we have to get more information, because, for example, it's not enough just to have a nickname," he says. "We have to understand the reason why somebody might've been given $200,000."

Image copyright Reuters

The police chief is anticipating more arrests in the Odebrecht case, especially once technicians have cracked Mywebday. So why is that so complicated?

"On Marcelo Odebrecht's cellphone, we found information that there were orders to destroy evidence, to clean up devices," says prosecutor Deltan Dallagnol.

"It seems the devices that contained the files that could open the system were destroyed. We tried to rebuild the system in different ways.

"We asked the FBI for help. It turned out we'd need a lot of computers doing only this for more than 100 years in order for us to have a lucky strike."

But Fabio Salvador, the technical manager for the federal police, is optimistic. His team had a breakthrough in late February.

"This is a great fight for criminal expertise in Brazil," he says. "And we're going to win."

You can hear more on Corruption Incorporated - the Odebrecht Story.