A Jordanian court sentenced a man to death by hanging after convicting him of a deadly attack on an intelligence services office two months ago, state news agency Petra reported Thursday.
The state security court also handed down a one-year jail term to a co-defendant on charges of selling the machine gun used in the June 6 attack, Petra added. Both rulings can be appealed.
The main defendant was identified as Mahmoud Masharfeh, a 22-year-old Jordanian national.
Five people were killed in the attack near a Palestinian refugee camp north of the capital, Amman.
Jordan is generally a stable country but it is surrounded by neighbours in turmoil such as Iraq and Syria.
Jordan is part of a US-led air alliance against Islamic State in Syria.
In recent months, Jordanian authorities have cracked down on Islamic State sympathizers since the extremist group's rise to prominence in 2014.