The permanent members of the UN's Security Council do not abide by laws they force other members to abide by. This is because there really are great powers in the world, which, despite being difficult for people in the West to understand, is very obvious in the rest of the world.
There are waivers allowed from the executive branch and I believe Pakistan got one after 9/11 with some antiterrorism benchmarks (conditional aid).
As I understand it the US doesn't acknowledge Israel is nuclear armed and so doesn't give them a waiver congruent with the law.