6
# This is a more general example of the execute module.
8
# This one is called "echo".
10
# Attribute-Name = `%{echo:/path/to/program args}`
12
# If you wish to execute an external program in more than
13
# one section (e.g. 'authorize', 'pre_proxy', etc), then it
14
# is probably best to define a different instance of the
15
# 'exec' module for every section.
17
# The return value of the program run determines the result
18
# of the exec instance call as follows:
19
# (See doc/configurable_failover for details)
21
# < 0 : fail the module failed
22
# = 0 : ok the module succeeded
23
# = 1 : reject the module rejected the user
24
# = 2 : fail the module failed
25
# = 3 : ok the module succeeded
26
# = 4 : handled the module has done everything to handle the request
27
# = 5 : invalid the user's configuration entry was invalid
28
# = 6 : userlock the user was locked out
29
# = 7 : notfound the user was not found
30
# = 8 : noop the module did nothing
31
# = 9 : updated the module updated information in the request
32
# > 9 : fail the module failed
36
# Wait for the program to finish.
38
# If we do NOT wait, then the program is "fire and
39
# forget", and any output attributes from it are ignored.
41
# If we are looking for the program to output
42
# attributes, and want to add those attributes to the
43
# request, then we MUST wait for the program to
44
# finish, and therefore set 'wait=yes'
46
# allowed values: {no, yes}
50
# The name of the program to execute, and it's
51
# arguments. Dynamic translation is done on this
52
# field, so things like the following example will
55
program = "/bin/echo %{User-Name}"
58
# The attributes which are placed into the
59
# environment variables for the program.
63
# request attributes from the request
64
# config attributes from the configuration items list
65
# reply attributes from the reply
66
# proxy-request attributes from the proxy request
67
# proxy-reply attributes from the proxy reply
69
# Note that some attributes may not exist at some
70
# stages. e.g. There may be no proxy-reply
71
# attributes if this module is used in the
72
# 'authorize' section.
77
# Where to place the output attributes (if any) from
78
# the executed program. The values allowed, and the
79
# restrictions as to availability, are the same as
80
# for the input_pairs.
85
# When to execute the program. If the packet
86
# type does NOT match what's listed here, then
87
# the module does NOT execute the program.
89
# For a list of allowed packet types, see
90
# the 'dictionary' file, and look for VALUEs
91
# of the Packet-Type attribute.
93
# By default, the module executes on ANY packet.
94
# Un-comment out the following line to tell the
95
# module to execute only if an Access-Accept is
96
# being sent to the NAS.
98
#packet_type = Access-Accept
101
# Should we escape the environment variables?
103
# If this is set, all the RADIUS attributes
104
# are capitalised and dashes replaced with
105
# underscores. Also, RADIUS values are surrounded
106
# with double-quotes.
108
# That is to say: User-Name=BobUser => USER_NAME="BobUser"