BERLIN, Germany: A Pakistani man was convicted in Germany on Monday of spying for Iran to search out potential attack targets for the Revolutionary Guards, reports foreign media.

The defendant, 31-year-old Mustufa Haidar Syed-Naqvi, was sentenced to four years and three months in prison “for working for a foreign intelligence service,” a spokeswoman for Berlin’s superior court said.

The court found he spied “against Germany and another NATO member,” France, for the al-Quds Force, the foreign operations wing of the elite Revolutionary Guards.

Syed-Naqvi compiled dossiers on possible attack targets — a German lawmaker who is the former head of a German-Israeli organization, and a French-Israeli economics professor.

Investigators found detailed dossiers on the men and their daily routines, with hundreds of photos and video clips.

The court heard they detailed the targets’ homes and work places, various access routes to them, as well as information on security guards, surveillance cameras and nearby police stations.

A representative of Germany’s domestic intelligence service, which handles counterespionage, said it was alerted to the defendant by a “reliable” source.

The service suspected the al-Quds Force was preparing for a possible future conflict with the United States and Israel, when it would hit targets in Europe in a form of “asymmetrical warfare.”

The Karachi-born Syed-Naqvi came to Germany as a student in 2012 and most recently lived in the western city of Bremen. The defendant travelled to Iran at least twice, in October 2015 and February 2016, and received at least $2,237 for his intelligence activities. He was arrested in July 2016, but declined to testify during the trial — “out of fear,” according to his lawyer.