user-name (Event Policy)
Syntax
user-name username;
Hierarchy Level
[edit event-options policy policy-name then change-configuration], [edit event-options policy policy-name then event-script filename], [edit event-options policy policy-name then execute-commands], [edit event-options policy policy-name then upload filename (filename | committed) destination destination-name]
Description
Associate a user with an action in an event policy. The event policy action is
executed under the privileges of the associated user. You can configure the
user-name statement for the following actions:
-
Changing the configuration
-
Executing a SLAX or XSLT event script
-
Executing commands
-
Uploading a file
When you configure the user-name statement for event scripts, it
applies to only SLAX and XSLT scripts. To execute a local Python event script
under the access privileges of a specific user, configure the
python-script-user username
statement at the [edit event-options event-script
file filename] hierarchy level. If you do
not configure the python-script-user statement for a Python
event script, the device executes the script using the access privileges of the
generic, unprivileged system account nobody.
Default
If you do not configure a user for an event policy action, actions that support this statement
are executed as user root.
Options
| username | Username that is configured at the |
Required Privilege Level
maintenance—To view or add this statement in the configuration.
Release Information
Statement introduced in Junos OS Release 8.4.
Support at the [edit event-options policy policy-name then change-configuration] hierarchy level introduced in Junos
OS Release 12.1.