The men with the bulldozer came after midnight. When the streets were dark and empty, they demolished a 19th-century Sufi spiritual centre and Koranic school, leaving behind only a heap of rubble and a forlorn chalkboard.

The attackers vanished into the night, but their assault was supported by many in the working-class neighbourhood. "It's for the best," shrugged a 21-year-old student. "This is helping the country."

The destruction of the historic building in Tripoli two weeks ago – targeted by ultra-conservative Salafists who see the mystical Sufi form of Islam as idolatrous – is just the latest in a wave of attacks across North Africa by hard-line Islamist militias.

Story continues below advertisement

From Tunisia to Egypt, the former Arab Spring countries are seeing a rise in Salafist influence, often expressed in violence towards Westerners and Sufi shrines. And their ideology is spreading south into West Africa, with adherents fuelling conflicts from Mali to Nigeria.

Since the street revolutions in 2011 that toppled the long-ruling regimes of Libya, Tunisia and Egypt, these extremist groups have exploited the security vacuum that emerged from the downfall of tyrants. They may lack popular support, yet have found freedom to operate in the turmoil of post-revolutionary politics.

The world was shocked by the Islamist rebels who destroyed historic Sufi sites in northern Mali last year, yet little attention is paid to the same trend in Libya, where hard-line Salafist radicals have imposed their purist beliefs by destroying sites in many neighbourhoods. Intimidated by the heavily armed fighters, the Libyan police have done little to stop the continuing destruction of Sufi shrines, tombs, mosques and schools – and some have even joined the demolition gangs, providing the muscle to protect the pickaxe-wielding militants as they destroy Sufi sites.

Idris Abusnina, the imam of the biggest and most famous mosque in Tripoli's old town, steps carefully past the gaping holes in the floor of a gloomy back room, where ancient tombs have been ransacked and destroyed by Salafists who broke into the compound by smashing through its wooden doors.

Four tombs were destroyed and 11 others were damaged in the November attack on the Ahmed Pasha Karamanli mosque. Mr. Abusnina said the police refused to investigate.

There was little doubt of the identity of the attackers. Salafists, who were active although repressed under Moammar Gadhafi's regime, had been issuing threats against the historic 18th-century mosque for years, complaining that its 150 tombs were idolatrous.

"They came late at night, with their pickaxes and their sledgehammers," Mr. Abusnina said. "It's sad. Demolishing these tombs and graves is wrong. You need to respect others, even if you disagree with them."

Story continues below advertisement

Not far away, in another quarter of the city, two domed buildings now stand empty. The tombs inside, marking the graves of family members of the city's former Turkish rulers, were removed by a Salafist militia that neighbours said broke into the locked buildings last August.

Nothing remains at the domed buildings today, except a small sign on the facade that proclaims them to be an archeological treasure. "Protected by law," the sign proclaims. Similar signs were posted on historic buildings all over Tripoli.

Yet these cultural treasures are clearly unprotected by the law when a militia wants to destroy them. "The militias all have weapons, and people are afraid to stop them," said Ibrahim Sudani, a neighbour who was sipping a coffee on a park bench near the Turkish tombs.

"There's no law," he said. "They can do whatever they want. If it happens to an archeological site, it could happen to your own home next."

Surveys show that the Salafists are still a small minority of Libya's population. The vast majority of Libyans reject their beliefs. But in a climate of insecurity and lawlessness, in which hundreds of armed militias are beyond government control, the religious hardliners are able to operate with nearly complete impunity.

In the eastern city of Benghazi, a series of violent attacks on Western targets have been linked to the Islamist militia groups, including an assault on the U.S. diplomatic mission last Sept. 11 that killed U.S. ambassador Christopher Stevens and three other Americans, sparking a political furor in the United States.

Story continues below advertisement

Barely two weeks before the assault, the world should have noticed that Libya's Islamist militias were getting bolder. In one of the most dramatic attacks since the overthrow of Col. Gadhafi, hundreds of heavily armed Salafists descended on the Sha'ab mosque – just across the street from one of Tripoli's best-known business hotels. In broad daylight, they destroyed the Sufi tombs in the mosque and then the mosque itself, using bulldozers and excavators, while dozens of Libyan police sealed off the street to give them a free hand.

A few hours later, when the mosque was gone, they celebrated their victory by slaughtering a camel and distributing the meat to their supporters.