A 29-year-old Somalian immigrant was shot dead by police after he killed one man and took a female hostage at a hotel in Brighton, a Melbourne suburb, June 5. He also injured three police officers that responded to the incident.

Yacqub Khayre was identified as the suspect in the horrific ordeal. Khayre had a longstanding criminal record in the country, which included a violent burglary in 2012 in which he was sentenced to over five years in prison. He was also acquitted in a trial where it was alleged that he was plotting a terrorist attack at an Australian army base.

ISIS has reportedly claimed that Khayre was a soldier and carried out the attack in response to appeals that targeted nationals of the coalition countries.

BREAKING: ISIS claims Melbourne, Australia terror attack calling attacker a soldier of the Islamic State #Brighton pic.twitter.com/YSrjELCE3H — Lisa Daftari (@LisaDaftari) June 5, 2017

Here’s what you need to know about Khayre:

1. Khayre Killed 1 Man & Wounded 3 Police Officers in a Hotel Before He Was Killed

On June 5, Khayre took a woman hostage at the Buckingham Serviced Apartments in Brighton. The ordeal lasted about two hours, and it ended with Khayre being killed by police when gunfire was exchanged between the two. Khayre killed two men and injured three police officers in the incident.

Police say that Khayre, who was on parole for criminal offenses, took the woman hostage around 4 p.m. local time in Brighton. When authorities arrived on scene, they found a man dead inside the foyer in the complex while he was holed up inside the woman’s apartment.

BREAKING: Police are on the scene of a possible terror attack in Melbourne suburb of Brighton. https://t.co/10lvIbew21 #7News pic.twitter.com/KOaewUCdyE — 7 News Adelaide (@7NewsAdelaide) June 5, 2017

After a standoff that lasted around two hours, Khayre was shot dead by police when he exited the room and fired at officers, injuring three of them.

It’s believed that all three victims inside the hotel were employees. Police turned away those staying at the location for the evening, telling them to come back in the morning until a full investigation was complete.

2. He Reportedly Called a Newsroom & Pledged Allegiance to the Islamic State

In the middle of the attack, Channel 7 in Melbourne reported receiving a call from a male that said: “This is for IS, and this is for al-Qaeda.”

Channel 7 said that in the brief call, a woman, believed to be the hostage, could be heard screaming frantically in the background.

The Daily Mail reported that the call was answered by Channel 7 Chief of Staff Nicole Bland. She said that the phone call left her “chilled to the bone.”

Channel 7’s Paul Dowsley said that Bland described the voice on the other side of the phone as being “very firm” while issuing his statement. The call occurred roughly 20 minutes before Khayre was shot and killed by police.

3. He Was Previously Acquitted of Planning a Terrorist Attack on an Army Base

The gruesome incident wasn’t the first time that Khayre has been involved in a terrorism plot, the Herald Sun reported.

In 2009, he was charged and acquitted after he planned a suicide attack against Sydney’s Holsworthy army. If successful, Khayre planned to use high-powered weapons with others to kill as many Australian soldiers at the base as possible.

An investigation found that money was being transferred from Australia to the Somalian terrorist group known as al-Shabaab. The money trail led authorities to the suspects, and their plan was foiled.

At his 2010 trial, however, Khayre’s attorneys argued that he was “looking for religious enlightenment” and had no plan to go through with an attack.

Five men, including Khayre, were arrested in connection with the terror plot. Their names are Saney Edow Aweys, Nayef El Sayed, Abdirahman Ahmed and Wissam Mahmoud Fattal.

The jury acquitted him and a co-defendant. Three other men were convicted in the plot and sentenced to 18 years in prison.

4. Khayre Also Carried out a Home Invasion & Was Jailed for 3 Years

In 2012, after he was cleared of the alleged suicide plot, he was convicted of an aggravated battery in Dallas, a suburb of Melbourne.

Khayre broke into a woman’s home in Dallas and began stealing things. He was holding a torch and was wearing black gloves when the woman returned home after a night out and saw him in her house.

When Khayre made contact with the woman, who lived with her father, he attacked her. Her father woke up to her screams.

Khayre then tried to attack the father, who was a former Turkish police officer. He and the father fought, with Khayre punching him in the face and headbutting him.

Finally, the woman and her father wrestled Khayre to the ground and apprehended him. He was restrained until authorities arrived on scene and took him into custody. He was found to have a meth pipe on him and a knife in his possession.

Police said that when he was captured, he was “so impaired by drugs that he could not immediately be interviewed.” When he finally was coherent enough to speak, he lied about his identity.

Kahyre pleaded guilty to the charges of theft, aggravated burglary and intentionally and recklessly causing injury. He was sentenced to serve five years and six months in prison, but was paroled after three years.

5. Khayre Immigrated From Somalia With His Family

When he was 3-years old, Khayre and his family moved to Australia because of an ongoing war in Mogadishu in 1991. He moved in with his uncle, Ibrahim Khayre, who was already living in Melbourne.

Yacqub grew up in the Melbourne area and went to school in the area. His uncle said that he eventually became close friends with Lebanese boys that turned out to be “bad influences” in his life.

His uncle called him a “respectable, disciplined boy who was nice to others and did well at school.” That lasted until he was around 12, when his grandfather died. He was a major influence in Yacqub’s life, and his schoolwork started to deteriorate after that.

One time, Yacqub stole his uncle’s car, and soon enough he rarely saw him anymore. Ibrahim said that he now “regrets bringing his family to Australia.”

When he was 21-years old, Yacqub allegedly returned to Somalia to attend a camp. His uncle told The Sydney Morning Herald that’s where he thinks “weapons and military training may have happened.”