Added expanduser call to public key path