Home
last modified time | relevance | path

Searched refs:appUids (Results 1 – 6 of 6) sorted by relevance

/system/netd/server/
DTrafficControllerTest.cpp223 void expectUidOwnerMapValues(const std::vector<uint32_t>& appUids, uint8_t expectedRule, in expectUidOwnerMapValues() argument
225 for (uint32_t uid : appUids) { in expectUidOwnerMapValues()
244 void expectUidPermissionMapValues(const std::vector<uid_t>& appUids, uint8_t expectedValue) { in expectUidPermissionMapValues() argument
245 for (uid_t uid : appUids) { in expectUidPermissionMapValues()
254 void expectPrivilegedUserSet(const std::vector<uid_t>& appUids) { in expectPrivilegedUserSet() argument
256 EXPECT_EQ(appUids.size(), mTc.mPrivilegedUser.size()); in expectPrivilegedUserSet()
257 for (uid_t uid : appUids) { in expectPrivilegedUserSet()
619 std::vector<uint32_t> appUids = {1000, 1001, 10012}; in TEST_F() local
621 mTc.updateUidOwnerMap(appUids, PENALTY_BOX_MATCH, BandwidthController::IptOpInsert))); in TEST_F()
622 expectUidOwnerMapValues(appUids, PENALTY_BOX_MATCH, 0); in TEST_F()
[all …]
DBandwidthController.h49 int addNaughtyApps(const std::vector<uint32_t>& appUids);
50 int removeNaughtyApps(const std::vector<uint32_t>& appUids);
51 int addNiceApps(const std::vector<uint32_t>& appUids);
52 int removeNiceApps(const std::vector<uint32_t>& appUids);
DBandwidthController.cpp326 int BandwidthController::addNaughtyApps(const std::vector<uint32_t>& appUids) { in addNaughtyApps() argument
327 return manipulateSpecialApps(appUids, PENALTY_BOX_MATCH, IptOpInsert); in addNaughtyApps()
330 int BandwidthController::removeNaughtyApps(const std::vector<uint32_t>& appUids) { in removeNaughtyApps() argument
331 return manipulateSpecialApps(appUids, PENALTY_BOX_MATCH, IptOpDelete); in removeNaughtyApps()
334 int BandwidthController::addNiceApps(const std::vector<uint32_t>& appUids) { in addNiceApps() argument
335 return manipulateSpecialApps(appUids, HAPPY_BOX_MATCH, IptOpInsert); in addNiceApps()
338 int BandwidthController::removeNiceApps(const std::vector<uint32_t>& appUids) { in removeNiceApps() argument
339 return manipulateSpecialApps(appUids, HAPPY_BOX_MATCH, IptOpDelete); in removeNiceApps()
342 int BandwidthController::manipulateSpecialApps(const std::vector<uint32_t>& appUids, in manipulateSpecialApps() argument
344 Status status = gCtls->trafficCtrl.updateUidOwnerMap(appUids, matchType, op); in manipulateSpecialApps()
DNetdNativeService.cpp324 std::vector<uint32_t> appUids = {static_cast<uint32_t>(abs(uid))}; in bandwidthAddNaughtyApp() local
325 int res = gCtls->bandwidthCtrl.addNaughtyApps(appUids); in bandwidthAddNaughtyApp()
331 std::vector<uint32_t> appUids = {static_cast<uint32_t>(abs(uid))}; in bandwidthRemoveNaughtyApp() local
332 int res = gCtls->bandwidthCtrl.removeNaughtyApps(appUids); in bandwidthRemoveNaughtyApp()
338 std::vector<uint32_t> appUids = {static_cast<uint32_t>(abs(uid))}; in bandwidthAddNiceApp() local
339 int res = gCtls->bandwidthCtrl.addNiceApps(appUids); in bandwidthAddNiceApp()
345 std::vector<uint32_t> appUids = {static_cast<uint32_t>(abs(uid))}; in bandwidthRemoveNiceApp() local
346 int res = gCtls->bandwidthCtrl.removeNiceApps(appUids); in bandwidthRemoveNiceApp()
DTrafficController.cpp553 Status TrafficController::updateUidOwnerMap(const std::vector<uint32_t>& appUids, in updateUidOwnerMap() argument
557 for (uint32_t uid : appUids) { in updateUidOwnerMap()
/system/netd/tests/
Dbinder_test.cpp3011 std::vector<int32_t> appUids = {TEST_UID1, TEST_UID2}; in TEST_F() local
3013 mNetd->trafficSetNetPermForUids(INetd::PERMISSION_INTERNET, appUids); in TEST_F()
3014 checkUidsInPermissionMap(appUids, false); in TEST_F()
3015 mNetd->trafficSetNetPermForUids(INetd::PERMISSION_NONE, appUids); in TEST_F()
3016 checkUidsInPermissionMap(appUids, true); in TEST_F()
3017 mNetd->trafficSetNetPermForUids(INetd::PERMISSION_UNINSTALLED, appUids); in TEST_F()
3018 checkUidsInPermissionMap(appUids, false); in TEST_F()