plugins/python/example_policy_plugin.py: make allowed_commands ordered

Storing them as "tuple" instead of "set", so they have a fix order.
This makes the output of the list() example stable. ("set" is printed out
in random order)
This commit is contained in:
Robert Manner
2020-01-09 15:39:49 +01:00
committed by Todd C. Miller
parent 2ee1dd3ec3
commit 35c85596d7

View File

@@ -41,7 +41,7 @@ class SudoPolicyPlugin(sudo.Plugin):
not acceptable, catch it. not acceptable, catch it.
""" """
_allowed_commands = {"id", "whoami"} _allowed_commands = ("id", "whoami")
_safe_password = "12345" _safe_password = "12345"
# -- Plugin API functions -- # -- Plugin API functions --