Iran's intelligence minister said on Saturday the mastermind behind Wednesday's attacks in Tehran, which killed 17 people, had been killed by security forces.

"The mastermind and main commander of terrorist attacks on the parliament and Mausoleum of Ayatollah Khomeini was killed today by the security forces," Mahmoud Alavi, minister of intelligence, was quoted as saying by Tasnim news agency. 

Four armed assailants attacked parliament office buildings on Wednesday morning, while the shrine of revolutionary founder Ruhollah Khomeini was struck by a suicide bomber, state media reported.

One of the attackers on Iran's parliament complex blew himself up on the fourth floor, while under siege by security forces, state broadcaster IRIB reported.

The Islamic State of Iraq and the Levant (ISIL, also known as ISIS) group had claimed responsibility for the attack, by suicide bombers and gunmen.

A number of arrests were made after the deadly attack on the parliament and Mausoleum of Ayatollah Khomeini.

Addressing a ceremony in Tehran early on Saturday, Brigadier General Ashtari said a number of fighters affiliated with armed groups have been arrested, local media reported.

The attack on the shrine of Khomeini is symbolically stunning. As Iran's first supreme leader, Khomeini is a towering figure in the country and was its revolutionary leader in the 1979 overthrow of the shah.