Bangladeshis are generally said to think of themselves as Bengalis first, and Muslims next.
Lately, some in the mostly Sunni Muslim nation of 160 million have been thinking differently.
Like in other societies noted for their tolerance, the rise of fundamentalism and radical ideology within the broader faith has also impacted Bangladesh.
While poverty has contributed to disgruntlement, the lack of opportunities at home has led thousands to seek work in the Gulf and in South-east Asia. This has exposed them to multiple outside influences.
In the 1990s, Malaysians used to complain about Bangladeshi Lotharios stealing the affections of Malay women. These days, some of them have clearly turned to a far riskier path.
While the world is now aware of their activities here, it waits to hear from Kuala Lumpur, which surely must be doing its own monitoring of such groups, and other jurisdictions such as Dubai in the UAE and Kuwait, which also keeps a weather eye on potential terror outfits.
What shapes extremist thinking in a Bangladeshi? There is of course, the Wahabi influences spreading from the Middle East. But in their own neighbourhood, the situation is not pretty.
Religion-based nationalism is on the rise. In Myanmar, Rohingya Muslims of Bengali origin continue to suffer disenfranchisement under the dominant Buddhist majority. This has enraged many in Bangladesh, who share a sense of kinship with the Rohingyas.
Remnants of Pakistani influence in the nation, through the hardline Jamaat-e-Islami party, have also pushed religion into the nation's body politic.
Last year, Bangladesh executed several leading Jamaat members convicted of genocidal actions in favour of Pakistan during the Liberation struggle of 1971.
And even in India, a nation admired around the world for its tolerant ways, sections of its society and government have been signalling a lurch towards Hindu nationalism.
It is against this background that radicalism began manifesting last year in a significant way.
Three months ago, the US State Department issued a travel alert on Bangladesh after several terror attacks on foreigners in the country.
These included the murders of bloggers known for secular views as well as the killings of a Japanese agricultural worker and an Italian social worker who was murdered within the diplomatic area.
The murder of the foreigners was claimed by the Islamic State in Iraq and Syria (ISIS). However, Bangladeshi officials at the time ruled out the influence of ISIS in the country.
Instead, they blamed the domestic political opposition. While they had good reason to do that, it is only part of the story.
Bangladesh is divided by the bitter rivalry between Prime Minister Sheikh Hasina Wajed of the Awami League party and her rival, the widowed Khaleda Zia of the Bangladesh Nationalist Party.
Both parties make ample use of strong-arm methods in their politics.
In August 2005, some 300 bombs went off across the country, wounding more than 50 but killing just two. Subsequently, there has been sporadic violence.
However, Sheikh Hasina Wajed, prodded by India, has been unsparing of extremism since her current tenure began six years ago.
But the tolerance of thugs in both camps for their political use also means that a few extremist elements have also succeeded in finding a sinecure in their midst. Such men are aided and abetted by regional terrorist outfits, some of them based in Pakistan.
Last year, Hefazat-e-Islami, a group of students and teachers with close links to Jamaat-e-Islami fought on the streets with police and destroyed cars in several cities.
They wanted restrictions on women's rights and tough new laws on blasphemy.
That said, Bangladesh continues to be largely a nation that hews to a moderate interpretation of the faith. Indeed, the situation would have been worse if the nation had not made impressive strides toward attaining the UN's Millennium Development Goals.
A booming garment manufacturing industry, swelled by orders fleeing China and more expensive manufacturing locations, has also helped keep militancy in check by proving employment to thousands of women.
The empowerment that ensued has helped stem extremist thought from spreading too deeply - mothers, after all, are the biggest influence on the young.
This article was first published on JAN 21, 2016.
Get a copy of The Straits Times or go to straitstimes.com for more stories.