Image copyright Getty Images Image caption The 2002 attack on the French-owned Limburg oil tanker killed one and injured 12 others

A Saudi man held at the US military prison at Guantanamo Bay who pleaded guilty to war crimes has been transferred back to Saudi Arabia.

Ahmed al-Darbi pleaded guilty in 2014 to the 2002 bomb attack on an oil tanker in the waters off Yemen.

The transfer was announced by the Pentagon in a statement on Wednesday.

It is the first time under Donald Trump's presidency that a detainee has left the military prison at Guantanamo Bay, and leaves 40 prisoners there.

Darbi's transfer was cleared after he met the terms of an agreement following his prior admission to guilt, the Pentagon statement said.

Under the plea deal, Darbi agreed not to sue the US over his capture and the conditions of his confinement.

He had previously alleged that he was subjected to waterboarding among other forms of torture while in US custody, the Associated Press news agency reported in 2014.

The US "co-ordinated with the government of the Kingdom of Saudi Arabia to ensure the transfer took place in accordance with established standards for security and humane treatment," the Pentagon added.

Last year, US military judges sentenced Darbi to 13 years' detention at the controversial Guantanamo Bay camp after he was found guilty of terrorism.

After waiving his right to appeal, he will now serve the remainder of his sentence in Saudi Arabia.

Darbi, who was taken to the US prison in Cuba in August 2002, pleaded guilty to five charges related to the 2002 bombing of the MV Limburg, which killed one crewmember and injured 12. The tanker was French-owned and chartered to a Malaysian oil company.

Prosecutors said Darbi had helped plan the bombing and bought the boats involved in the attack.

In June 2002, he was arrested in Azerbaijan on a charge of possessing counterfeit currency. He was then transferred to American custody and was reportedly taken blindfolded to the US base in Bagram, Afghanistan, where he reportedly said he was tortured.

Mr Trump has vowed to send more detainees to Guantanamo Bay, which is located on a US naval base on Cuba.