The short response
Deliberate attacks on civilians and hostage-taking are prohibited and must be condemned. They do not excuse unlawful attacks on Palestinians. International humanitarian law binds each side independently of the other’s conduct.
The evidence
An atrocity by one side does not suspend the rules for the other. The ICRC identifies this as the principle of non-reciprocity: compliance with humanitarian law cannot be made conditional on an opponent complying.
Why the argument does not follow
Attacks on civilians and hostage-taking must be condemned and investigated. They do not answer whether a separate action against Palestinians complies with the law.