These attacks are by Indian Muslims who are oppressed by the Hindu Majority
As long as India continues to blame Pakistan for everything, these types of attacks will continue.
India needs to address its oppressive nature in which it treats its muslim citizens
As you said, India's treatment of Muslims results in tragedies like this. Same goes for Israeli treatment of Palestinian citizens.