Indeed. If proving P=NP somehow allowed us to break cryptography, we could just assume P=NP and break cryptography the same way.
Logical thinking is hard and escapes many people.