1 --- mod_auth_radius-1.5.8/mod_auth_radius-2.0.c.orig 2009-05-16 10:31:47.000000000 +0200
2 +++ mod_auth_radius-1.5.8/mod_auth_radius-2.0.c 2015-03-31 22:13:50.312803792 +0200
8 +#include <arpa/inet.h>
9 #include <openssl/md5.h>
16 -set_int_slot(cmd_parms *cmd, char *struct_ptr, const char *arg)
17 +set_int_slot(cmd_parms *cmd, void *mconfig, const char *arg)
19 - int offset = (int)cmd->info;
20 - *(int *)(struct_ptr + offset) = atoi(arg);
21 + char *struct_ptr = mconfig;
22 + int offset = (int)cmd->info;
23 + int *ptr = (int*)(struct_ptr + offset);
31 apr_snprintf(one, COOKIE_SIZE, "%s%s%s%s%s%08x", scr->secret,
32 - r->user, passwd, c->remote_ip, hostname, expires);
33 + r->user, passwd, r->useragent_ip, hostname, (unsigned)expires);
35 /* if you're REALLY worried about what's going on */
38 apr_snprintf(two, COOKIE_SIZE, "%s%s", scr->secret, ap_md5(r->pool, one));
40 apr_snprintf(cookie, COOKIE_SIZE, "%s%08x",
41 - ap_md5(r->pool, two), expires);
42 + ap_md5(r->pool, two), (unsigned)expires);
44 apr_snprintf(cookie, COOKIE_SIZE, "%s%08x%s",
45 - ap_md5(r->pool, two), expires, string);
46 + ap_md5(r->pool, two), (unsigned)expires, string);
52 static const char * const aszPost[]={ "mod_authz_user.c", NULL };
53 ap_register_provider(p, AUTHN_PROVIDER_GROUP, "radius", "0", &authn_radius_provider);
54 - ap_hook_check_user_id(authenticate_basic_user,NULL,aszPost,APR_HOOK_MIDDLE);
57 module AP_MODULE_DECLARE_DATA radius_auth_module =