simplify and fix cb_SSH_KEYFUNCTION