As someone said recently, there are always going to be gray areas when it comes to moral questions like "How great a risk of harm to innocents am I allowed to impose when defending myself against an attack?" But we can set out obvious cases to act as boundary markers, and then ask which of them a real situation more closely resembles. So: If someone is shooting at me out of the window of an occupied apartment building, I can shoot back at that window. If I hit his hostage inside, that is very unfortunate but I am not culpable. However, I cannot launch a rocket at the building that will take down the whole edifice. In the latter case, I am culpable.