A Kosovo man told a German court he regrets murdering two US servicemen at Frankfurt airport and does not ken why he did it.
Arid Uka, 21, told the court he had been radicalised by jihadist propaganda videos he watched online.
Prosecutors believe he acted alone in carrying out the deadly terror attack on German soil.
Two other US airmen were seriously injured in the attack on an air force bus in March.
"What I did was wrong, but I cannot undo what I did," Uka told the court at the opening of his trial.
Prosecutors said he had wanted to kill the airmen because they were going to join the Nato-led force in Afghanistan.
'Can't understand'
Uka said he carried out the attack after watching a video purporting to show US servicemen raping a Muslim girl in Iraq.
In fact, the video was a scene from Brian De Palma's anti-war film, Redacted.
"I thought what I saw in that video, these people would do in Afghanistan," Uka said.
"I killed two people and opened fire on three others.
"Today I can't understand myself how I could have acted this way."
He had no known contact with Islamic terror groups, prosecutors say.
Prosecutors say Uka went into one of the airport terminals, saw some US airmen and followed them back to their military bus. They say he asked one of them for a light, asked him where the bus was going, and then shot that man dead.
The indictment says Uka then boarded the bus, shouting "Allah-u akbar," and shot another man dead. Two others were severely injured; one of them was blinded in one eye.
He put his gun against the head of a fifth serviceman but the trigger jammed.
Prosecutors say Uka then fled into the terminal, where he was apprehended and confessed to the attack.
If the court accepts his confession, he is likely to only get 15 years in prison.