Closed Bug 1118422 Opened 9 years ago Closed 9 years ago

[Dialer][SIM PIN] - In 2.2 changing the SIM PIN via dialer with the wrong PIN does not give the proper error message (X tries remaining).

Categories

(Firefox OS Graveyard :: Gaia::Dialer, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(blocking-b2g:2.2+, b2g-v2.1 unaffected, b2g-v2.2 verified, b2g-master verified)

VERIFIED FIXED
2.2 S5 (6feb)
blocking-b2g 2.2+
Tracking Status
b2g-v2.1 --- unaffected
b2g-v2.2 --- verified
b2g-master --- verified

People

(Reporter: jmitchell, Assigned: thills)

Details

(Keywords: regression, Whiteboard: [2.2-Daily-Testing][planned-sprint c=3])

Attachments

(4 files)

Description:
The user can use the dialer app to change their SIM PIN. If the enter the incorrect SIM PIN they are not presented with a warning message that they have X tries left before their SIM becomes PUK-locked. 

Repro Prerequisite: Have SIM PIN enabled under Settings > SIM Manager > SIM Security

Repro Steps:
1) Update a Flame to 20150106010234
2) Start Dialer App
3) send **04*1234*6789*6789# (would change your PIN code from "1234" to "6789", update 1234 or 6789 as needed for your SIM but use INCORRECT SIM PIN)
4) Repeat 3 times

Actual:
After each attempt you are presented with a "The old PIN you typed is not correct" error message but no mention of having X tries left before locking the SIM card

Expected:
Some mention of X tries left before locking the SIM card

Environmental Variables:
Device: Flame Master (2.2 KK, Nightly, Full-flashed)
Build ID: 20150106010234
Gaia: b77e0d56d197e0ee02d801a25c784130d888c9db
Gecko: 2a193b7f395c
Gonk: a814b2e2dfdda7140cb3a357617dc4fbb1435e76
Version: 37.0a1 (Master)
Firmware Version: V18D
User Agent: Mozilla/5.0 (Mobile; rv:37.0) Gecko/37.0 Firefox/37.0

Repro frequency: 5/5
Link to relevant test case: https://moztrap.mozilla.org/manage/case/14361/
See attached: logcat, Screenshot

---------------------------------------------------------------------------------------
Issue DOES reproduce in 2.2 v188-1

Device: Flame Master (V188-1 Flame KK - Nightly - Full Flashed)
Build ID: 20150105010205
Gaia: c2bf20d23851d5fda9f8f0ef0267db5f49152376
Gecko: 636498d041b5
Gonk: a814b2e2dfdda7140cb3a357617dc4fbb1435e76
Version: 37.0a1 (Master)
Firmware Version: v188-1
User Agent: Mozilla/5.0 (Mobile; rv:37.0) Gecko/37.0 Firefox/37.0


Issue does NOT reproduce in 2.1

Actual Results: Inputting the wrong pin when attempting to change the PIN code via dialer gives the correct error message "X retries left"

Device: Flame 2.1 (Flame KK - Nightly - Full Flashed)
Build ID: 20150105001204
Gaia: 73be51f998031f06db0cd660c0e388fa621c9f4c
Gecko: 05dd053f1d90
Gonk: a814b2e2dfdda7140cb3a357617dc4fbb1435e76
Version: 34.0 (2.1)
Firmware Version: V18D
User Agent: Mozilla/5.0 (Mobile; rv:34.0) Gecko/34.0 Firefox/34.0
Flags: needinfo?(pbylenga)
Bad user UX regression.

Requesting a window.
blocking-b2g: --- → 2.2?
Flags: needinfo?(pbylenga)
QA Contact: pcheng
Triage: Regression
blocking-b2g: 2.2? → 2.2+
b2g-inbound regression window:

Last Working Environmental Variables:
Device: Flame
BuildID: 20141128092705
Gaia: a3e2f4d39082ffc0ee67c72c48d6e7be2486010e
Gecko: 5a68579c6fbf
Version: 36.0a1 (2.2 Master)
Firmware: V188-1
User Agent: Mozilla/5.0 (Mobile; rv:36.0) Gecko/36.0 Firefox/36.0

First Broken Environmental Variables:
Device: Flame
BuildID: 20141128110444
Gaia: 47111fd2bbe8b0055c8a596959d701391d2a9953
Gecko: d707f05e2ea4
Version: 36.0a1 (2.2 Master)
Firmware: V188-1
User Agent: Mozilla/5.0 (Mobile; rv:36.0) Gecko/36.0 Firefox/36.0

First Broken Gaia & Last Working Gecko - issue DOES repro
Gaia: 47111fd2bbe8b0055c8a596959d701391d2a9953
Gecko: 5a68579c6fbf

First Broken Gecko & Last Working Gaia - issue does NOT repro
Gaia: a3e2f4d39082ffc0ee67c72c48d6e7be2486010e
Gecko: d707f05e2ea4

Gaia pushlog:
https://github.com/mozilla-b2g/gaia/compare/a3e2f4d39082ffc0ee67c72c48d6e7be2486010e...47111fd2bbe8b0055c8a596959d701391d2a9953

Caused by the patch for Bug 1031175.
QA Whiteboard: [QAnalyst-Triage?]
Flags: needinfo?(ktucker)
Hello Gabriele, can you please take a look at this issue? Looks to be caused by the uplift for bug 1031175.
QA Whiteboard: [QAnalyst-Triage?] → [QAnalyst-Triage+]
Flags: needinfo?(ktucker) → needinfo?(gsvelto)
I'm busy with another 2.2+ blocker right now, I'll have a look as soon as I'm done with it. Leaving the NI for now.
Whiteboard: [2.2-Daily-Testing] → [2.2-Daily-Testing][planned-sprint c=?]
Target Milestone: --- → 2.2 S4 (23jan)
Whiteboard: [2.2-Daily-Testing][planned-sprint c=?] → [2.2-Daily-Testing][planned-sprint c=3]
Assignee: nobody → drs.bugzilla
The code that populates the error message in this scenario is the following:

https://github.com/mozilla-b2g/gaia/blob/a33dc866dd0661616587cab531418d5afa997133/apps/communications/dialer/js/mmi.js#L257

If |mmiError.additionalInformation| contains a number then it's the number of retries we have left and we'll add it to the message to be shown. This code was changed in bug 1031175 so something must have been broken there though I don't see how. Doug, I think that printing out the contents of the mmiError object as well as the message we assembled should be enough to figure out why we're missing that part of the message.
Flags: needinfo?(gsvelto)
Target Milestone: 2.2 S4 (23jan) → 2.2 S5 (6feb)
Assignee: drs.bugzilla → thills
Attached file PR for fix
Attachment #8554812 - Flags: review?(drs.bugzilla)
Comment on attachment 8554812 [details] [review]
PR for fix

We should add rudimentary tests for SIM PIN's while we're here.
Attachment #8554812 - Flags: review?(drs.bugzilla) → review-
Thanks for the review Doug.  Attached is a new version with some tests in this area.
Attachment #8555428 - Flags: review?(drs.bugzilla)
Comment on attachment 8555428 [details] [review]
Updated PR with new test

Great, thanks for the added tests. I left one comment about missing use of ```MockL10n```, but this is otherwise good to go.
Attachment #8555428 - Flags: review?(drs.bugzilla) → review+
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Attached file 2.2 Uplift request
[Approval Request Comment]
[Bug caused by] (feature/regressing bug #):1031175
[User impact] if declined: user will not be warned that they have n number of remaining tries before they PUK-lock their SIM and might have to call carrier if they don't know the SIM.
[Testing completed]:yes
[Risk to taking this patch] (and alternatives if risky): low risk.  The fix was just a variable name that was eliminated in the 1031175 patch.
[String changes made]:none.
Attachment #8555925 - Flags: approval-gaia-v2.2?(release-mgmt)
Attachment #8555925 - Flags: approval-gaia-v2.2?(release-mgmt) → approval-gaia-v2.2+
This issue is verified fixed on Flame 3.0 and Flame 2.2.

Observed behavior: Following STR, error message shows the number of retries left.

Device: Flame (full flash, nightly user build, 319MB mem)
BuildID: 20150202154235
Gaia: 4171327fce4803c52b2fae8071b114a70a3a68a7
Gecko: 3bf7ed413e87
Gonk: e7c90613521145db090dd24147afd5ceb5703190
Version: 38.0a1 (3.0 Master) 
Firmware Version: v18D-1
User Agent: Mozilla/5.0 (Mobile; rv:38.0) Gecko/38.0 Firefox/38.0

Device: Flame (full flash, nightly user build, 319MB mem)
BuildID: 20150202002507
Gaia: d6141fa3208f224393269e17c39d1fe53b7e6a05
Gecko: be206fa2fb60
Gonk: e7c90613521145db090dd24147afd5ceb5703190
Version: 37.0a2 (2.2) 
Firmware Version: v18D-1
User Agent: Mozilla/5.0 (Mobile; rv:37.0) Gecko/37.0 Firefox/37.0
Status: RESOLVED → VERIFIED
Flags: needinfo?(ktucker)
Flags: needinfo?(ktucker)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: