A soldier and a Muslim man were slightly injured when a man drove his car at troops protecting a mosque in Valence in southern France on Friday, officials said.

The driver was seriously wounded when the soldiers shot at him, but his injuries are not life-threatening, the government said in a statement. He was taken to hospital, but is still to be questioned and his motives are not yet known.

The 29-year-old is not known to local intelligence services, a source close to the investigation said. He is from a suburb of Lyon, about an hour’s drive from Valence, and his wife had arrived at the hospital to visit him, the source said.

The injured passerby was a 72-year-old man who was hit in the calf by a stray shot from the soldiers, the mayor of Valence, Nicolas Daragon, told the iTELE news channel. The soldier had slight injuries to his legs.

“The four soldiers were in front of the mosque, a moderate, quiet mosque, in between two prayer sessions, at a time when many worshippers arrived,” Daragon said. “A car drove at them.” The driver tried twice to hit the soldiers and they shot at him on his second attempt, he said.

France has been on high alert since Islamic State militants killed 130 people in shootings and suicide bombings in Paris on 13 November. Soldiers are protecting sensitive places across the country, including official buildings and religious sites.