diff --git a/src/auth/radius.c b/src/auth/radius.c index 3d3d2d22..2d331060 100644 --- a/src/auth/radius.c +++ b/src/auth/radius.c @@ -48,7 +48,6 @@ static rc_handle *rh = NULL; static char nas_identifier[64]; -static unsigned override_config = 0; static void radius_global_init(void *pool, void *additional) { @@ -62,9 +61,6 @@ static void radius_global_init(void *pool, void *additional) goto fail; } - if (config->no_override_config == 0) - override_config = 1; - if (config->nas_identifier) { strlcpy(nas_identifier, config->nas_identifier, sizeof(nas_identifier)); } else { @@ -339,9 +335,9 @@ static int radius_auth_pass(void *ctx, const char *pass, unsigned pass_len) } else if (vp->attribute == PW_FRAMED_IPV6_ROUTE && vp->type == PW_TYPE_STRING) { /* Framed-IPv6-Route */ append_route(pctx, vp->strvalue, vp->lvalue); - } else if (vp->attribute == PW_INTERIM_INTERVAL && vp->type == PW_TYPE_INTEGER && override_config != 0) { + } else if (vp->attribute == PW_INTERIM_INTERVAL && vp->type == PW_TYPE_INTEGER) { pctx->interim_interval_secs = vp->lvalue; - } else if (vp->attribute == PW_SESSION_TIMEOUT && vp->type == PW_TYPE_INTEGER && override_config != 0) { + } else if (vp->attribute == PW_SESSION_TIMEOUT && vp->type == PW_TYPE_INTEGER) { pctx->session_timeout_secs = vp->lvalue; } else { syslog(LOG_DEBUG, "radius-auth: ignoring server's value %u of type %u", (int)vp->attribute, (int)vp->type); diff --git a/src/cfg.h b/src/cfg.h index 09b4603d..4d26514d 100644 --- a/src/cfg.h +++ b/src/cfg.h @@ -37,7 +37,6 @@ typedef struct gssapi_cfg_st { typedef struct radius_cfg_st { char *config; char *nas_identifier; - unsigned no_override_config; } radius_cfg_st; typedef struct plain_cfg_st { diff --git a/src/ocserv-args.def b/src/ocserv-args.def index 377153ae..bc4b1689 100644 --- a/src/ocserv-args.def +++ b/src/ocserv-args.def @@ -94,12 +94,11 @@ An example configuration file follows. # One entry must be listed per line, and 'ocpasswd' should be used # to generate password entries. # -# radius[config=/etc/radiusclient/radiusclient.conf,groupconfig=true,nas-identifier=name,override-config=false]: +# radius[config=/etc/radiusclient/radiusclient.conf,groupconfig=true,nas-identifier=name]: # The radius option requires specifying freeradius-client configuration # file. If the groupconfig option is set, then config-per-user will be overriden, -# and all configuration will be read from radius. The 'override-config' if set to -# false will ignore Acct-Interim-Interval, Session-Timeout from the server and only the -# configured values will be considered. +# and all configuration will be read from radius. That also includes the +# Acct-Interim-Interval, and Session-Timeout values. # # The supported atributes for radius configuration are: # Group-Name, Framed-IPv6-Address, Framed-IPv6-Prefix, DNS-Server-IPv6-Address, diff --git a/src/subconfig.c b/src/subconfig.c index db90695a..bfb7623c 100644 --- a/src/subconfig.c +++ b/src/subconfig.c @@ -230,8 +230,6 @@ void *radius_get_brackets_string(struct perm_cfg_st *config, const char *str) } else if (c_strcasecmp(vals[i].name, "nas-identifier") == 0) { additional->nas_identifier = vals[i].value; vals[i].value = NULL; - } else if (c_strcasecmp(vals[i].name, "override-config") == 0) { - additional->no_override_config = 1-CHECK_TRUE(vals[i].value); } else if (c_strcasecmp(vals[i].name, "groupconfig") == 0) { if (CHECK_TRUE(vals[i].value)) config->sup_config_type = SUP_CONFIG_RADIUS;