HSBC has settled a criminal investigation into rigged currency transactions after agreeing to pay a $101.5m (£72.7m) fine.

The lender admitted that, in two separate incidents, its traders misused confidential information provided by their clients and used it for their own profit.

The settlement agreed with the US Department of Justice (DoJ) consists of a $63.1m fine for financial crimes and of a $38.4m repayment to an unnamed corporate client.

HSBC added the DoJ had agreed to reduce the fine by 15% after taking into account the bank's cooperation and "extensive remediation" efforts.

As part of the deal, the bank has also entered a three-year deferred prosecution agreement with the DoJ. The deal has to be ratified by a US court but if approved would allow Europe's biggest lender to avoid criminal charges.

"The conduct described in the agreement occurred in 2010 and 2011," the bank said.

"Since then, HSBC has introduced a number of measures designed to make the control environment in its Global Markets business more robust.

"The DoJ recognises these extensive improvements, noting that HSBC has dedicated significant resources to strengthening its systems and controls."

In October last year, Mark Johnson, the former head of HSBC's FX global cash trading in London, was found guilty of defrauding a client in a currency deal worth $3.5bn by a New York court.

Johnson was found guilty of defrauding Cairn Energy in what prosecutors described as a clear case of "front-running" the company's $3.5bn order. According to the prosecution, Johnson was among 11 traders in London and New York who sparked a pound-buying frenzy shortly before the Cairn transaction was due to be completed.

As a result, the value of sterling surged to its highest level in two days on 7 December 2011, shortly before the 3pm deadline for the deal. Johnson and his former colleague Stuart Scott, HSBC's European head of foreign exchange trading in London until December 2014, allegedly pocketed $3m in profit and also billed their client $5m in fees for their work.

HSBC has since agreed to repay Cairn Energy $8.1m in settlement over the incident. The lender has had a turbulent relationship with authorities. In September it was fined $175m for "unsound practices" in its foreign exchange transactions.

Two months later, the bank agreed to pay €300m (£266m) to French authorities to settle a long-running investigation into tax evasion by French clients, after it had been alleged that HSBC's Swiss private banking unit had helped its clients evade tax.