Reworked plugin APIs slightly, added full support for authentication from plugins.

This commit is contained in:
Jan Vidar Krey
2010-07-29 08:43:22 +02:00
parent c75090cdf2
commit 93be2c584e
12 changed files with 244 additions and 140 deletions

View File

@@ -234,7 +234,7 @@ int hub_handle_password(struct hub_info* hub, struct hub_user* u, struct adc_mes
if (u->state == state_verify)
{
if (acl_password_verify(hub->acl, u, password))
if (acl_password_verify(hub, u, password))
{
on_login_success(hub, u);
}
@@ -465,7 +465,7 @@ void hub_send_password_challenge(struct hub_info* hub, struct hub_user* u)
{
struct adc_message* igpa;
igpa = adc_msg_construct(ADC_CMD_IGPA, 38);
adc_msg_add_argument(igpa, acl_password_generate_challenge(hub->acl, u));
adc_msg_add_argument(igpa, acl_password_generate_challenge(hub, u));
user_set_state(u, state_verify);
route_to_user(hub, u, igpa);
adc_msg_free(igpa);