2605 Commits

Author SHA1 Message Date
Jeff Davidson
35cda39422 Squashed merge of master-sim into master.
Includes the following commits:

==

New system feature: eUICC.

Presence of this feature implies that eUICC-related APIs are expected
to function as long as an eUICC is present in the device. Note that an
eUICC may be embedded in the device but may also be removable.

==

Add empty EuiccManager API and plumbing.

==

Add stub EuiccService.

EuiccService is the class that the LPA app must implement; for now,
just define the action and priority so that the implementation can be
found. Actual methods will come later.

Also declare two relevant permissions: BIND_EUICC_SERVICE, which the
implementation must require (so that nobody else can bind to the
service directly), and WRITE_EMBEDDED_SUBSCRIPTIONS, which permits
signature|privileged apps and CTS (via development) to access
EuiccManager APIs.

==

Add UiccAccessRule based off UiccCarrierPrivilegeRules#AccessRule.

This class can be used to transfer access rules between an
EuiccService implementation and the platform.

We also add a simple encoding/decoding of a list of rules so that they
may be stored in the subscription info table.

==

Add getEid() to EuiccManager/EuiccService.

getEid() fetches the EID. It requires either a privileged permission
(READ_PRIVILEGED_PHONE_STATE) or carrier privileges on the
currently-active profile. Until there is a use case that requires
opening this up to apps with only READ_PHONE_STATE, we shouldn't do
so.

To avoid churn in the future, the API signatures for EuiccService
include a slot ID to identify which SIM slot is being used. However,
this parameter is currently not populated correctly (nor is it usable,
as no Telephony APIs accept a slot ID to address commands). There is
no need to expose it yet in the EuiccManager APIs as we expect to
follow the TelephonyManager pattern of allowing per-slot instances of
EuiccManager in the future while keeping other method signatures the
same.

==

Define Euicc UI actions in EuiccManager/EuiccService.

The EuiccManager actions are to be implemented by the platform (and
only the platform), which forwards the actions to the active
implementation.

Also, remove our explicit priority meta-data tag as we can just rely
on android:priority in the corresponding intent-filter.

==

APIs for downloading embedded subscriptions.

Includes:

-getDownloadableSubscriptionMetadata, used by the platform and LUI to
fetch metadata about a downloadable subscription. The platform will
use this to perform the necessary permission checks (only allowing
otherwise-unprivileged apps to download profiles that are permitted
per the subscription metadata), and the LUI can use this to present
the name of the profile.

-downloadSubscription, to actually perform a profile download.

The stub for startResolutionActivity is included but not implemented;
resolution activities will be handled in a follow-up change.

==

Test: TreeHugger
Change-Id: I47b1da5a69f0736012cb137e02cd6c4e07fdaace
2017-04-03 11:17:53 -07:00
Brad Ebinger
ae8a95883b Merge "Remove non-localized message" am: ddbd256954 am: 70a09c00e5
am: 9c7b7f0de7

Change-Id: Ifc9f2278c7497f357b7db82ed27e6083351bf84b
2017-03-28 22:44:30 +00:00
Brad Ebinger
70a09c00e5 Merge "Remove non-localized message"
am: ddbd256954

Change-Id: Ia0fb7f8facca6d15485bf98f2a0538338a878962
2017-03-28 22:35:36 +00:00
Brad Ebinger
ddbd256954 Merge "Remove non-localized message" 2017-03-28 22:21:54 +00:00
Robert Greenwalt
f8966a0a50 Merge "Correct ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS" am: 07be9a0ef9 am: 79bde60db2
am: 8072754768

Change-Id: Iff682d4d9dc83544c0fce49c98d4c10563bf6317
2017-03-28 16:45:00 +00:00
Robert Greenwalt
79bde60db2 Merge "Correct ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS"
am: 07be9a0ef9

Change-Id: I3158ce88ca76a3ad4e8894f514030b31ae40f1fb
2017-03-28 16:20:57 +00:00
Robert Greenwalt
7811b34b36 Correct ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS
The name is not allowed for an internal, non-public
intent.  Changed to use com.android.internal.* namespace.

bug:35266833
Test: Ran cts.IntentTest.shouldNotFindUnexpectedIntents
Change-Id: Ifd7d7f0aa537bfbbc7d67aa3b73b0887acd6104a
2017-03-27 22:43:15 +00:00
Jack Yu
9b7d3a86bd Merge "Deprecated getDeviceId and added getMeid and getImei"
am: ad2e7405ad

Change-Id: I4e006290c54a371fc5f080c37f86ca946507d871
2017-03-24 17:10:54 +00:00
Shuto Nagamatsu
e74c8103a4 Remove non-localized message
Remove non-localized english "code" from ImsException constructor.
Non-localized message causes user confusion.

Bug: 32792378
Change-Id: I0c71c35e7830db7de5b1d041211de54c92285b4d
2017-03-24 08:03:49 +09:00
Jack Yu
f301dab471 Deprecated getDeviceId and added getMeid and getImei
Added two new public APIs getMeid and getImei. Deprecated the exisintg
getDeviceId API because it can't return a constant id when phone type
changes.

Test: CTS and manual
bug: 34233620, 10831289

Merged-In: Iad4c05d2fd2efc538214f466861497c973882dfe
Change-Id: Iad4c05d2fd2efc538214f466861497c973882dfe
2017-03-23 14:42:33 -07:00
Jack Yu
0dc3b9104b Deprecated getDeviceId and added getMeid and getImei
Added two new public APIs getMeid and getImei. Deprecated the exisintg
getDeviceId API because it can't return a constant id when phone type
changes.

Test: CTS and manual
bug: 34233620, 10831289

Change-Id: Iad4c05d2fd2efc538214f466861497c973882dfe
2017-03-23 14:35:38 -07:00
Jeff Davidson
f7368e05b4 Merge "Move IccUtils to reflect Java package declaration." 2017-03-23 17:08:45 +00:00
Sanket Padawe
bdee77da38 Merge "Change 'idx' to 'index' in SubscriptionManager & TelephonyManager apis."
am: 1df4c1ae54

Change-Id: I9233a85edb9321faaeb3f7813d4020159e52b691
2017-03-23 00:45:37 +00:00
fionaxu
388eab4147 sendDialerCode API review
1. address the feeback from API review:
throw exception rather than a boolean return
throw Security exception for permission denial and non-default dailer app.
throw invalidStateException if telephonyServie unavaialble.
2. sendDialerCode API will only check permission and package match without
enforcing the format of secret code(*#*# CODE #*#*) as throwing an unchecked
exception for wrong bad format seems to be an overkill regarding the API usage.
Dialer calls this API for each keyboard press to check format and send the intent
altogether which is no longer appropriate if we plan to return void and will
reduce frquent API calls.
3. allow callers with carrier privilege
4. not require MODIFY_PHONE_STATE as third party dialer apps won't be
granted
5. TODO mark android.provider.Telephony.SECRET_CODE to be protected
after calling apps move to this API.

Bug:35767402
Test: Manual
Change-Id: I8287aa93f2f79d356935a48cf808705d9b49984b
2017-03-22 16:56:38 -07:00
Sanket Padawe
1df4c1ae54 Merge "Change 'idx' to 'index' in SubscriptionManager & TelephonyManager apis." 2017-03-22 21:27:22 +00:00
Sanket Padawe
90e022a73c Change 'idx' to 'index' in SubscriptionManager & TelephonyManager apis.
Bug: 35767068
Test: No build failure.
Change-Id: I3b15901ff18742b5e99f03e74a6412d352461458
Merged-in: I3b15901ff18742b5e99f03e74a6412d352461458
2017-03-21 22:29:12 +00:00
Sanket Padawe
980231f317 Merge "Change 'idx' to 'index' in SubscriptionManager & TelephonyManager apis." 2017-03-21 22:13:02 +00:00
Sanket Padawe
7e46025199 Change 'idx' to 'index' in SubscriptionManager & TelephonyManager apis.
Bug: 35767068
Test: No build failure.
Change-Id: I3b15901ff18742b5e99f03e74a6412d352461458
2017-03-21 11:31:29 -07:00
Jack Yu
e3070ede55 Added ETWS primary message default message support
ETWS primary message does not contain messagy body. We used
to use hardcoded "ETWS" as the body, which is not easy for
end users to understand what happened. Added the built-in
default messages provided by Japanese government guideline
for earthquake, Tsunami, test, and other channels support to
enhance the user experience.

Test: manual
bug: 33595007
Change-Id: I53659298d8ce3b3ba5c751c14c1b36e76d6dc562
2017-03-20 22:37:50 -07:00
Jeff Davidson
46d7fbed6b Move IccUtils to reflect Java package declaration.
This class was in com/android/internal/telephony but declared itself
in com.android.internal.telephony.uicc. Mismatches here make IDEs
unhappy when resolving imports, and only the latter is used in
compilation, so consolidate on the latter.

Test: N/A (will rely on TreeHugger)
Change-Id: I598341bacbd70947b6e2789b2e543879cd41a4c9
2017-03-21 00:08:18 +00:00
Jayachandran Chinnakkannu
e7cd345537 Merge "Add new precise call fail causes and OEM causes" am: 9aa841d254 am: 4992b1533e
am: a7c4fdbf03

Change-Id: Iea9ee9c4a407638dfa19669b25d0c1534978d4a6
2017-03-17 22:41:35 +00:00
Jayachandran Chinnakkannu
4992b1533e Merge "Add new precise call fail causes and OEM causes"
am: 9aa841d254

Change-Id: I2b52c9c332fc73a37ac2c4c492ac9b85b2025897
2017-03-17 22:27:11 +00:00
Jayachandran C
5cbadddff2 Add new precise call fail causes and OEM causes
Bug: 35609963
Change-Id: Ia0579721e7132950ccfafd7be38f43d1963c016c
2017-03-16 15:43:41 -07:00
TreeHugger Robot
76c27d8b04 Merge "Update VVM API" 2017-03-10 18:40:00 +00:00
Brad Ebinger
6202c5e005 Merge "Disable a phone number log for user build" am: 59a40691a5 am: d31314d550
am: c906a167cb

Change-Id: I0c1bef7c7b436dcee5dfc8a06e8141f7757d7199
2017-03-10 00:03:18 +00:00
Brad Ebinger
d31314d550 Merge "Disable a phone number log for user build"
am: 59a40691a5

Change-Id: I9b2a14b29fe5e096b734b6e3f1d4b65806753646
2017-03-09 21:46:39 +00:00
Ta-wei Yen
3f5858efa0 Update VVM API
+ TelephonyManager.getVisualVoicemailPackageName() uses pinned subId
  from the manager.
+ TelephonyManager.getNetworkSpecifier() updated doc to explain what
  a network specifier is.
+ TelephonyManager.getCarrierConfig() Annotated with @WorkerThread
  specified failure behavior.
+ VisualVoicemailSms.getFields() Doc specified values are carrier
  dependent.

- Hide DEFAULT_* from VisualVociemaliSmsFitelrSettings

Test: CTS TelephonyManagerTest
Bug: 35766748
Fixes: 35766370
Fixes: 35766489
Change-Id: If48d48a0cf588bcb59c7b77ce6a452d2fda7bfa5
2017-03-07 14:29:49 -08:00
TreeHugger Robot
cce5466f93 Merge "Throw SecurityException in sendVisualVoicemailSms()" 2017-03-07 21:18:18 +00:00
youhei.x.miyoshi
b3cd7b51d3 Disable a phone number log for user build
A phone number is privacy data. Therefore, it should be prevented
from logging in user build.

Test: manual - checked log
Bug: 34582911
Change-Id: Id040653dbfd236250e7eb07c9c2e9587ded3d63f
2017-03-06 14:53:10 +09:00
Ta-wei Yen
49f3756b59 Throw SecurityException in sendVisualVoicemailSms()
Previously if the caller is not the active VVM service, the exception
will be consumed by the Binder because it is a oneway method.

This CL changes the method to non-oneway so the caller will receive
the exception. Docs are also updated.

Change-Id: Iedf96539be3958a92e151b926ee069d6edfc4d09
Fixes: 35854031
Test: CTS - VisualVoicemailServiceTest
2017-03-03 16:36:05 -08:00
Nathan Harold
b94d28acb5 Move newFromRil() function to a utility class
Remove a dependency on frameworks/opt from SmsMessage for CDMA

-Code move to frameworks/opt/telephony../cdma/SmsMessageConverter

Bug: 33414487
Test: Manually verified GSM and CDMA SMS: MO and MT
Change-Id: I730d292c4aad6524b03b18c0751738a73a71ecf7
2017-03-03 10:10:08 -08:00
Nathan Harold
5a0618ead1 Port Utility Functions from DefaultPhoneNotifier
-Move static utility functions from frameworks/opt/telephony/
 ..DefaultPhoneNotifier to a new utility class in frameworks/base

-Update TelephonyRegistry to point to the new functions.

Bug: 33414487
Test: compilation
Change-Id: I36a113cb5122569d451ec3a2dfa71d72d590fa52
2017-03-03 10:10:08 -08:00
Dan Willemsen
4980bf4aff Merge branch 'stage-telephony-refactor' into master
Bug: 33644781
Change-Id: If571e3ad9432035811714e3a92d9dfff39311c61
2017-03-03 10:10:08 -08:00
Jack Yu
01cfdb4f3a Merge "Added two new RIL commands support"
am: d7b60d7869

Change-Id: I28f1e0192db63a302daa69c2e6b13762fcbfb37b
2017-03-02 06:11:24 +00:00
Jack Yu
1bab118bed Added two new RIL commands support
Added RIL_REQUEST_SEND_DEVICE_STATE and
RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER RIL requests support.

Test: telephony sanity tests
bug: 32223897, 20125037, 28294587

Merged-In: I148a4322dfab2d8d84faf6505fb89dfc290411e3
Change-Id: I148a4322dfab2d8d84faf6505fb89dfc290411e3
2017-03-02 03:29:07 +00:00
Jack Yu
da70ca69fd Added two new RIL commands support
Added RIL_REQUEST_SEND_DEVICE_STATE and
RIL_REQUEST_SET_UNSOLICITED_RESPONSE_FILTER RIL requests support.

Test: telephony sanity tests
bug: 32223897, 20125037, 28294587

Change-Id: I148a4322dfab2d8d84faf6505fb89dfc290411e3
2017-03-01 19:21:22 -08:00
nharold
d03ccf89bf Merge changes from topic 'query-fplmn-sync' am: 0dc62c6dd3 am: 1f7f262920
am: 3243ec0614

Change-Id: I3da03980792e5fa898b7109dbb2cea7147f7ee94
2017-03-01 23:38:30 +00:00
nharold
1f7f262920 Merge changes from topic 'query-fplmn-sync'
am: 0dc62c6dd3

Change-Id: Ibc08427e8de920f7f95a6a530b45cfcf8402d203
2017-03-01 21:37:58 +00:00
Nathan Harold
6a7c9333b9 Provide a public API for TelephonyManager.getForbiddenPlmns()
Bug: 33296073
Test: none
Change-Id: I4f1bce663669c18098755c386456e6e9687a3cfb
2017-02-27 16:34:40 -08:00
Nathan Harold
f56cd70734 Add support for querying Forbidden PLMNs
Bug: 32277497
Test: Verified via public API for: missing SIM and working SIM
Change-Id: Ib7838a4be81853ef336e4f3d527c483b49cd2167
2017-02-27 16:01:57 -08:00
TreeHugger Robot
ffffb47569 Merge "Change internal intents from android.* to com.android.internal.*" 2017-02-27 20:34:21 +00:00
Chen Xu
f4854018a2 Merge "move ACTION_CARRIER_SETUP intent to public api"
am: fcb37ffc60

Change-Id: Iaa09a2c35a88d58a6c6df4122bf7f1f87bd7075e
2017-02-25 01:12:09 +00:00
Chen Xu
fcb37ffc60 Merge "move ACTION_CARRIER_SETUP intent to public api" 2017-02-25 01:05:30 +00:00
Amit Mahajan
f5ee786475 Change internal intents from android.* to com.android.internal.*
Test: none
Bug: 35269293
Change-Id: I74585b3d6459cee613408d80fe4a3c13327e5dab
2017-02-24 13:29:37 -08:00
fionaxu
6a5ac3b922 move ACTION_CARRIER_SETUP intent to public api
As per CDD: The "android.*" namespace for intent constants is reserved for public
Android API in AOSP. (Whether public to the full SDK, @SystemApi or
defined in AOSP support libraries.)
ACTION_CARRIER_SETUP intent is generally useful for carrier privileged
apps which is unbundled carrier apps, thus move to public APIs

Bug: 33679956
Test: Manual
Change-Id: I202398f868d35e7e9046e7cc41330a3c26dca0b0
Merged-in: Ie2b5d072406513f04676210d08c43d91623c3cd2
2017-02-24 10:34:07 -08:00
Chen Xu
f73da9c7ed Merge "move ACTION_CARRIER_SETUP intent to public api" 2017-02-24 18:15:46 +00:00
fionaxu
adfe7009f2 move ACTION_CARRIER_SETUP intent to public api
As per CDD: The "android.*" namespace for intent constants is reserved for public
Android API in AOSP. (Whether public to the full SDK, @SystemApi or
defined in AOSP support libraries.)
ACTION_CARRIER_SETUP intent is generally useful for carrier privileged
apps which is unbundled carrier apps, thus move to public APIs

Bug: 33679956
Test: Manual
Change-Id: Ie2b5d072406513f04676210d08c43d91623c3cd2
2017-02-23 16:50:54 -08:00
Abhishek Adappa
423b3bd84f Merge "Add a new ImsReasonInfo code" am: b4234e6af8 am: bb59947d90
am: 44f4430953

Change-Id: Iaaa2f91f36f0f57a81a5f0e7781564296654a33a
2017-02-23 22:32:50 +00:00
Abhishek Adappa
bb59947d90 Merge "Add a new ImsReasonInfo code"
am: b4234e6af8

Change-Id: Ia5174fafbc08acf559e35a28538d2b112b5cdb19
2017-02-23 22:22:40 +00:00
Treehugger Robot
b4234e6af8 Merge "Add a new ImsReasonInfo code" 2017-02-23 22:14:21 +00:00