rlm_cache updates for v3.0.x

Arran Cudbard-Bell a.cudbardb at freeradius.org
Tue Nov 25 00:03:25 CET 2014


The rlm_cache module will act as described in the notes in raddb/cache in v3.0.x.

The main change between 3.0.5 rlm_cache and 3.0.6 rlm_cache are that it will
return different rcodes for different cache states.

In <= v3.0.5
------------

The module returns "ok" if it found a cache entry.
The module returns "updated" if it added a new cache entry.
The module returns "noop" if it did nothing.

In >= v3.0.6
------------

The module returns "ok" if it found or created a cache entry.
The module returns "updated" if it merged a cached entry.
The module returns "noop" if it did nothing.
The module returns "fail" on error.

The full list of return code for the various runtime options are documented here:
https://github.com/FreeRADIUS/freeradius-server/blob/v3.0.x/raddb/mods-available/cache#L106

The second change is that the cache module will now default to *not* merging the
cached attributes back into the current request when creating a cache entry.

You can still force the server to do this by setting control:Cache-Merge := yes.

The original reason for merging the Cache-Entry into the current request was so
that the results of xlat expansions performed by the cache module would be 
available.

Almost no one used the rlm_cache module to cache the results of xlat expansions however,
and the behaviour had some odd side effects when working with attribute references,
so it seems more sensible to leave it disabled by default.

If anyone has any objections to the above behaviour changes, feel free to post them
to the list.

We also decided that the multivalued conditions were pretty useful and should be pulled
into v3.0.x as well. The test coverage of the condition parser/evaluator is good,
we don't expect any issues with it.

Testing of current v3.0.x branch would be appreciated.

-Arran

Arran Cudbard-Bell <a.cudbardb at freeradius.org>
FreeRADIUS development team

FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2



More information about the Freeradius-Users mailing list