Merge "Adding SecurityException information to all device logging DPM public methods" into nyc-dev
am: 8fc5462ee1
* commit '8fc5462ee1f9b8e5b13d13b0920433b340fa6b6c':
Adding SecurityException information to all device logging DPM public methods
This commit is contained in:
@@ -2921,7 +2921,7 @@ public class DevicePolicyManager {
|
||||
* Called by a device owner to request a bugreport.
|
||||
*
|
||||
* <p>There must be only one user on the device, managed by the device owner.
|
||||
* Otherwise a security exception will be thrown.
|
||||
* Otherwise a {@link SecurityException} will be thrown.
|
||||
*
|
||||
* @param admin Which {@link DeviceAdminReceiver} this request is associated with.
|
||||
* @return {@code true} if the bugreport collection started successfully, or {@code false}
|
||||
@@ -5686,6 +5686,9 @@ public class DevicePolicyManager {
|
||||
* <p> Device logs contain various information intended for security auditing purposes.
|
||||
* See {@link SecurityEvent} for details.
|
||||
*
|
||||
* <p>There must be only one user on the device, managed by the device owner.
|
||||
* Otherwise a {@link SecurityException} will be thrown.
|
||||
*
|
||||
* @param admin Which device owner this request is associated with.
|
||||
* @param enabled whether device logging should be enabled or not.
|
||||
* @see #retrieveDeviceLogs
|
||||
@@ -5701,6 +5704,9 @@ public class DevicePolicyManager {
|
||||
/**
|
||||
* Return whether device logging is enabled or not by the device owner.
|
||||
*
|
||||
* <p>Can only be called by the device owner, otherwise a {@link SecurityException} will be
|
||||
* thrown.
|
||||
*
|
||||
* @param admin Which device owner this request is associated with.
|
||||
* @return {@code true} if device logging is enabled by device owner, {@code false} otherwise.
|
||||
*/
|
||||
@@ -5720,6 +5726,9 @@ public class DevicePolicyManager {
|
||||
* <p> Access to the logs is rate limited and it will only return new logs after the device
|
||||
* owner has been notified via {@link DeviceAdminReceiver#onSecurityLogsAvailable}.
|
||||
*
|
||||
* <p>There must be only one user on the device, managed by the device owner.
|
||||
* Otherwise a {@link SecurityException} will be thrown.
|
||||
*
|
||||
* @param admin Which device owner this request is associated with.
|
||||
* @return the new batch of device logs which is a list of {@link SecurityEvent},
|
||||
* or {@code null} if rate limitation is exceeded or if logging is currently disabled.
|
||||
@@ -5764,6 +5773,9 @@ public class DevicePolicyManager {
|
||||
* result, this API is provided as best-effort and the returned logs may contain corrupted data.
|
||||
* </strong>
|
||||
*
|
||||
* <p>There must be only one user on the device, managed by the device owner.
|
||||
* Otherwise a {@link SecurityException} will be thrown.
|
||||
*
|
||||
* @param admin Which device owner this request is associated with.
|
||||
* @return Device logs from before the latest reboot of the system.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user