int fileexists ( string path )
int access ( string path )
fileexists or access() determines whether the file fn or path exists on the policy server.
Returns true if the path name exists, false if not.
if (fileexists("/opt/quest/pmc") ) { print ("PMC is installed."); }
if (access("/opt/quest/pmc") ) { print ("PMC is installed."); }
int getopt ( string argv, string optstring))
getopt breaks up command lines for easier parsing and legal review. It examines a list of arguments for short options, which is a dash followed by a single letter or parameter.
while ((option = getopt(args, "vh")) !=""){
print("Matched option",option);
}
int getopt_long ( string argv, string optstring, string long_options))
getopt_long breaks up command lines for easier parsing and legal review. It examines a list of arguments for short or long options.
The function works in posixly correct mode and does not reorder arguments. However, if you unset the POSIXLY_CORRECT environment option, it reorders the argv variable as it scans, placing all nonoptions at the end of the list.
while ((option = getopt_long(args, "vh",{"verbose","help"})) !=""){
print("Matched option",option);
}
int getopt_long_only ( string argv, string optstring, string long_options))
getopt_long breaks up command lines for easier parsing. It examines a list of arguments for only long options.
The function works in posixly correct mode and does not reorder arguments. However, if you unset the POSIXLY_CORRECT environment option, it reorders the argv variable as it scans, placing all nonoptions at the end of the list.
while ((option = getopt_long_only(args, "vh",{"verbose","help"})) !=""){
print("Matched option",option);
}
© 2024 One Identity LLC. ALL RIGHTS RESERVED. 이용 약관 개인정보 보호정책 Cookie Preference Center