Bugfixes for the private key import