/system/netd/server/ |
D | UnreachableNetwork.cpp | 29 int UnreachableNetwork::addUsers(const UidRanges& uidRanges, uint32_t subPriority) { in addUsers() argument 30 if (!isValidSubPriority(subPriority) || !canAddUidRanges(uidRanges, subPriority)) { in addUsers() 34 int ret = RouteController::addUsersToUnreachableNetwork(mNetId, {{subPriority, uidRanges}}); in addUsers() 39 addToUidRangeMap(uidRanges, subPriority); in addUsers() 43 int UnreachableNetwork::removeUsers(const UidRanges& uidRanges, uint32_t subPriority) { in removeUsers() argument 47 RouteController::removeUsersFromUnreachableNetwork(mNetId, {{subPriority, uidRanges}}); in removeUsers() 52 removeFromUidRangeMap(uidRanges, subPriority); in removeUsers()
|
D | Network.cpp | 90 for (const auto& [priority, uidRanges] : mUidRangeMap) { in appliesToUser() 91 if (uidRanges.hasUid(uid)) { in appliesToUser() 99 void Network::addToUidRangeMap(const UidRanges& uidRanges, uint32_t subPriority) { in addToUidRangeMap() argument 102 iter->second.add(uidRanges); in addToUidRangeMap() 104 mUidRangeMap[subPriority] = uidRanges; in addToUidRangeMap() 108 void Network::removeFromUidRangeMap(const UidRanges& uidRanges, uint32_t subPriority) { in removeFromUidRangeMap() argument 111 iter->second.remove(uidRanges); in removeFromUidRangeMap() 120 bool Network::canAddUidRanges(const UidRanges& uidRanges, uint32_t subPriority) const { in canAddUidRanges() argument 121 if (uidRanges.overlapsSelf()) { in canAddUidRanges() 122 ALOGE("uid range %s overlaps self", uidRanges.toString().c_str()); in canAddUidRanges() [all …]
|
D | VirtualNetwork.cpp | 34 int VirtualNetwork::addUsers(const UidRanges& uidRanges, uint32_t subPriority) { in addUsers() argument 35 if (!isValidSubPriority(subPriority) || !canAddUidRanges(uidRanges, subPriority)) { in addUsers() 41 {{subPriority, uidRanges}}); in addUsers() 47 addToUidRangeMap(uidRanges, subPriority); in addUsers() 51 int VirtualNetwork::removeUsers(const UidRanges& uidRanges, uint32_t subPriority) { in removeUsers() argument 56 {{subPriority, uidRanges}}); in removeUsers() 62 removeFromUidRangeMap(uidRanges, subPriority); in removeUsers()
|
D | PhysicalNetwork.cpp | 161 int PhysicalNetwork::addUsers(const UidRanges& uidRanges, uint32_t subPriority) { in addUsers() argument 162 if (!isValidSubPriority(subPriority) || !canAddUidRanges(uidRanges, subPriority)) { in addUsers() 168 {{subPriority, uidRanges}}); in addUsers() 174 addToUidRangeMap(uidRanges, subPriority); in addUsers() 178 int PhysicalNetwork::removeUsers(const UidRanges& uidRanges, uint32_t subPriority) { in removeUsers() argument 183 {{subPriority, uidRanges}}); in removeUsers() 189 removeFromUidRangeMap(uidRanges, subPriority); in removeUsers()
|
D | Network.h | 63 virtual void addToUidRangeMap(const UidRanges& uidRanges, uint32_t subPriority); 64 virtual void removeFromUidRangeMap(const UidRanges& uidRanges, uint32_t subPriority); 68 bool canAddUidRanges(const UidRanges& uidRanges, uint32_t subPriority) const;
|
D | UnreachableNetwork.h | 26 [[nodiscard]] int addUsers(const UidRanges& uidRanges, uint32_t subPriority) override; 27 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, uint32_t subPriority) override;
|
D | VirtualNetwork.h | 36 [[nodiscard]] int addUsers(const UidRanges& uidRanges, uint32_t subPriority) override; 37 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, uint32_t subPriority) override;
|
D | PhysicalNetwork.h | 45 [[nodiscard]] int addUsers(const UidRanges& uidRanges, uint32_t subPriority) override; 46 [[nodiscard]] int removeUsers(const UidRanges& uidRanges, uint32_t subPriority) override;
|
D | RouteController.cpp | 802 for (const auto& [subPriority, uidRanges] : uidRangeMap) { in modifyPhysicalNetwork() 803 for (const UidRangeParcel& range : uidRanges.getRanges()) { in modifyPhysicalNetwork() 915 for (const auto& [subPriority, uidRanges] : uidRangeMap) { in modifyUnreachableNetwork() 916 for (const UidRangeParcel& range : uidRanges.getRanges()) { in modifyUnreachableNetwork() 935 [[nodiscard]] static int modifyRejectNonSecureNetworkRule(const UidRanges& uidRanges, bool add) { in modifyRejectNonSecureNetworkRule() argument 941 for (const UidRangeParcel& range : uidRanges.getRanges()) { in modifyRejectNonSecureNetworkRule() 960 for (const auto& [subPriority, uidRanges] : uidRangeMap) { in modifyVirtualNetwork() 961 for (const UidRangeParcel& range : uidRanges.getRanges()) { in modifyVirtualNetwork() 1257 int RouteController::addUsersToRejectNonSecureNetworkRule(const UidRanges& uidRanges) { in addUsersToRejectNonSecureNetworkRule() argument 1258 return modifyRejectNonSecureNetworkRule(uidRanges, true); in addUsersToRejectNonSecureNetworkRule() [all …]
|
D | NetworkController.h | 122 [[nodiscard]] int addUsersToNetwork(unsigned netId, const UidRanges& uidRanges, 124 [[nodiscard]] int removeUsersFromNetwork(unsigned netId, const UidRanges& uidRanges,
|
D | RouteController.h | 134 [[nodiscard]] static int addUsersToRejectNonSecureNetworkRule(const UidRanges& uidRanges); 135 [[nodiscard]] static int removeUsersFromRejectNonSecureNetworkRule(const UidRanges& uidRanges);
|
D | SockDiag.h | 77 int destroySockets(const UidRanges& uidRanges, const std::set<uid_t>& skipUids,
|
/system/netd/server/aidl_api/netd_aidl_interface/7/android/net/netd/aidl/ |
D | NativeUidRangeConfig.aidl | 39 android.net.UidRangeParcel[] uidRanges;
|
/system/netd/server/aidl_api/netd_aidl_interface/current/android/net/netd/aidl/ |
D | NativeUidRangeConfig.aidl | 39 android.net.UidRangeParcel[] uidRanges;
|
/system/netd/server/binder/android/net/netd/aidl/ |
D | NativeUidRangeConfig.aidl | 33 UidRangeParcel[] uidRanges;
|
/system/netd/server/aidl_api/netd_aidl_interface/1/android/net/ |
D | INetd.aidl | 11 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 12 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 13 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 14 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/tests/ |
D | binder_test.cpp | 616 std::vector<UidRangeParcel>&& uidRanges, in makeNativeUidRangeConfig() argument 620 res.uidRanges = uidRanges; in makeNativeUidRangeConfig() 658 std::vector<UidRangeParcel> uidRanges = {makeUidRangeParcel(BASE_UID + 8005, BASE_UID + 8012), in TEST_F() local 663 EXPECT_TRUE(mNetd->networkAddUidRanges(TEST_NETID1, uidRanges).isOk()); in TEST_F() 665 EXPECT_TRUE(ipRuleExistsForRange(RULE_PRIORITY_SECURE_VPN, uidRanges[0], action)); in TEST_F() 667 EXPECT_TRUE(mNetd->networkRemoveUidRanges(TEST_NETID1, uidRanges).isOk()); in TEST_F() 668 EXPECT_FALSE(ipRuleExistsForRange(RULE_PRIORITY_SECURE_VPN, uidRanges[0], action)); in TEST_F() 670 EXPECT_TRUE(mNetd->networkAddUidRanges(TEST_NETID1, uidRanges).isOk()); in TEST_F() 671 EXPECT_TRUE(ipRuleExistsForRange(RULE_PRIORITY_SECURE_VPN, uidRanges[1], action)); in TEST_F() 673 EXPECT_FALSE(ipRuleExistsForRange(RULE_PRIORITY_SECURE_VPN, uidRanges[1], action)); in TEST_F() [all …]
|
/system/netd/server/aidl_api/netd_aidl_interface/2/android/net/ |
D | INetd.aidl | 28 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 29 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 30 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 31 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/3/android/net/ |
D | INetd.aidl | 29 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 30 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 31 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 32 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/4/android/net/ |
D | INetd.aidl | 29 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 30 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 31 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 32 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/7/android/net/ |
D | INetd.aidl | 51 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 52 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 53 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 54 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/6/android/net/ |
D | INetd.aidl | 51 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 52 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 53 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 54 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/binder/android/net/ |
D | INetd.aidl | 142 void networkAddUidRanges(int netId, in UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 155 void networkRemoveUidRanges(int netId, in UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 178 void networkRejectNonSecureVpn(boolean add, in UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 183 void socketDestroy(in UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/current/android/net/ |
D | INetd.aidl | 51 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 52 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 53 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 54 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|
/system/netd/server/aidl_api/netd_aidl_interface/5/android/net/ |
D | INetd.aidl | 29 void networkAddUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkAddUidRanges() argument 30 void networkRemoveUidRanges(int netId, in android.net.UidRangeParcel[] uidRanges); in networkRemoveUidRanges() argument 31 void networkRejectNonSecureVpn(boolean add, in android.net.UidRangeParcel[] uidRanges); in networkRejectNonSecureVpn() argument 32 void socketDestroy(in android.net.UidRangeParcel[] uidRanges, in int[] exemptUids); in socketDestroy() argument
|