private key both have different nicknames, import the cert with the nickname from the file's cert, not from the file's private key. Also, fix an infinite loop and certain other bugs. r=neil.williams. git-svn-id: svn://10.0.0.236/trunk@218281 18797224-902f-48f8-a5cc-f745e15eee43