From 80f3d35f64a720a1d59552589cb77e2061eadf6d Mon Sep 17 00:00:00 2001 From: twyen Date: Fri, 23 Feb 2018 01:14:17 -0800 Subject: Prevent VVM subscribing when carrier reset subscription status On VVM3 when the user upgrade to premium VVM through the carrier, the carrier will actively send STATUS SMSes first indicating the status is unknown, then the new premium status. STATUS updates sent by the carrier were ignored until recently. Currently seeing the unknown status the provisioning process will be triggered, and the user will be downgraded back to basic VVM. In this CL if the STATUS update is initiated by the carrier instead by a STATUS request, provisioning will be ignored. Bug: 73625577 Test: N/A PiperOrigin-RevId: 186737242 Change-Id: Ieb10f9a50e0c3001d02cefc31256a9adac1ae5d1 --- java/com/android/voicemail/impl/ActivationTask.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'java/com/android/voicemail/impl/ActivationTask.java') diff --git a/java/com/android/voicemail/impl/ActivationTask.java b/java/com/android/voicemail/impl/ActivationTask.java index 3cdbee484..d8ec4e252 100644 --- a/java/com/android/voicemail/impl/ActivationTask.java +++ b/java/com/android/voicemail/impl/ActivationTask.java @@ -196,7 +196,8 @@ public class ActivationTask extends BaseTask { VisualVoicemailProtocol protocol = helper.getProtocol(); Bundle data; - if (messageData != null) { + boolean isCarrierInitiated = messageData != null; + if (isCarrierInitiated) { // The content of STATUS SMS is provided to launch this task, no need to request it // again. data = messageData; @@ -237,7 +238,8 @@ public class ActivationTask extends BaseTask { } else { if (helper.supportsProvisioning()) { VvmLog.i(TAG, "Subscriber not ready, start provisioning"); - helper.startProvisioning(this, phoneAccountHandle, status, message, data); + helper.startProvisioning( + this, phoneAccountHandle, status, message, data, isCarrierInitiated); } else if (message.getProvisioningStatus().equals(OmtpConstants.SUBSCRIBER_NEW)) { VvmLog.i(TAG, "Subscriber new but provisioning is not supported"); -- cgit v1.2.3