To configure a scan with your custom settings, create an on-demand task.
Task
cd /opt/isec/ens/threatprevention/bin
./isecav --addodstask --name [task name] [additional options]
Replace [task name] with the name that you want to set. The task name is a mandatory field and must be unique.
Multiple tasks can be configured with different settings.
Replace [additional options] with the settings that you need.
Option | Values | Description | Note |
--scanarchive | enable (default) disable | Examines the contents of archive (compressed) files, including .jar files. CAUTION: Scanning archives is resource-intensive and affects performance. | |
--scanmime | enable disable (default) | Detects, decodes, and scans Multipurpose Internet Mail Extensions (MIME) encoded files. | |
--scanpups | enable (default) disable | Detects, decodes, and scans potentially unwanted programs. | |
--scanunknownprograms | enable (default) disable | Detects, decodes, and scans unknown program files. | |
--scanunknownmacros | enable (default) disable | Detects, decodes, and scans unknown macro viruses. | |
--scanlocaldrives | enable disable | Scans all regular files under locally mounted file systems. | An on-demand task runs a scan on the configured files and directories. So you must set a scan path using one of these options. --scanlocaldrives enable --scantmpfolders enable --scannetworkdrives enable --scanpaths [path] |
--scanpaths | Absolute file name, just the name of a file, or Absolute name of the directory, specified according to these guidelines:
| Includes the specified files or directories to the scan. | |
--scantmpfolders | enable disable | Scans all files under these directories in the system: /tmp /usr/local/tmp /var/tmp | |
--scannetworkdrives | enable disable | Iterates and scans all network mount points on the system. Restricted to NFS and CIFS shares mounted on the system. | |
--scansubfolders | enable disable | Iterates through the folders specified. | Only applicable when specified with these options: scanlocaldrives scanpaths scantmpfolders scannetworkdrives |
--filetypestoscan |
| Specifies which file types to scan. | |
--scanmacros | enable disable | Scans for known macro threats in the list of default and specified files. | Only applicable with filetypestoscan |
--addfiletype | Extension name — The file types are specified as extension names and support the wildcard [?]. Duplicate entries are automatically removed. | Adds file types to the default or specified user-defined list. | |
--delfiletype [extension name] | Extension names — Specify the entry to be deleted. | Deletes file types from the user-defined list of the file. | |
--noextension | enable disable | Specifies files to be scanned with no extension. | |
--excludepaths | Absolute file name, just the name of a file or Absolute name of the directory, specified according to these guidelines:
| Excludes the specified files or directories from the scan. | |
--excludefiletype | Extension names, specified according to these guidelines:
| Specifies the extensions for exclusion. | |
-- excludepathwithsubfolder | Excludes the specified directory and it's all sub directories. | Only applicable for directories specified as part of excludepaths. | |
--usescancache | enable disable | Specifies to use the On-Access Scan cache lookup while scanning files for this task. | |
--primaryaction |
| Sets the primary scan action for threat detection. If the primary action fails, the secondary action is performed. | |
--secondaryaction |
| This action is performed when primary action fails. | This option is only available when primaryaction is specified as clean. For the primary action Delete, the only secondary option valid is Continue. |
--primaryactionpup |
| Sets the primary scan action for potentially unwanted programs. If the primary action fails, the secondary action is performed. | |
--secondaryactionpup |
| This action is performed when primary action for potentially unwanted programs fails. | This option is only available when primaryaction is specified as clean. |
--gti |
| The sensitivity option is available only when McAfee GTI file rating is enabled for the scan. |
Example: ./isecav --addodstask --name odstask --scanlocaldrives enable
The command adds the on-demand task with task name odstask, which scans only the local drives on the system.
Run an on-demand task that you created.
cd /opt/isec/ens/threatprevention/bin
./isecav --runtask --index [index number]
Replace [index number] with the index number of the task that you want to run. The command does not run if the task is already running.
Check whether an on-demand scan is enabled.
cd /opt/isec/ens/threatprevention/bin
./isecav --listtasks
View whether McAfee GTI is enabled or disabled for the on-access scan, and its sensitivity level, if enabled.
cd /opt/isec/ens/threatprevention/bin
./isecav --getoasconfig --summary
Enable McAfee GTI for on-access scanning to get file reputation from the McAfee GTI database.
You must have enabled On-Access Scan, and the system you intend to enable McAfee GTI must have Internet connection.
cd /opt/isec/ens/threatprevention/bin
Note: When you enable McAfee GTI without specifying the sensitivity level, the default sensitivity level medium is applied.
You can disable the McAfee GTI file reputation check for on-access scanning.
cd /opt/isec/ens/threatprevention/bin
./isecav --setoasglobalconfig --gti --state disable
You can view the sensitivity level defined in McAfee GTI presently for on-access scanning before changing it.
cd /opt/isec/ens/threatprevention/bin
./isecav --getoasconfig --summary
You can define or change the sensitivity level of McAfee GTI detection.
cd /opt/isec/ens/threatprevention/bin
./isecav --setoasglobalconfig --gti --sensitivity high
The available parameters are:
Note: These parameters values (verylow, low, medium, high, and veryhigh are case sensitive.
If you already configured the sensitivity level, the latest update replaces the existing sensitivity level. McAfee GTI sensitivity level is set to Medium by default for on-access scanning.
Tip: You can also set McAfee GTI state and its sensitivity level using the command
./isecav --setoasglobalconfig --gti --state enable --sensitivity high
Log on to the system as root user.
cd /opt/isec/ens/threatprevention/bin
./isecav --addodstask --name <task_name> --parameter1 <value> --parameter2 <value> --gti --state enable --sensitivity veryhigh
The default sensitivity level for on-demand scanning is veryhigh.
Note: For standalone systems, you can't change the existing on-demand scan settings. For managed systems, you can change the on-demand scan policies for the policy-based on-demand scans such as Full Scan and Quick Scan.
Create a DAT update task from the command-line.
cd /opt/isec/ens/threatprevention/bin
./isecav --addupdatetask --name <task_name> --updatetype --<type_of_update>
./isecav --listtasks
./isecav --addupdate task --name datupdate --updatetype dat
When you run the command from the /opt/isec/ens/threatprevention/bin directory, the software creates a DAT update task.
Run the DAT update task immediately.
cd /opt/isec/ens/threatprevention/bin
./isecav --listtasks
./isecav --runtask --index <index_number>.
If the index number of your DAT update task is 3, you must run the command.
./isecav --runtask --index 3
Run the DAT update task at a specified time or at periodic intervals.
You must have created a DAT update task.
cd /opt/isec/ens/threatprevention/bin
./isecav --listtasks
./isecav --scheduletask --index <index_number> --daily --starttime <HH:MM>
./isecav --scheduletask --index 3 --daily --starttime 12:45
When you run the command from the /opt/isec/ens/threatprevention/bin directory, the software runs the DAT update task everyday at 12:45.
Enable or disable the product logging as required.
cd /opt/isec/ens/threatprevention/bin
Configure the maximum Product log file size in megabytes.
cd /opt/isec/ens/threatprevention/bin
./isecav --setmaxproductlogsize <Number>
You can specify the file size between 1 MB and 999 MB. The default value is 10 MB
This command sets the maximum Product log file size to 25 MB.
./isecav --setmaxproductlogsize 25
Configure the software to log the information to SYSLOG in addition to storing the information in the product log.
cd /opt/isec/ens/threatprevention/bin
./isecav --usesyslog enable
Specify the directory where you want to store the quarantined items.
cd /opt/isec/ens/threatprevention/bin
./isecav --setquarantinefolder /directory_path/
You must specify the absolute path directory.
Note: You can't configure the existing directories to quarantine the detections. You should specify a new directory name.
For example,./isecav --setquarantinefolder /root/ensl_quarantinedir/
The default quarantine directory for standalone systems is /Quarantine. For systems managed by McAfee ePO, you can use the Common Policy to configure the quarantine directory. The default directory configured in the Common Policy is /quarantine/.
Use Access Protection commands to protect your standalone systems from external attacks. Enable, disable, or view the status of Access Protection using isecav commands.
cd /opt/isec/ens/threatprevention/bin
./isecav --setapstatus [enable]
Note: To disable Access Protection, run:
./isecav --setapstatus [disable]
Print the status of Access Protection, whether it is enabled or disabled.
cd /opt/isec/ens/threatprevention/bin
./isecav --getapstatus
You can create Access Protection rules, edit the rule settings, or delete the rules from the command line.
cd /opt/isec/ens/threatprevention/bin
./isecav --createaprule --rulename [value] --block [enable |disable] --report [enable |disable] --subrulename [value] --subruletype [file | process] --operations [value(s)] --includetargetfile [file1, file2...]
./isecav --createaprule --rulename test1 --block enable --report enable --subrulename stest1 --subruletype file --operations create --includetargetfile /tmp/testfile1
When you run the command from the /opt/isec/ens/threatprevention/bin directory, a rule test1 with a subrule stest1 is created that blocks the user from creating a file or directory with the name testfile1 in the /tmp directory.
When you create a rule, use parameters to block enable/disable, to apply the rule to specific users, files, or processes. You can also use parameters to report the number of tries made to access the rule-enabled files. You can also edit any rule using rule index. The getallaprules command lists all access protection rules with rule index created for a system.
Table 1: Access Protection parameters to create rules | |
Options | Description |
--rulename [value] | This command is used to name the Access Protection custom rule. Here, value can be alphanumeric and can take a maximum of 256 characters. Each custom rule name must be unique. When creating a rule, this parameter is mandatory. |
--block [enable | disable] | This command is used to enable or disable blocking of access attempts defined in the rule. This parameter is mandatory. The parameter to enable or disable the block command:--block [enable | disable] Note: When creating a rule, both --block or --report parameters are mandatory. A rule is disabled when both --block and –report are disabled. If both rules exist, then block is given the higher precedence. |
--report [enable | disable] | This command is used to enable or disable reporting of access tries. This parameter is mandatory. Note: When creating a rule, both --block or --report parameters are mandatory. A rule is disabled when both --block and –report are disabled. If both rules exist, then block is given the higher precedence. |
| This is an optional parameter and specifies the applicable process that triggers the rule if there is a subrule violation. You can identify a process with a name and a file. File can be either the file name or path. Wildcards [*, ?, and **] and comma-separated values are also accepted. Note: When --includeprocess and --excludeprocess are not specified, the rule becomes applicable to all processes. When the same process is mentioned in --includeprocess and --excludeprocess, then --excludeprocess takes higher precedence. |
| --includeusers triggers the rule for the specified users when there is a violation, whereas --excludeusers does not trigger the rule even when there is a rule violation. These parameters are optional and can accept comma-separated values. Local and Domain users are supported. Note: When --includeusers and --excludeusers are not specified, the rule becomes applicable to all users. When the same user is mentioned in --includeusers and --excludeusers then --excludeusers takes higher precedence. |
Edit a custom Access Protection rule identified by ruleindex.
Table 1: Parameters to create and edit subrules | |
Command | Description |
--addsubrule | This command is used to add subrules to a rule. |
--editaprule [ruleindex] | Edits a custom Access protection rule identified by ruleindex. |
Table 2: Parameters to manage subrules | |
Command | Description |
--subrulename [value] | This command is used to name the subrule that is added to the rule. The subrule name must be unique within a rule. This parameter is mandatory. |
--subruletype [file | process] | This command is used to set the type of subrule. The type can be file or process. This parameter is mandatory. |
--operations [value(s)] | This command is used to specify the operations associated with the subrule. Operations can vary based on the type of the subrule. Possible values for file subrule — create, delete, execute, change permission, read, rename, write, change owner, symlink, and hardlink. Possible values for process subrule — terminate and run. This parameter is mandatory. Single or comma-separated values are allowed. |
Targets are files or processes on which a subrule action is applied.
Depending on the --subruletype, the targets can differ. A subrule must have at least one target.
Multiple targets can be added at the same time for a subrule.
When --subruletype is file, the following target parameters can be used.
Table 1: Commands for subrule target file | |
Command | Description |
--includetargetfile [file1, file2…] | Specifies the target files that are included in a file subrule. The values for file can be file, name, or path. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
--includetargetdstfile [file1, file2…] | Specifies the destination file or paths that are included in a file subrule. The target operations available for a file subrule are Rename, Hardlink, or Symlink. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
--excludetargetfile [file1, file2…] | Specifies the target files that are excluded when defining the subrule target based on either the file, name, or path. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
--excludetargetdstfile [file1, file2…] | Specifies the target destination file or paths that are excluded for a file subrule. The target operations available for a file subrule are Rename, Hardlink, or Symlink. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
Subrule targets when the subrule type is process:
Table 2: Commands for subrule target process | |
Command | Description |
--includetargetprocess [name1:file1, name2:file2,…] | Specifies the target process that is included when applying the subrule. The target process has a name and a file. The value for file can be either the file name or path. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
--excludetargetprocess [name1:file1, name2:file2,…] | Specifies the target process that must be excluded when applying the subrule. The target process has a name and a file. The value for file can be either the file name or path. Wildcards [*, ?, and **] and comma-separated values are also allowed. |
Processes in the global exclusions list are excluded from rules.
Exclusions are useful when you want to exclude system-specific files or processes to run as configured.
Command | Description |
--setapexclusions [name1:processfile1, name2: processfile2,…] | Excludes the specified processes, identified by a name and file, for all Access Protection rules. processfile can either be the file name or path. Wildcards [*, ?, and **] and comma-separated values are allowed. Note: Adding a [*] in this setting ensures that all processes are excluded. |
--getapexclusions | Prints the processes that are excluded for all rules. |
Exclude processes from triggering a rule when there is a violation.
cd /opt/isec/ens/threatprevention/bin
./isecav --setapexclusions [name1:processfile1, name2: processfile2,…]
./isecav --getapexclusions
./isecav --deleteapexclusions [name1:processfile1, name2: processfile2,…]
You can view all Access Protection rules and their configuration details.
Table 1: Commands to manage Access Protection rules | |
Commands | Description |
--getallaprules | Prints all the Access Protection rules (irrespective of whether the rules are enabled or disabled). Information displayed includes rule index, rule name, actions, and origin (McAfee-defined or User-defined). To view all Access protection rules, run:./isecav --getallaprules |
--getapruleconfig [ruleindex] | Prints the details of the Access Protection rule identified by ruleindex. Information displayed includes actions, processes/users to which the rule applies, subrule and their associated targets. To print the Access Protection rules, run: ./isecav --getapruleconfig [ruleindex] |
--deleteaprule [ruleindex] | To delete the Access Protection rule identified by ruleindex. Rule name cannot be used when deleting rules. Note: McAfee-defined rules cannot be deleted. To delete an Access Protection rule, run: ./isecav --deleteaprule [ruleindex] |