[Network Alert] Presidential alerts not displayed when Emergency Alert is off for GSM

RESOLVED FIXED in Firefox OS v2.2

Status

Firefox OS
Gaia::Network Alerts
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: cyang, Assigned: julienw)

Tracking

(Blocks: 1 bug)

unspecified
2.2 S9 (3apr)
ARM
Gonk (Firefox OS)

Firefox Tracking Flags

(blocking-b2g:2.2+, b2g-v2.2 fixed, b2g-master fixed)

Details

(Whiteboard: [caf priority: p2][CR 813152])

Attachments

(1 attachment)

(Reporter)

Description

3 years ago
While on GSM network, when a Presidential alert has been received, the UI does not display this message when Emergency Alert is toggled off.

STR:

1) Go to Settings->Messaging Settings
2) Toggle 'Emergency Alert' to off
3) Inject a Presidential alert cell broadcast message (message id 4370)

Actual: Nothing is displayed on the screen
Expected: The Presidential alert is displayed on the screen

Presidential Level Alerts are not settable by MMI and should always be displayed regardless of the UI settings. Reference TS at [1], table under section 9.4.1.2.2 for 'Not settable by MMI'.

Note that this bug is similar to bug 1091960 but that bug was more specific to incorrect value checks for CDMA support. Opening a new bug as this is only occurring for GSM.

The reason for this bug is because at [2], cell_broadcast_system.js returns early to let Network Alert app handle CMAS messages. However, the check at [3] prevents the Presidential alert from being displayed.


[1] http://www.etsi.org/deliver/etsi_ts/123000_123099/123041/11.06.00_60/ts_123041v110600p.pdf
[2] https://github.com/mozilla-b2g/gaia/blob/v2.2/apps/system/js/cell_broadcast_system.js#L80
[3] https://github.com/mozilla-b2g/gaia/blob/v2.1/apps/network-alerts/js/index.js#L37
(Assignee)

Comment 1

3 years ago
Thanks Carol, this is indeed a better idea to file a separate bug.

I definitely agree we should fix this.

Bevis, do you know how we can know the alert is a Presidential alert from Gaia?
blocking-b2g: --- → 2.2?
Flags: needinfo?(btseng)
(Reporter)

Comment 2

3 years ago
(In reply to Julien Wajsberg [:julienw] from comment #1)
> Thanks Carol, this is indeed a better idea to file a separate bug.
> 
> I definitely agree we should fix this.
> 
> Bevis, do you know how we can know the alert is a Presidential alert from
> Gaia?

The quick fix would be at [3], check for message.messageId for Presidential alert id 4370
(Assignee)

Comment 3

3 years ago
From what I read this requirement could be different depending on the carrier. Maybe we should make it depend on the mcc/mnc ?
(Reporter)

Comment 4

3 years ago
> The quick fix would be at [3], check for message.messageId for Presidential alert id 4370

Actually on second thought, the check at [3] should just be removed altogether. The filtering of messages would have already been done down at the RIL level. UI should not have to do such filtering. For example: 

 ril.cellbroadcast.searchlist = ""
 ril.cellbroadcast.disabled = false
 cmas.enabled = false

Then the only CB messages that would be received by the UI is Presidential Alert only. It would seem that the check in Gaia is redundant to what the lower layers are already doing.
(In reply to Carol Yang [:cyang] from comment #4)
> > The quick fix would be at [3], check for message.messageId for Presidential alert id 4370
> 
> Actually on second thought, the check at [3] should just be removed
> altogether. The filtering of messages would have already been done down at
> the RIL level. UI should not have to do such filtering. For example: 
> 
>  ril.cellbroadcast.searchlist = ""
>  ril.cellbroadcast.disabled = false
>  cmas.enabled = false
> 
> Then the only CB messages that would be received by the UI is Presidential
> Alert only. It would seem that the check in Gaia is redundant to what the
> lower layers are already doing.

Due to these 2 reasons:
1. "cmas.enabled" is a UI settings for user to choose whether Emergency Alert shall be displayed or not.
2. Presidential-Level Alert is "Not settable by MMI".

The solution is to identify "Presidential-Level" Alert and then, display it without checking 'cmas.enabled'.
In GSM network, 'messageId' is used to identify the Presidential-Level CMAS message if its value is equal to "4370" or "4383". Reference TS at [1], table under section 9.4.1.2.2.

[1] http://www.etsi.org/deliver/etsi_ts/123000_123099/123041/11.06.00_60/ts_123041v110600p.pdf
Flags: needinfo?(btseng)
(Assignee)

Comment 6

3 years ago
Bevis, can you also please comment on comment 4? Is this check done in Gecko already?
Flags: needinfo?(btseng)
(Assignee)

Comment 7

3 years ago
IMO cmas.enabled should be checked by UI because it's purely a UI concern.
(In reply to Julien Wajsberg [:julienw] from comment #6)
> Bevis, can you also please comment on comment 4? Is this check done in Gecko
> already?

I don't think 'ril.cellbroadcast.searchlist = ""' is a check but actually triggers modem to clear the search list settable from MMI but all the channels in CBMI/CBMIR/CBMID of the inserted UICC will still be applied according to MOZ-RIL's implementation.

In addition, 'ril.cellbroadcast.disabled = false' triggers modem to deactivate the CBS service.
However, according to the discussion in bug 100851, we still don't have too much information about how different vendor/modem solution behaves: 
Does all cbs messages are disabled or only the ones settable by MMI when deactivated?

That's why I provide a different suggestion in comment 5 to fix this bug.

We can NI Carol to double confirm if this proposal is better.
Flags: needinfo?(btseng)
Flags: needinfo?(cyang)
(In reply to Julien Wajsberg [:julienw] from comment #7)
> IMO cmas.enabled should be checked by UI because it's purely a UI concern.

I agree with you that this is purely UI concern.
The only concern is that if this UI design conflict to any certificate criteria especially to the Presidential-Level Alerts.
(Assignee)

Comment 10

3 years ago
(In reply to Bevis Tseng[:bevistseng][:btseng] from comment #9)
> (In reply to Julien Wajsberg [:julienw] from comment #7)
> > IMO cmas.enabled should be checked by UI because it's purely a UI concern.
> 
> I agree with you that this is purely UI concern.
> The only concern is that if this UI design conflict to any certificate
> criteria especially to the Presidential-Level Alerts.

Yes, then this is a bug and we need to fix it :)
(Reporter)

Comment 11

3 years ago
(In reply to Bevis Tseng[:bevistseng][:btseng] from comment #8)
> (In reply to Julien Wajsberg [:julienw] from comment #6)
> > Bevis, can you also please comment on comment 4? Is this check done in Gecko
> > already?
> 
> I don't think 'ril.cellbroadcast.searchlist = ""' is a check but actually
> triggers modem to clear the search list settable from MMI but all the
> channels in CBMI/CBMIR/CBMID of the inserted UICC will still be applied
> according to MOZ-RIL's implementation.
> 
> In addition, 'ril.cellbroadcast.disabled = false' triggers modem to
> deactivate the CBS service.
> However, according to the discussion in bug 100851, we still don't have too
> much information about how different vendor/modem solution behaves: 
> Does all cbs messages are disabled or only the ones settable by MMI when
> deactivated?
> 
> That's why I provide a different suggestion in comment 5 to fix this bug.
> 
> We can NI Carol to double confirm if this proposal is better.

Hi Bevis,

You're solution in comment 5 will fix the issue.

Thanks,
Carol
Flags: needinfo?(cyang)

Updated

3 years ago
Whiteboard: [CR 813152]

Updated

3 years ago
Whiteboard: [CR 813152] → [caf priority: p2][CR 813152]
this seems to be a new feature so I doubt if we should implement this at this moment.
is this cert blocker?
(Reporter)

Comment 13

3 years ago
(In reply to Wesley Huang [:wesley_huang] (EPM) (NI me) from comment #12)
> this seems to be a new feature so I doubt if we should implement this at
> this moment.
> is this cert blocker?

Without a fix, this would be breaking the spec. Also, note that this works for the CDMA case.
(Assignee)

Comment 14

3 years ago
This looks very easy to do, let's not spend too much time to discuss and let's just do it for v2.2. I can take on the work to do it.
(Assignee)

Updated

3 years ago
Assignee: nobody → felash
blocking-b2g: 2.2? → 2.2+
Created attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master
(Assignee)

Comment 16

3 years ago
Comment on attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master

Hey Carol,

I don't have an easy way to check that myself yet (I asked for support from our emulator peers so that I can test using the emulator). Could you please test this patch on your side?

Thanks
Attachment #8585497 - Flags: feedback?(cyang)
(Reporter)

Comment 17

3 years ago
Comment on attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master

I see the Presidential Alert now
Attachment #8585497 - Flags: feedback?(cyang) → feedback+
(Assignee)

Comment 18

3 years ago
Comment on attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master

Thanks,

let's ask a review then !
Attachment #8585497 - Flags: review?(schung)
Comment on attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master

Only some small nits but looks great overall, thanks!
Attachment #8585497 - Flags: review?(schung) → review+
(Assignee)

Updated

3 years ago
Keywords: checkin-needed

Updated

3 years ago
Keywords: checkin-needed
https://github.com/mozilla-b2g/gaia/pull/29220

Autolander could not land the pull request due to not having collaborator rights. This is possibly due to a tree closure. Please check the tree status and request checkin again once the tree is open.
(Assignee)

Comment 21

3 years ago
master: b7aafb22f3018091553a499b4b343c2340553ef9
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → FIXED
(Assignee)

Comment 22

3 years ago
Comment on attachment 8585497 [details] [review]
[gaia] julienw:1147160-presidential-alerts > mozilla-b2g:master

[Approval Request Comment]
[Bug caused by] (feature/regressing bug #): -
[User impact] if declined: Presidential alerts can be opt out.
[Testing completed]: yes, both manually and unit tests.
[Risk to taking this patch] (and alternatives if risky): low
[String changes made]: none
Attachment #8585497 - Flags: approval-gaia-v2.2?

Comment 23

3 years ago
Bhavana, please get this uplifted to 2.2.
Flags: needinfo?(bbajaj)

Updated

3 years ago
Flags: needinfo?(bbajaj)
Attachment #8585497 - Flags: approval-gaia-v2.2? → approval-gaia-v2.2+
v2.2: https://github.com/mozilla-b2g/gaia/commit/9226ac0d3d9d33b0400f8f69ec4bdf8f545a414b
status-b2g-v2.2: --- → fixed
status-b2g-master: --- → fixed
Target Milestone: --- → 2.2 S9 (3apr)
You need to log in before you can comment on or make changes to this bug.