From a31a27288fea1228b16f456fcac12c4374d35f43 Mon Sep 17 00:00:00 2001 From: joonhunshin Date: Wed, 22 Nov 2023 06:35:18 +0000 Subject: Add feature flagging to enforce telephony features for public APIs and CTS. Bug: 297989574 Test: build pass Change-Id: If26eb0205340b19e079f13b787af7581d1fd067b --- flags/telephony.aconfig | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/flags/telephony.aconfig b/flags/telephony.aconfig index f60885b5f9..b849d53e64 100644 --- a/flags/telephony.aconfig +++ b/flags/telephony.aconfig @@ -5,4 +5,11 @@ flag { namespace: "telephony" description: "This flag controls telephony feature flags mapping." bug:"297989574" -} \ No newline at end of file +} + +flag { + name: "enforce_telephony_feature_mapping_for_public_apis" + namespace: "telephony" + description: "This flag controls telephony feature flags mapping for public APIs and CTS." + bug:"297989574" +} -- cgit v1.2.3 From 3f289473f91c18308c82c9b84d100e876a0ae211 Mon Sep 17 00:00:00 2001 From: arunvoddu Date: Tue, 28 Nov 2023 07:48:12 +0000 Subject: Changing the visibility of getCarrierRestrictionStatus API to public with flagged annotation Bug: 313553044 Test: Built Successfully and verified cts Change-Id: I590c97795715a6d1f6d5726cf504a5ce9a5cd564 --- flags/uicc.aconfig | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/flags/uicc.aconfig b/flags/uicc.aconfig index 3ef2301650..b2024b006e 100644 --- a/flags/uicc.aconfig +++ b/flags/uicc.aconfig @@ -11,4 +11,10 @@ flag { namespace: "telephony" description: "This flag controls to download the IMSI encryption keys after user unlocks the phone." bug:"303780982" +} +flag { + name: "carrier_restriction_status" + namespace: "telephony" + description: "This flag control the visibility of the getCarrierRestrictionStatus in carrierRestrictionRules class." + bug:"313553044" } \ No newline at end of file -- cgit v1.2.3 From ea8607eb11b65fec2e7938f4631f54e7e6365daf Mon Sep 17 00:00:00 2001 From: Hyosun Kim Date: Tue, 12 Dec 2023 13:51:02 +0000 Subject: Change the default infrastructure value to 'cellular|satellite'. Bug: 315080816 Test: atest ApnSettingTest Test: atest DataProfileManagerTest Test: manual test After NTN is connected, SMS/MMS is working and Internet/Voice Call is blocked. Change-Id: I3af5dfc72865624de9db14409b2f33a221b1f026 --- .../internal/telephony/data/ApnSettingTest.java | 33 ++++++++++++++++++++++ .../telephony/data/DataProfileManagerTest.java | 7 +++++ 2 files changed, 40 insertions(+) diff --git a/tests/telephonytests/src/com/android/internal/telephony/data/ApnSettingTest.java b/tests/telephonytests/src/com/android/internal/telephony/data/ApnSettingTest.java index 98d3ce5b61..378df4b944 100644 --- a/tests/telephonytests/src/com/android/internal/telephony/data/ApnSettingTest.java +++ b/tests/telephonytests/src/com/android/internal/telephony/data/ApnSettingTest.java @@ -16,6 +16,9 @@ package com.android.internal.telephony.data; +import static android.telephony.data.ApnSetting.INFRASTRUCTURE_CELLULAR; +import static android.telephony.data.ApnSetting.INFRASTRUCTURE_SATELLITE; + import static junit.framework.Assert.assertFalse; import static junit.framework.Assert.assertTrue; import static junit.framework.Assert.fail; @@ -381,4 +384,34 @@ public class ApnSettingTest extends TelephonyTest { .build(); assertEquals("proxy.mobile.att.net", apn3.getMmsProxyAddressAsString()); } + + @Test + public void testBuild_InfrastructureBitmask() { + int infrastructureBitmask = INFRASTRUCTURE_CELLULAR | INFRASTRUCTURE_SATELLITE; + ApnSetting apn1 = new ApnSetting.Builder() + .setId(1234) + .setOperatorNumeric("310260") + .setEntryName("mms") + .setApnName("mms") + .setApnTypeBitmask(ApnSetting.TYPE_MMS | ApnSetting.TYPE_DEFAULT) + .setProtocol(ApnSetting.PROTOCOL_IPV4V6) + .setNetworkTypeBitmask((int) (TelephonyManager.NETWORK_TYPE_BITMASK_LTE)) + .build(); + // InfrastructureBitmask default value set to '3(cellular|satellite)' + assertEquals(infrastructureBitmask, apn1.getInfrastructureBitmask()); + + infrastructureBitmask = INFRASTRUCTURE_CELLULAR; + ApnSetting apn2 = new ApnSetting.Builder() + .setId(1235) + .setOperatorNumeric("310260") + .setEntryName("mms") + .setApnName("mms") + .setApnTypeBitmask(ApnSetting.TYPE_MMS | ApnSetting.TYPE_DEFAULT) + .setProtocol(ApnSetting.PROTOCOL_IPV4V6) + .setNetworkTypeBitmask((int) (TelephonyManager.NETWORK_TYPE_BITMASK_LTE)) + .setInfrastructureBitmask(infrastructureBitmask) + .build(); + // InfrastructureBitmask value set to '1(cellular)' + assertEquals(infrastructureBitmask, apn2.getInfrastructureBitmask()); + } } diff --git a/tests/telephonytests/src/com/android/internal/telephony/data/DataProfileManagerTest.java b/tests/telephonytests/src/com/android/internal/telephony/data/DataProfileManagerTest.java index ff14f9a262..e556cb877e 100644 --- a/tests/telephonytests/src/com/android/internal/telephony/data/DataProfileManagerTest.java +++ b/tests/telephonytests/src/com/android/internal/telephony/data/DataProfileManagerTest.java @@ -1611,6 +1611,7 @@ public class DataProfileManagerTest extends TelephonyTest { | TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(DEFAULT_APN_SET_ID) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1646,6 +1647,7 @@ public class DataProfileManagerTest extends TelephonyTest { .setNetworkTypeBitmask((int) (TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(DEFAULT_APN_SET_ID) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1674,6 +1676,7 @@ public class DataProfileManagerTest extends TelephonyTest { | TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(APN_SET_ID_1) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1702,6 +1705,7 @@ public class DataProfileManagerTest extends TelephonyTest { | TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(MATCH_ALL_APN_SET_ID) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1737,6 +1741,7 @@ public class DataProfileManagerTest extends TelephonyTest { | TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(APN_SET_ID_1) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1765,6 +1770,7 @@ public class DataProfileManagerTest extends TelephonyTest { .setNetworkTypeBitmask((int) (TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(DEFAULT_APN_SET_ID) + .setInfrastructureBitmask(1) .build()) .build(); @@ -1793,6 +1799,7 @@ public class DataProfileManagerTest extends TelephonyTest { | TelephonyManager.NETWORK_TYPE_BITMASK_NR)) .setMvnoMatchData("") .setApnSetId(MATCH_ALL_APN_SET_ID) + .setInfrastructureBitmask(1) .build()) .build(); -- cgit v1.2.3 From 0d8580cb0d8f856490dd3eb89c12da29b586c826 Mon Sep 17 00:00:00 2001 From: Jack Yu Date: Wed, 13 Dec 2023 16:06:59 -0800 Subject: Removed a feature flag This is the actual bug and need to be fixed immediately. Bug: 315750601 Test: Basic telephony functionality tests Change-Id: I92da19bd0553b6c0510443a33ed1e53f814927ed --- flags/misc.aconfig | 7 ------- 1 file changed, 7 deletions(-) diff --git a/flags/misc.aconfig b/flags/misc.aconfig index 7f40596014..835efeefce 100644 --- a/flags/misc.aconfig +++ b/flags/misc.aconfig @@ -50,13 +50,6 @@ flag { bug: "310594186" } -flag { - name: "load_dds_on_create" - namespace: "telephony" - description: "Load default data subid on create in PhoneGlobals." - bug: "310591561" -} - flag { name: "enable_telephony_analytics" namespace: "telephony" -- cgit v1.2.3