KABUL—Afghan President Ashraf Ghani, angry over a wave of bomb attacks that have killed dozens of people in recent days, blamed neighbor Pakistan for failing to stop Taliban militants from plotting terror strikes from there.

“We hoped for peace, but war is declared against us from Pakistani territory,” Mr. Ghani said at a news conference on Monday, as Afghanistan’s top security officials stood behind him in a show of support.

The...