Home Minister Asaduzzaman Khan's statement Sunday came days after Ansar al-Islam, the Bangladeshi division of al Qaeda in the Indian Subcontinent, claimed responsibility for the killing of blogger Nazimuddin Samad last week.
Khan said authorities are investigating two to three people in connection with the attack, but they have not arrested them because officials are still trying to confirm their involvement.
Samad's death marks the sixth time a Bangladeshi writer of atheist material has been killed in 14 months.
Bangladeshi authorities have previously denied that foreign terror groups such as al Qaeda or ISIS have taken root in the majority-Muslim country.
Instead, they have often claimed homegrown extremists are responsible for such attacks.
A gruesome attack
Samad, a 26-year-old graduate student, was on his way home from evening classes Wednesday when three to four people circled him.
"First the attackers hacked Samad with machetes, then shot him," Dhaka Senior Assistant Police Commissioner Nurul Amin said.
Police said the attackers then fled the scene on motorcycles. No arrests have been made.
War against atheism
In its statement claiming responsibility, al Qaeda accused Samad of being an "enemy of Allah." It listed three of Samad's posts on Facebook going back to 2013 as examples of his insults against Islam.
The group has effectively declared war against atheist writers who dare to challenge al Qaeda's strict interpretation of Islam.
It has also threatened to target judges, lawyers, engineers and doctors "who don't allow others to follow the rulings of the Islamic Shariah."
Khan, the home minister, said the issue is not freedom of expression but tolerance of other religions.
"The bloggers, they should control their writing," he told CNN. "Our country is a secular state. ... I want to say that people should be careful not to hurt anyone by writing anything -- hurt any religion, any people's beliefs, any religious leaders."
The Bangladeshi government has vowed to bring killers to justice.
Law Minister Anisul Huq pointed to the December 2015 death sentence handed down to two men convicted of killing blogger Ahmed Rajib
And several top government officials insist security forces will provide protection to writers who feel their lives are at risk.
But some feel that not enough is being done. The response to Samad's murder has raised emotions amongst fellow Bangladeshi writers and students, amongst others. They took to the streets of Dhaka over the weekend, demanding action from the government.
"We want to see a change in Bangladesh's public policy," said Ripon Sardar, a student from Jagannath University who was demonstrating in the capital over the weekend.
The view is shared by many the blogging community, but there is a sense of frustration, if not resignation, at the government's ability to protect them and the free speech that is vital to their work.
Atheists flee Bangladesh
Members of the besieged "free-thinker" intellectual community in Bangladesh say they do not trust the police, because in recent years authorities prosecuted several writers for "insulting religion" in their published work.
"I have not gone to the police because police actually tried to arrest me in 2013," one atheist blogger in Bangladesh said.
He asked not to be identified because he is on a hit list of 84 atheist writers published by a jihadi group more than a year ago. The blogger is part of a network that has helped at least a dozen colleagues flee Bangladesh.
"This community is shattered," the writer said.
To avoid being murdered, the blogger said, he stopped posting comments online, changed his phone number and place of residence and regularly changed his route to and from work.
He said he felt like it was a de facto crime to admit to being an atheist in this country.
"I'm definitely living in fear," he said.
In 2015, the freedom of press watchdog organization Committee to Protect Journalists
listed Bangladesh as 12th in the world on its Global Impunity Index
highlighting countries "where journalists are slain and the killers go free."