A security guard has admitted spying for Russia while working at the British Embassy in Berlin.
Prosecutors alleged David Smith, 58, had wanted to hurt the UK and the embassy where he had worked for eight years.
The Briton was accused of collecting intelligence about the embassy and leaking secret documents.
Smith pleaded guilty at the Old Bailey to eight charges under the Official Secrets Act.
He is said to have wanted to live in Russia or Ukraine during the time he passed on secret intelligence from May 2020.
Prosecutors said he was driven by an intense hatred for his country and angered by the flying of the Rainbow flag in support of the LGBT community.
He was arrested in August 2021 and 800 euro (£700) of cash was found in his home in Potsdam, Germany.
Smith, now of no fixed abode, pleaded guilty to the charges on 4 November, but reporting restrictions were initially put in place.
They were lifted on Friday after the prosecution indicated it would not seek a trial on a ninth charge that he had denied.
Smith will be sentenced at a later date and faces a maximum of 14 years in prison.
The charges laid against Smith stated he had communicated with General Major Sergey Chukhurov, the Russian military attache based out of the Russian Embassy in Berlin in 2020 – giving information about the addresses, phone numbers and activities of various British civil servants.
He collected intelligence on the operation and layout of the embassy, which was said to be useful to "an enemy, namely the Russian state".
Some of this material was classified as "secret" and related to the activities of the British government and its German embassy.
As a security guard, David Smith did not have access to top secret material in the embassy.
But the material he has admitted passing on or collecting could still be very useful for the Russians.
It could potentially help identify undercover British intelligence officers at the embassy and any agents they were meeting.
Details of CCTV could also potentially have helped Russian spies work out how to run their own operations against the embassy and collect its secrets.
Smith's lawyers are understood to dispute the prosecution's claims about his motivation but disgruntled employees historically have often been the most effective recruits for spy services.
The case may also raise questions about the checks carried out on staff, like Smith, that are recruited locally.
On the day of his arrest, Smith had left work early complaining he was feeling ill and was met by German police at his home.
A request was made for his extradition to the UK in November 2021, following a probe by British counter-terrorism police. Smith arrived back to the UK in April.
Footage from the embassy and a draft letter to a Russian military attache, dated 14 May 2020, were found after an examination of his electronic devices.
In the letter he confirmed he worked at the embassy and wanted anonymity as he offered a book classified as "official sensitive".
There were also "secret" classified emails and documents, pictures of staff security passes and personal information as well as posters and whiteboards in the embassy.
Smith's lawyer told the court the defendant disputed the way the prosecution was presenting his motivation.
Matthew Ryder KC said: "It is right to say there is significant difference as to the basis Mr Smith has pleaded guilty including him not having a negative intention towards the UK that the prosecution have alleged against him."
Inside the capital taken hostage by brutal gangs
Oil prices rise as cap on Russian crude looms
'They destroyed us, but we came together stronger'
Inside the capital taken hostage by brutal gangs
Do you need to change your accent to get a top job? Video
Two generations share bed after Russian advance
Why have so few elderly Chinese been vaccinated?
Should we put a price on nature? Video
'England manager's critics must admit he got it spot on'
How 'incredible' Mbappe upstaged history-maker Giroud
Inside the world of South Korean male beauty pageants
'Tech layoffs won't destroy American dreams of Indians’
Zimbabwe's stunning 80km safari train
The misery of middle managers
The love song that became an anthem
© 2022 BBC. The BBC is not responsible for the content of external sites. Read about our approach to external linking.