Five global banks including the UK's Barclays and Royal Bank of Scotland have agreed to pay over $5bn in combined fines and will plead guilty to criminal charges over the rigging of foreign exchange markets.After a long-standing US probe into whether traders at the institutions conspired to fix foreign currency rates, JP Morgan Chase & Co, Barclays, Royal Bank of Scotland and Citigroup will all plead guilty to conspiring to rig foreign exchange prices.Swiss bank UBS received immunity in the case, but will plead guilty to manipulating the Libor benchmark.The banks will pay a combined penalty of $5.6bn to US and UK state authorities.RBS will pay penalties of £395m to the Department of Justice (DOJ) and $274m to the Federal Reserve.Barclays has agreed to pay a combined total of £1.5bn to the UK Financial Conduct Authority, the US Commodity Futures Trading Commission, the New York State Department of Financial Services, the DOJ and the Board of Governors of the Federal Reserve System. The £284.4m fine Barclays will pay to the FCA is the largest ever imposed by the FCA.Georgina Philippou, the FCA's acting director of enforcement and market oversight said of Barclays: "This is another example of a firm allowing unacceptable practices to flourish on the trading floor. Instead of addressing the obvious risks associated with its business Barclays allowed a culture to develop which put the firm's interests ahead of those of its clients and which undermined the reputation and integrity of the UK financial system.""Firms should scrutinise their own systems and cultures to ensure that they make good on their promises to deliver change," she added.Barclays shares popped higher after the news. Accendo Markets research analyst Augustin Eden pointed out that Barclays had actually set aside £2.05bn to cover the fines, making it the "the bank of choice for the bulls as its peers line up for their own appointments with the canes of UK and US regulators."