java.lang.Object | |
↳ | com.samsung.android.knox.log.AuditLogRulesInfo |
This class provides the configuration object that is used by AuditLog
to perform
selective data logging, via setAuditLogRules(AuditLogRulesInfo)
.
Using this class, administrator will be able to configure the rules, based on the following
parameters:
Severity: This parameter configures the rule for severity level of data selection. The
selection scale is:
AUDIT_LOG_SEVERITY_ALERT
AUDIT_LOG_SEVERITY_CRITICAL
AUDIT_LOG_SEVERITY_ERROR
AUDIT_LOG_SEVERITY_WARNING
AUDIT_LOG_SEVERITY_NOTICE
Outcome: This parameter is used to select log information based on outcome.The defined
values for this parameter are:
AUDIT_LOG_OUTCOME_ALL
AUDIT_LOG_OUTCOME_FAILURE
AUDIT_LOG_OUTCOME_SUCCESS
Groups: Use a list with the module groups:
AUDIT_LOG_GROUP_SECURITY
AUDIT_LOG_GROUP_SYSTEM
AUDIT_LOG_GROUP_NETWORK
AUDIT_LOG_GROUP_EVENTS
AUDIT_LOG_GROUP_APPLICATION
Users: Provide a list with the current users on device to select auditable information
based on user. Only owner (User 0) administrator is able to filter audit events by user.
EnableKernel: Administrator may request all information from kernel to be logged, using
boolean value true. Using false will disable this selection. To avoid selection of
unnecessary information causing excessive storage allocation, it is recommended to leave this
value as false. Disabling kernel will not interfere on collection of necessary data that
comes from kernel, including IpTables and Encryption information.
API level 17 |
KNOX 2.5 |
Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
int | AUDIT_LOG_OUTCOME_ALL | Use this constant to configure AuditLogRulesInfo Outcome value to All. | |||||||||
int | AUDIT_LOG_OUTCOME_FAILURE | Use this constant to configure AuditLogRulesInfo Outcome value to Failure. | |||||||||
int | AUDIT_LOG_OUTCOME_SUCCESS | Use this constant to configure AuditLogRulesInfo Outcome value to Success. |
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From interface
android.os.Parcelable
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
This constructor is used to instantiate an AuditLogRulesInfo object with the most permissive
values and kernel messages disabled.
| |||||||||||
This constructor is used to instantiate an AuditLogRulesInfo object with parameters defined
by the administrator.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
This API retrieves the list of group modules of an AuditLogRulesInfo object.
| |||||||||||
This API retrieves the value set as outcome for an AuditLogRulesInfo object.
| |||||||||||
This API retrieves the value set as severity for an AuditLogRulesInfo object.
| |||||||||||
This API retrieves the list of users of an AuditLogRulesInfo object.
| |||||||||||
Deprecated
in API level 35
NOTE: This API is not available since Android 12. | |||||||||||
This API configures the list of group modules of an AuditLogRulesInfo object.
| |||||||||||
Deprecated
in API level 35
NOTE: This API is not available since Android 12. | |||||||||||
This API configures an outcome level for AuditLogRulesInfo object.
| |||||||||||
This API configures a severity level of an AuditLogRulesInfo object.
| |||||||||||
This API configures the list of users of an AuditLogRulesInfo object.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
android.os.Parcelable
|
Use this constant to configure AuditLogRulesInfo Outcome value to All.
API level 17 |
KNOX 2.5 |
Use this constant to configure AuditLogRulesInfo Outcome value to Failure.
API level 17 |
KNOX 2.5 |
Use this constant to configure AuditLogRulesInfo Outcome value to Success.
API level 17 |
KNOX 2.5 |
This constructor is used to instantiate an AuditLogRulesInfo object with the most permissive values and kernel messages disabled.
The Default values are:
Severity: AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); |
API level 17 |
KNOX 2.5 |
This constructor is used to instantiate an AuditLogRulesInfo object with parameters defined by the administrator.
severityRule | Defined value for severity. |
---|---|
outcomeRule | Defined value for outcome |
groupsRule | Defined list with Module Groups |
enableKernel | Enable or disable kernel originated messages. |
userRule | Defined filter by user (only available to Owner) |
Administrator must inform the parameter values to use this API.
List<Integer> mGroups = new ArrayList<Integer>(); mGroups.add(AuditLog.AUDIT_LOG_GROUP_SECURITY); mGroups.add(AuditLog.AUDIT_LOG_GROUP_SYSTEM); mGroups.add(AuditLog.AUDIT_LOG_GROUP_NETWORK); List<Integer> mUsers = new ArrayList<Integer>(); mUsers.add(0); mUsers.add(100); AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo( AuditLog.AUDIT_LOG_SEVERITY_NOTICE, AUDIT_LOG_OUTCOME_RULES_ALL, mGroups, false, mUsers); |
API level 17 |
KNOX 2.5 |
This API retrieves the list of group modules of an AuditLogRulesInfo object.
Administrator may use this API to retrieve the list of group modules configured for an
AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); List |
API level 17 |
KNOX 2.5 |
This API retrieves the value set as outcome for an AuditLogRulesInfo object.
Administrator may use this API to retrieve the outcome set for an AuditLogRulesInfo
object
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); int outComerule = mAuditLogRulesInfo.getOutcomeRule(); |
API level 17 |
KNOX 2.5 |
This API retrieves the value set as severity for an AuditLogRulesInfo object.
Administrator may use this API to get the severity value set for an AuditLogRulesInfo
object.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); int severityRule = mAuditLogRulesInfo.getSeverityRule(); |
API level 17 |
KNOX 2.5 |
This API retrieves the list of users of an AuditLogRulesInfo object.
Administrator may use this API to retrieve the list of users configured for an
AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); List |
API level 17 |
KNOX 2.5 |
Deprecated
in API level 35
NOTE: This API is not available since Android 12.
This API retrieves the value of kernel logging configuration on AuditLogRulesInfo object.
true
if kernel logs selection is enabled and false
otherwise.Administrator may use this API to retrieve kernel logging status of an
AuditLogRulesInfo object.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); boolean ret = mAuditLogRulesInfo.isKernelLogsEnabled(); |
API level 17 |
KNOX 2.5 |
This API configures the list of group modules of an AuditLogRulesInfo object.
groupsRule | A list containing a set of selected module groups. |
---|
Administrator may use this API to set the group modules for an AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); List |
API level 17 |
KNOX 2.5 |
Deprecated
in API level 35
NOTE: This API is not available since Android 12.
This API configures kernel logging status AuditLogRulesInfo object.
It is recommended to leave kernel messages logging off, in order to preserve storage
allocation with unnecessary information.
enableKernel | Enable or disable kernel originated messages. |
---|
Administrator may use this API to configure kernel logging of an AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); mAuditLogRulesInfo.setKernelLogsEnabled(true); |
API level 17 |
KNOX 2.5 |
This API configures an outcome level for AuditLogRulesInfo object.
outcomeRule | Defined value for outcome |
---|
Administrator may use this API to configure Outcome value for an AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); mAuditLogRulesInfo.setOutcomeRule(AUDIT_LOG_OUTCOME_FAILURE); |
API level 17 |
KNOX 2.5 |
This API configures a severity level of an AuditLogRulesInfo object.
severityRule | Defined value for severity. |
---|
Administrator may use this API to configure severity level for an AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); mAuditLogRulesInfo.setSeverityRule(AuditLog.AUDIT_LOG_SEVERITY_NOTICE); |
API level 17 |
KNOX 2.5 |
This API configures the list of users of an AuditLogRulesInfo object.
userRule | A list containing a set of selected users. |
---|
Administrator may use this API to configure users for an AuditLogRulesInfo.
AuditLogRulesInfo mAuditLogRulesInfo = new AuditLogRulesInfo(); List |
API level 17 |
KNOX 2.5 |