Details of a failed plot to trap a Nazi spy without the knowledge of Britain's war leaders have been released.
It was feared Cicero would sell sensitive details about D-Day
Civil servants suspected the identity of the agent, codenamed Cicero, and feared he would wreck plans for D-Day.
The spy was a valet to a British ambassador in Turkey and sold copies of his employer's secret papers.
National Archive documents say a fake Cabinet Office paper was planted at the embassy in the hope Cicero would photograph it and give himself away.
Cicero - a Turk later exposed as Ilyas Bazna - worked for Sir Hughe Knatchbull-Hugessen, the British ambassador to Ankara.
He was not caught in the January 1944 sting and his story - which became the subject of the James Mason film Five Fingers - was not revealed until after the war.
The documents reveal how Sir Hughe would leave sensitive papers in a red box while he took a bath.
Cicero would use the ambassador's key to open the lock before photographing papers and selling them to the Germans.
It was one of the enemy's biggest spying coups of World War II and could have threatened the security of Operation Overlord, the Allied landings in Normandy.
The records reveal civil servants in the Foreign Office suspected Cicero's identity and planted the document, entitled Peace Feelers from Bulgaria, without telling the war cabinet.
Foreign Secretary Anthony Eden was not told and his signature was forged by his private secretary.
The records, available to the public in Kew, London, state Cicero was paid up to £88,000 by Germany for copies of documents.