Fix bug relevant to ssh key-based authentication