Syntax
keepenv( string env1 [, string env2, …] )
Description
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.
Example
# reset the environment to the minimum keepenv("PATH", "TERM", “HOME”, “USER”);