void sfsextauth::dispatch (svccb *sbp) { if (eof || !sbp) { eofcb (); } if (!registered) { warn ("This sfsextauth hasn't registered with the sfsagent yet!\n"); sbp->reject (PROC_UNAVAIL); } switch (sbp->proc ()) { case SFSEXTAUTH_NULL: sbp->reply (NULL); break; case SFSEXTAUTH_AUTHINIT: authinit (sbp); break; case SFSEXTAUTH_AUTHMORE: authmore (sbp); break; default: warn ("invalid SFSEXTAUTH procno %d\n", sbp->proc ()); sbp->reject (PROC_UNAVAIL); } }
void sfssrp_authorizer::authmore_2 (const sfsagent_authmore_arg *argp, sfsagent_auth_res *resp, cbv cb, str pw) { pwd = pw; if (!pwd || !pwd.len ()) { resp->set_authenticate (false); (*cb) (); } else { srpc->setpwd (pwd); authmore (argp, resp, cb); } }