The usage of white phosphorus is restricted under international humanitarian law. Although there can be lawful uses, it must never be fired at, or in close proximity to, a populated civilian area or civilian infrastructure, due to the high likelihood that the fires and smoke it causes spread. Such attacks, which fail to distinguish between civilians and civilian objects and fighters and military objectives, are indiscriminate and thus prohibited.
It’s messed up, but using white phosphorus isn’t banned under international law.
White phosphorus munitions are not banned under international law, but because of their incendiary effects, their use is supposed to be tightly regulated.[57] Because white phosphorus has legal uses, shells filled with it are not directly prohibited by international humanitarian law. Experts consider them not as incendiary, but as masking, since their main goal is to create a smoke screen.[58]
https://www.amnesty.org/en/latest/news/2023/10/lebanon-evidence-of-israels-unlawful-use-of-white-phosphorus-in-southern-lebanon-as-cross-border-hostilities-escalate/
Nice, thanks