Salafism: A new threat to Hamas.

On the streets of Rafah in the southern Gaza Strip, clusters of men wear long tunics over baggy trousers, a costume common in Pakistan but virtually unknown among Palestinians — until recently.

It is an emblem of Salafism, a branch of Islam that advocates restoring a Muslim empire across the Middle East and into Spain. Some Salafis preach violence, even killing Muslims deemed not pious enough. While historically a fringe group in the southeastern Mediterranean, Salafis have sought inroads in Lebanon and Jordan and are battling Hamas in Gaza.

While Al Qaeda, which shares its conservative religious views and promotion of holy war, has not gained a foothold in the region, Salafism may be the wave of the future. In Algeria and Morocco, similar movements have expanded in the past two decades to create havoc through civilian bombings and attacks on the police.

“This is the challenge we face in the world,” said Bilal Saab, a researcher in Middle East security at the University of Maryland in College Park. “We are getting better at dealing with insurgencies, though Afghanistan is proving to be an exception. It is much more difficult to combat the constant threat of underground urban terrorism.”