The case has strained relations between Athens and Tehran amid growing tensions between Iran and the United States.

The removal of oil from the Lana, formerly Pegas, prompted Iranian forces to seize two Greek tankers in the Middle East Gulf which have not yet been released.

"The (Greek) Supreme Court's ruling... is in Iran's favour," a Greek government official said, asking not to be named due to the sensitivity of the issue. The official said the ruling, which has not been made public, had come to the government's knowledge on Tuesday.

Another official confirmed the ruling. A government spokesperson said the government would not comment on court decisions.

For over two months the Iranian-flagged Lana remained under arrest off the Greek island of Evia, near the town of Karystos.

Greek authorities approved its release earlier this month, after a judicial panel ruled in favour of an Iranian company, overturning a previous court order, and the vessel which had engine problems was tugged to Piraeus.

Greek media reported that the United States challenged that decision bringing the case before Greece's Supreme Court.

U.S. government officials had no immediate comment.

Part of the ship's Iranian oil cargo had been transferred to another ship, Ice Energy, which was hired by the United States and is also moored off Piraeus port.

"Lana is expected to get fuel later today and test its engine so that it can start the oil transfer at the end of the week and sail off," the first official told Reuters.

(Reporting by Angeliki Koutantou, Lefteris Papadimas, Jonathan Saul, Arshad Mohammed; Editing by Frank Jack Daniel)