A British manager of a firm providing security to the UK embassy in Kabul has been jailed for two years after being found guilty of bribery charges.
Ex-army officer Bill Shaw was tried by the Afghan anti-corruption court, partly funded by the UK government.
He was also fined $25,000 (£16,185). Reports say his lawyers will appeal against his conviction.
Shaw admitted paying for the release of two armoured cars - impounded by the Afghan authorities last October.
But his defence lawyer insisted Shaw thought he was making an official release payment rather than handing over a bribe.
The BBC's Martin Patience in Kabul says his trial was one of the first cases heard by an anti-corruption court which was set up to help the Afghan government crack down on corruption.
But there are suggestions that Shaw's conviction is an attempt by the Afghan government to prove its claim that foreigners are responsible for most of the country's corruption, our correspondent adds.
This has been denied by the Afghan authorities.
Shaw said he believed he was paying a legitimate fine to release two vehicles that were impounded by the national directorate due to licensing irregularities, Britain's Guardian newspaper reports.
It says Shaw arranged with a man called Eidi Mohammad for the cars to be released in return for $25,000.
His lawyer argued in court that the fact that he attempted at the time the money was paid and for weeks afterwards to get a receipt proved that he had not intended to pay a bribe.
Shaw also co-operated with authorities, voluntarily attending interviews with investigators, the newspaper said.
He also returned to the country after a 12-day holiday in the UK in early January before he was arrested on 3 March, it added.
According to reports, Shaw is now set to be moved to Pul-e-Charkhi prison - a notorious jail on the outskirts of the capital, Kabul - in the coming days.
His lawyer Kimberley Motley said the trial had been poorly conducted and that there would be an immediate appeal.
"For some reason [the tribunal] decided not to follow Afghan law or the UN conventions to which Afghanistan is a party. Furthermore, the presumption of innocence did not exist for him," she told the Guardian.
The security firm Shaw worked for - G4S - said his conviction - along with an Afghan colleague - was "patently unfair".
A former soldier, Shaw served for 28 years in the British army and was awarded the MBE, an official British honour.