Home
last modified time | relevance | path

Searched refs:UidRange (Results 1 – 13 of 13) sorted by relevance

/frameworks/base/services/tests/servicestests/src/com/android/server/connectivity/
DVpnTest.java31 import android.net.UidRange;
107 final Set<UidRange> ranges = vpn.createUserAndRestrictedProfilesRanges(primaryUser.id, in testRestrictedProfilesAreAddedToVpn()
110 assertEquals(new ArraySet<>(Arrays.asList(new UidRange[] { in testRestrictedProfilesAreAddedToVpn()
111 UidRange.createForUser(primaryUser.id), in testRestrictedProfilesAreAddedToVpn()
112 UidRange.createForUser(restrictedProfileA.id) in testRestrictedProfilesAreAddedToVpn()
121 final Set<UidRange> ranges = vpn.createUserAndRestrictedProfilesRanges(primaryUser.id, in testManagedProfilesAreNotAddedToVpn()
124 assertEquals(new ArraySet<>(Arrays.asList(new UidRange[] { in testManagedProfilesAreNotAddedToVpn()
125 UidRange.createForUser(primaryUser.id) in testManagedProfilesAreNotAddedToVpn()
134 final Set<UidRange> ranges = new ArraySet<>(); in testAddUserToVpnOnlyAddsOneUser()
137 assertEquals(new ArraySet<>(Arrays.asList(new UidRange[] { in testAddUserToVpnOnlyAddsOneUser()
[all …]
/frameworks/base/core/java/android/net/
DUidRange.java31 public final class UidRange implements Parcelable { class
35 public UidRange(int startUid, int stopUid) { in UidRange() method in UidRange
43 public static UidRange createForUser(int userId) { in createForUser()
44 return new UidRange(userId * PER_USER_RANGE, (userId + 1) * PER_USER_RANGE - 1); in createForUser()
58 public boolean containsRange(UidRange other) { in containsRange()
75 if (o instanceof UidRange) { in equals()
76 UidRange other = (UidRange) o; in equals()
99 public static final Creator<UidRange> CREATOR =
100 new Creator<UidRange>() {
102 public UidRange createFromParcel(Parcel in) {
[all …]
DNetworkAgent.java396 public void addUidRanges(UidRange[] ranges) { in addUidRanges()
404 public void removeUidRanges(UidRange[] ranges) { in removeUidRanges()
/frameworks/base/services/tests/servicestests/src/android/net/
DUidRangeTest.java38 UidRange original = new UidRange(1234, Integer.MAX_VALUE); in testNativeParcelUnparcel()
42 UidRange roundTrip = unmarshall(outParcel); in testNativeParcelUnparcel()
50 UidRange original = new UidRange(0x11115678, 0x22224321); in testIndividualNativeFields()
59 new UidRange(123, 123); in testSingleItemUidRangeAllowed()
60 new UidRange(0, 0); in testSingleItemUidRangeAllowed()
61 new UidRange(Integer.MAX_VALUE, Integer.MAX_VALUE); in testSingleItemUidRangeAllowed()
67 new UidRange(-2, 100); in testNegativeUidsDisallowed()
73 new UidRange(-200, -100); in testNegativeUidsDisallowed()
83 new UidRange(x, x - 1); in testStopLessThanStartDisallowed()
94 private static byte[] marshall(UidRange range) { in marshall()
[all …]
/frameworks/base/services/tests/servicestests/jni/
DUidRangeTest.cpp23 using android::net::UidRange;
28 const UidRange range = unmarshall(env, inParcel); in Java_android_net_UidRangeTest_readAndWriteNative()
34 const UidRange range = unmarshall(env, inParcel); in Java_android_net_UidRangeTest_getStart()
40 const UidRange range = unmarshall(env, inParcel); in Java_android_net_UidRangeTest_getStop()
49 UidRange unmarshall(JNIEnv* env, jbyteArray parcelData) { in unmarshall()
58 UidRange range; in unmarshall()
70 jbyteArray marshall(JNIEnv* env, const UidRange& range) { in marshall()
DUidRangeTest.h24 android::net::UidRange unmarshall(JNIEnv* env, jbyteArray parcelData);
26 jbyteArray marshall(JNIEnv* env, const android::net::UidRange& range);
/frameworks/base/services/core/java/com/android/server/connectivity/
DVpn.java56 import android.net.UidRange;
157 private Set<UidRange> mVpnUsers = null;
165 private Set<UidRange> mBlockedUsers = new ArraySet<>();
670 mNetworkAgent.addUidRanges(mVpnUsers.toArray(new UidRange[mVpnUsers.size()])); in agentConnect()
754 Set<UidRange> oldUsers = mVpnUsers; in establish()
855 Set<UidRange> createUserAndRestrictedProfilesRanges(@UserIdInt int userHandle, in createUserAndRestrictedProfilesRanges()
858 final Set<UidRange> ranges = new ArraySet<>(); in createUserAndRestrictedProfilesRanges()
895 void addUserToRanges(@NonNull Set<UidRange> ranges, @UserIdInt int userHandle, in addUserToRanges()
905 ranges.add(new UidRange(start, stop)); in addUserToRanges()
910 if (start != -1) ranges.add(new UidRange(start, stop)); in addUserToRanges()
[all …]
/frameworks/base/core/java/android/os/
DINetworkManagementService.aidl25 import android.net.UidRange;
348 void addVpnUidRanges(int netId, in UidRange[] ranges); in addVpnUidRanges()
353 void removeVpnUidRanges(int netId, in UidRange[] ranges); in removeVpnUidRanges()
440 void setAllowOnlyVpnForUids(boolean enable, in UidRange[] uidRanges); in setAllowOnlyVpnForUids()
/frameworks/base/services/core/java/com/android/server/
DNetworkManagementService.java63 import android.net.UidRange;
1853 public void setAllowOnlyVpnForUids(boolean add, UidRange[] uidRanges) in setAllowOnlyVpnForUids()
2037 public void addVpnUidRanges(int netId, UidRange[] ranges) { in addVpnUidRanges()
2059 public void removeVpnUidRanges(int netId, UidRange[] ranges) { in removeVpnUidRanges()
2135 UidRange[] ranges; in closeSocketsForFirewallChainLocked()
2144 ranges = new UidRange[] { in closeSocketsForFirewallChainLocked()
2147 new UidRange(Process.FIRST_APPLICATION_UID, Integer.MAX_VALUE), in closeSocketsForFirewallChainLocked()
2169 ranges = new UidRange[rules.size()]; in closeSocketsForFirewallChainLocked()
2173 ranges[numUids] = new UidRange(uid, uid); in closeSocketsForFirewallChainLocked()
DConnectivityService.java76 import android.net.UidRange;
2071 mNetd.addVpnUidRanges(nai.network.netId, (UidRange[])msg.obj); in maybeHandleNetworkAgentMessage()
2080 mNetd.removeVpnUidRanges(nai.network.netId, (UidRange[])msg.obj); in maybeHandleNetworkAgentMessage()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/mocks/
DConnectivityServiceMock.java73 import android.net.UidRange;
/frameworks/base/
DAndroid.mk701 system/netd/server/binder/android/net/UidRange.aidl \
Dcompiled-classes-phone2765 android.net.UidRange