Home
last modified time | relevance | path

Searched refs:UidRanges (Results 1 – 22 of 22) sorted by relevance

/system/netd/server/
DNetwork.h28 typedef std::map<int32_t, UidRanges> UidRangeMap;
54 [[nodiscard]] virtual int addUsers(const UidRanges&, int32_t /*subPriority*/) { in addUsers() argument
57 [[nodiscard]] virtual int removeUsers(const UidRanges&, int32_t /*subPriority*/) { in removeUsers() argument
66 virtual void addToUidRangeMap(const UidRanges& uidRanges, int32_t subPriority);
67 virtual void removeFromUidRangeMap(const UidRanges& uidRanges, int32_t subPriority);
69 void setAllowedUids(const UidRanges& uidRanges);
74 bool canAddUidRanges(const UidRanges& uidRanges) const;
79 std::map<int32_t, UidRanges> mUidRangeMap;
83 std::optional<UidRanges> mAllowedUids;
DUidRanges.cpp64 bool UidRanges::hasUid(uid_t uid) const { in hasUid()
77 const std::vector<UidRangeParcel>& UidRanges::getRanges() const { in getRanges()
81 bool UidRanges::parseFrom(int argc, char* argv[]) { in parseFrom()
122 UidRanges::UidRanges(const std::vector<UidRangeParcel>& ranges) { in UidRanges() function in android::net::UidRanges
127 void UidRanges::add(const UidRanges& other) { in add()
132 void UidRanges::remove(const UidRanges& other) { in remove()
138 bool UidRanges::overlapsSelf() const { in overlapsSelf()
150 std::string UidRanges::toString() const { in toString()
DUidRanges.h29 class UidRanges {
40 UidRanges() {} in UidRanges() function
41 UidRanges(const std::vector<android::net::UidRangeParcel>& ranges);
49 void add(const UidRanges& other);
50 void remove(const UidRanges& other);
DUnreachableNetwork.cpp29 int UnreachableNetwork::addUsers(const UidRanges& uidRanges, int32_t subPriority) { in addUsers()
43 int UnreachableNetwork::removeUsers(const UidRanges& uidRanges, int32_t subPriority) { in removeUsers()
57 return priority >= UidRanges::SUB_PRIORITY_HIGHEST && in isValidSubPriority()
58 priority <= UidRanges::SUB_PRIORITY_LOWEST; in isValidSubPriority()
DNetwork.cpp106 void Network::addToUidRangeMap(const UidRanges& uidRanges, int32_t subPriority) { in addToUidRangeMap()
115 void Network::removeFromUidRangeMap(const UidRanges& uidRanges, int32_t subPriority) { in removeFromUidRangeMap()
131 void Network::setAllowedUids(const UidRanges& uidRanges) { in setAllowedUids()
139 bool Network::canAddUidRanges(const UidRanges& uidRanges) const { in canAddUidRanges()
DUnreachableNetwork.h27 [[nodiscard]] int addUsers(const UidRanges& uidRanges, int32_t subPriority) override;
28 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, int32_t subPriority) override;
DVirtualNetwork.cpp35 int VirtualNetwork::addUsers(const UidRanges& uidRanges, int32_t subPriority) { in addUsers()
53 int VirtualNetwork::removeUsers(const UidRanges& uidRanges, int32_t subPriority) { in removeUsers()
97 return priority == UidRanges::SUB_PRIORITY_HIGHEST; in isValidSubPriority()
DPhysicalNetwork.cpp170 int PhysicalNetwork::addUsers(const UidRanges& uidRanges, int32_t subPriority) { in addUsers()
187 int PhysicalNetwork::removeUsers(const UidRanges& uidRanges, int32_t subPriority) { in removeUsers()
244 return (priority >= UidRanges::SUB_PRIORITY_HIGHEST && in isValidSubPriority()
245 priority <= UidRanges::SUB_PRIORITY_LOWEST) || in isValidSubPriority()
246 priority == UidRanges::SUB_PRIORITY_NO_DEFAULT; in isValidSubPriority()
DVirtualNetwork.h39 [[nodiscard]] int addUsers(const UidRanges& uidRanges, int32_t subPriority) override;
40 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, int32_t subPriority) override;
DPhysicalNetwork.h45 [[nodiscard]] int addUsers(const UidRanges& uidRanges, int32_t subPriority) override;
46 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, int32_t subPriority) override;
DNetworkController.h75 class UidRanges; variable
123 [[nodiscard]] int addUsersToNetwork(unsigned netId, const UidRanges& uidRanges,
125 [[nodiscard]] int removeUsersFromNetwork(unsigned netId, const UidRanges& uidRanges,
DRouteController.h88 class UidRanges; variable
153 [[nodiscard]] static int addUsersToRejectNonSecureNetworkRule(const UidRanges& uidRanges);
154 [[nodiscard]] static int removeUsersFromRejectNonSecureNetworkRule(const UidRanges& uidRanges);
DSockDiag.h77 int destroySockets(const UidRanges& uidRanges, const std::set<uid_t>& skipUids,
DRouteController.cpp769 UidRanges::SUB_PRIORITY_HIGHEST, ACTION_ADD)) { in addLocalNetworkRules()
801 INVALID_UID, UidRanges::SUB_PRIORITY_HIGHEST, in configureDummyNetwork()
835 INVALID_UID, INVALID_UID, UidRanges::SUB_PRIORITY_HIGHEST, in modifyLocalNetwork()
910 if (subPriority != UidRanges::SUB_PRIORITY_NO_DEFAULT) { in modifyPhysicalNetwork()
935 UidRanges::SUB_PRIORITY_HIGHEST, add)) { in modifyPhysicalNetwork()
944 UidRanges::SUB_PRIORITY_HIGHEST, add)) { in modifyPhysicalNetwork()
1073 [[nodiscard]] static int modifyRejectNonSecureNetworkRule(const UidRanges& uidRanges, bool add) { in modifyRejectNonSecureNetworkRule()
1127 UidRanges::SUB_PRIORITY_HIGHEST, add); in modifyVirtualNetwork()
1419 int RouteController::addUsersToRejectNonSecureNetworkRule(const UidRanges& uidRanges) { in addUsersToRejectNonSecureNetworkRule()
1423 int RouteController::removeUsersFromRejectNonSecureNetworkRule(const UidRanges& uidRanges) { in removeUsersFromRejectNonSecureNetworkRule()
DAndroid.bp65 "UidRanges.cpp",
192 "UidRanges.cpp",
DNetworkController.cpp637 int NetworkController::addUsersToNetwork(unsigned netId, const UidRanges& uidRanges, in addUsersToNetwork()
647 int NetworkController::removeUsersFromNetwork(unsigned netId, const UidRanges& uidRanges, in removeUsersFromNetwork()
844 network->setAllowedUids(UidRanges(config.uidRanges)); in setNetworkAllowlist()
892 int32_t bestSubPriority = UidRanges::SUB_PRIORITY_NO_DEFAULT; in getPhysicalOrUnreachableNetworkForUserLocked()
897 if (subPriority == UidRanges::SUB_PRIORITY_NO_DEFAULT) continue; in getPhysicalOrUnreachableNetworkForUserLocked()
DNetdNativeService.cpp331 int ret = gCtls->netCtrl.addUsersToNetwork(netId, UidRanges(uidRangeArray), in networkAddUidRanges()
332 UidRanges::SUB_PRIORITY_HIGHEST); in networkAddUidRanges()
340 int ret = gCtls->netCtrl.removeUsersFromNetwork(netId, UidRanges(uidRangeArray), in networkRemoveUidRanges()
341 UidRanges::SUB_PRIORITY_HIGHEST); in networkRemoveUidRanges()
347 int ret = gCtls->netCtrl.addUsersToNetwork(config.netId, UidRanges(config.uidRanges), in networkAddUidRangesParcel()
354 int ret = gCtls->netCtrl.removeUsersFromNetwork(config.netId, UidRanges(config.uidRanges), in networkRemoveUidRangesParcel()
367 UidRanges uidRanges(uidRangeArray); in networkRejectNonSecureVpn()
388 UidRanges uidRanges(uids); in socketDestroy()
DRouteControllerTest.cpp155 std::map<int32_t, UidRanges> uidRangeMap; in TEST_F()
DSockDiag.cpp433 int SockDiag::destroySockets(const UidRanges& uidRanges, const std::set<uid_t>& skipUids, in destroySockets()
DSockDiagTest.cpp390 UidRanges uidRanges; in destroySockets()
DNdcDispatcher.cpp1153 UidRanges uidRanges; in runCommand()
/system/netd/tests/
Dbinder_test.cpp137 using android::net::UidRanges;
4172 constexpr int SUB_PRIORITY_1 = UidRanges::SUB_PRIORITY_HIGHEST + 1;
4173 constexpr int SUB_PRIORITY_2 = UidRanges::SUB_PRIORITY_HIGHEST + 2;
4284 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4287 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4290 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4294 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4297 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4300 UidRanges::SUB_PRIORITY_HIGHEST); in TEST_F()
4935 UidRanges::SUB_PRIORITY_HIGHEST - 10); in TEST_F()
[all …]