Add a factory reset command is better then such hacks. If it deletes first all keys and the other stuff and set then back the PINs, it's no security vulnerability.