Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dc3e2b35 authored by Stanislav Zholnin's avatar Stanislav Zholnin
Browse files

Add atom for logging of AppPermissionsFragment views.

Test: make statsd_testdrive && ./out/host/linux-x86/bin/statsd_testdrive -p com.google.android.permissioncontroller 217
Bug: 133401502
Bug: 134581123
Change-Id: I60e500e99a13a4f2dea6d7141fc87f5b8422c3a7
parent c9dda9ec
Loading
Loading
Loading
Loading
+32 −0
Original line number Diff line number Diff line
@@ -315,6 +315,8 @@ message Atom {
            215 [(log_from_module) = "permissioncontroller"];
        AppPermissionFragmentViewed app_permission_fragment_viewed =
            216 [(log_from_module) = "permissioncontroller"];
        AppPermissionsFragmentViewed app_permissions_fragment_viewed =
            217 [(log_from_module) = "permissioncontroller"];
    }

    // Pulled events will start at field 10000.
@@ -6682,3 +6684,33 @@ message AppPermissionFragmentViewed {
    // Permission group viewed
    optional string permission_group_name = 4;
}

/**
* Information about a AppPermissionsFragment viewed by user
*/
message AppPermissionsFragmentViewed {
    // id which identifies single session of user interacting with permission controller
    optional int64 session_id = 1;

    // id which identifies single view as every view might have several logging records
    // with different package information attached
    optional int64 view_id = 2;

    // Permission group viewed
    optional string permission_group_name = 3;

    // UID of package for which permissions are viewed
    optional int32 uid = 4 [(is_uid) = true];

    // Name of package for which permissions are viewed
    optional string package_name = 5;

    // Category in which permission is included
    enum Category {
      UNDEFINED = 0;
      ALLOWED = 1;
      ALLOWED_FOREGROUND = 2;
      DENIED = 3;
    }
    optional Category category = 6;
}