keepenv( string env1 [, string env2, …] )
The keepenv procedure modifies the runenv variable to keep only those environment variables whose names are specified. All others are deleted from the runtime environment. This is used to constrain which environment variables a user may keep when running programs through Privilege Manager for Unix or Safeguard for Sudo when using the pmpolicy style policy.
# reset the environment to the minimum keepenv("PATH", "TERM", “HOME”, “USER”);
string policygetenv ( string name [, string value] )
policygetenv returns the value of the specified environment variable from the policy server.
# print the value of HOME if defined, otherwise print "none" print(policygetenv("HOME", "none"));
policysetenv ( string variable, string value )
The policysetenv procedure sets one or more environment variables in the policy server.
#set the shell variable policysetenv("SHELL", "/opt/quest/bin/pmsh");
unsetenv( string env1 [, env2, …+ )
The policyunsetenv procedure removes the named environment variable from the policy server.
The following example deletes the PAGER and EDITOR environment variables from the policy server.
policyunsetenv("PAGER", "EDITOR");
© 2024 One Identity LLC. ALL RIGHTS RESERVED. 이용 약관 개인정보 보호정책 Cookie Preference Center