(CNN) Anis Amri, the Tunisian suspect identified in this week's deadly attack on a Berlin Christmas market, died Friday in a shootout in Milan, according to Italian police.

The suspect was killed just after 3 a.m. local time, the Italian state police said on its Twitter feed.

When the man was asked for his papers by police, he pulled a .22-caliber gun out of his backpack and fired, according to the tweet. The driver of the police car returned fire, killing the suspect. A police officer was injured in the shootout, according to Italian police.

Amri, 24, had become a wanted man after Monday's attack in Berlin that killed 12 people and injured 48 . Though others could have been involved, Amri was the only suspect who had been publicly identified.

He had been considered violent and believed to be armed

And according to German investigative files that CNN saw Thursday, Amri had previously discussed launching an attack in Germany.

Here's what we know about him.

Italy

Amri was one of four children, according to a man who claimed to be his father.

The man said in an interview on Tunisian radio that Amri left for Italy about seven years ago after dropping out of school.

JUST WATCHED Search intensifies for German attacker Replay More Videos ... MUST WATCH Search intensifies for German attacker 02:09

While in Italy, he served four years in prison after he was involved in an arson attack on a school, his father said. Amri left for Germany more than a year ago, he added.

The elder Amri said he had not been in touch with his son, though the younger Amri maintained sporadic contact with his siblings.

A spokesman for the Italian state police, Mario Viola, told CNN that Amri's jail term for damaging state property, assault and arson at the Lampedusa refugee center began in late 2011. He was released in May 2015.

Amri entered Italy in February 2011 without any ID and claimed to be a 17-year-old minor, according to the spokesman. Italian authorities ordered his deportation, but Tunisian authorities wouldn't accept the request on the grounds of a lack of proper documentation, Viola said.

At that point, Italian authorities told Amri to leave the country, and officials lost track of him, according to Viola. Amri was "not suspected" of terrorism at the time and was considered a "petty criminal," Viola said. The Tunisian came to Italy at the same time as thousands of others amid the turmoil of the Arab Spring, he said.

Germany

Amri was believed to have gone to Germany in July 2015 and had traveled between Berlin and other cities -- but was mostly in Berlin since February, said Ralf Jaeger, interior minister of the German state of North Rhine-Westphalia.

Amri requested asylum in Germany but was denied, according to Jaeger.

Deportation proceedings were started but were not completed because Amri's identity could not be definitively established, according Stephan Mayer, a spokesman for the Christian Democratic Union/Christian Social Union parliamentary group.

While in Germany, authorities had their eye on Amri -- he was believed to be in touch with radical Islamists, including a recruitment network for ISIS operating in Germany, German security officials told CNN.

The main figure in the network, Ahmad Abdulaziz Abdullah -- a 32-year-old Iraqi national also known as Abu Walaa -- and four others were arrested and charged with terrorism offenses in November.

Jaeger said he could not confirm a link to Abu Walaa.

But according to the investigative files that CNN saw, German authorities were aware that Amri had close ties to the Abu Walaa network.

JUST WATCHED Was Berlin market attack an intel failure? Replay More Videos ... MUST WATCH Was Berlin market attack an intel failure? 06:08

Amri was particularly close to one of those charged in November, Boban Simeonovic, a German intelligence official told CNN.

Amri was mentioned several times by name in the 345-page investigative file, which underpinned the case built by prosecutors.

"Anis spoke several times about committing attacks," a police informant told German investigators, according to the files. The informant said Simeonovic and another member of the network "were in favor of that and gave him a place to hide."

Members of the Abu Walaa network also discussed driving a truck full of gasoline with a bomb into a crowd, the police informant told investigators, according to the documents.

In late 2015 and early 2016, Simeonovic tried through his contacts at a mosque in the northern German town of Hildesheim to arrange logistics for Amri to leave the country, according to the files.

Police officers enter a refugee shelter Thursday in Emmerich, Germany.

According to the police informant, Simeonovic repeatedly stressed to followers in Germany that there was a "state of war" in the country. Simeonovic and Abu Walaa "deem attacks justified, desire attacks, and support attackers," the informant stated.

"The only topic when I moved in these circles ... was how to join the armed jihad or how to get it to Germany ... by which I mean armed jihad for the Islamic State," the police informant said.

Amri -- who was thought to have used six aliases, according to authorities -- also showed up on the radar of German police because he was looking for a gun, one German security official said.

A reward of more $100,000 had been offered for information on Anis Amri's whereabouts.

In August, he was arrested with forged documents in the southern German town of Friedrichshafen en route to Italy, the security official said.

But a judge later ordered his release.

The hunt

Inside the truck that plowed through the Christmas market, authorities found a Polish man shot dead and a set of identity papers belonging to Amri.

The slain driver may have been involved in a struggle with the suspect inside the truck's cabin before being shot, CNN terrorism analyst Paul Cruickshank said. The papers could have been dropped during some sort of altercation.

Photos: Truck plows through Berlin Christmas market Authorities examine a truck Tuesday, December 20, that crashed into a crowded Christmas market in Berlin the night before. At least 12 people were killed and 48 injured in what police are investigating as a likely terrorist attack. Hide Caption 1 of 18 Photos: Truck plows through Berlin Christmas market Emergency responders tow the truck's cab away from the crash site on December 20. Ariel Zurawski, owner of the truck company, said the truck may have been hijacked as it was transporting 25 tons of steel. Hide Caption 2 of 18 Photos: Truck plows through Berlin Christmas market An overview of the crash site on December 20 shows where the tractor-trailer drove over the sidewalk and into market stalls near the Kaiser Wilhelm Memorial Church. Hide Caption 3 of 18 Photos: Truck plows through Berlin Christmas market A rescue worker stands beside Christmas decorations that were scattered by the crash. Hide Caption 4 of 18 Photos: Truck plows through Berlin Christmas market Members of the press crowd around the crash site on December 20. Hide Caption 5 of 18 Photos: Truck plows through Berlin Christmas market A rescue worker looks at destroyed market stalls near the truck's trailer. Hide Caption 6 of 18 Photos: Truck plows through Berlin Christmas market Authorities investigate the crash site on December 20. Hide Caption 7 of 18 Photos: Truck plows through Berlin Christmas market Emergency responders treat an injured person on Monday, December 19. Hide Caption 8 of 18 Photos: Truck plows through Berlin Christmas market German police shine a flashlight onto the back of the truck. Hide Caption 9 of 18 Photos: Truck plows through Berlin Christmas market Emergency crews work near the crash site on December 19. Hide Caption 10 of 18 Photos: Truck plows through Berlin Christmas market Police officers stand next to the truck. Hide Caption 11 of 18 Photos: Truck plows through Berlin Christmas market Ambulances are seen where the incident happened in western Berlin. Hide Caption 12 of 18 Photos: Truck plows through Berlin Christmas market Police stand beside the damaged truck that crashed into the market. Hide Caption 13 of 18 Photos: Truck plows through Berlin Christmas market First responders load an injured person into an ambulance. Hide Caption 14 of 18 Photos: Truck plows through Berlin Christmas market A Christmas tree lies next to the truck. Hide Caption 15 of 18 Photos: Truck plows through Berlin Christmas market Police take someone into custody near the market. Hide Caption 16 of 18 Photos: Truck plows through Berlin Christmas market Police stand guard at the market after the crash. Hide Caption 17 of 18 Photos: Truck plows through Berlin Christmas market An armed police officer stands near the scene. Hide Caption 18 of 18

Authorities publicly identified Amri on Wednesday, released pictures of him and offered a reward of up to 100,000 euros (about $104,000) for information on his whereabouts.

Germany's federal prosecutor said raids had taken place Thursday in cities across Germany. One was in Emmerich, in North Rhine-Westphalia, at a refugee shelter where Amri reportedly stayed before moving to Berlin.

Police also carried out a number of raids in the region on Wednesday, a German security official told CNN.

ISIS claimed it inspired the attack. The terror group's affiliated Amaq News Agency described the perpetrator as a "soldier of the Islamic State" who had acted in response to calls for attacks in the West.