Policies cannot be removed through Visual management screen, can only be removed from JSON editing screen
Categories
(Enterprise Products :: Console, defect)
Tracking
(Not tracked)
People
(Reporter: mcurtean, Assigned: julienw)
References
(Depends on 2 open bugs)
Details
(Keywords: regression)
Attachments
(5 files, 1 obsolete file)
Found in
Handlers policy example
Affected versions
commit "61cc1d56f9a44347addf29900a375fdf892e0ec6"
version "422/merge"
source "https://github.com/mozilla/enterprise-console"
build "https://github.com/mozilla/enterprise-console/actions/runs/34554392439"
Preconditions
A Company admin is logged into the Console.
Multiple users (authenticated and unauthenticated) are enrolled and have signed in.
With a user account, set the Handlers policy
Steps to reproduce
- From the console > Policy management> filter by Handlers and set the policy - see 2067099
"Handlers": {
"mimeTypes": { "": { "action": "saveToDisk" } },
"extensions": { "": { "action": "saveToDisk" } }
- Login on FxE and check the policy is displayed in about:policies.
- Return to the console Policies and from the Visual screen, switch the value to Not SET.
- Check again FxE about:policies.
Expected result
The policy should not be applied to the client when no value is set.
The policy should not have the SET label anymore.
The policy should be removed from the JSON list of policies.
Actual result
Handler policy value changes to null in the JSON policy list.
The policy still shows as SET in the policy sidebar.
The policy is still available in about:policies.
| Reporter | ||
Updated•2 months ago
|
| Assignee | ||
Comment 1•2 months ago
|
||
There may be a misunderstanding, due to confusing labels that we'll need to change.
"Not Set" does set a value... the value "not set". This translates to null in the JSON serialization. And because there is this null value the policy shows as "SET" in the sidebar. So this part makes sense. (but we need to change the confusing labels)
If you want to not set a value at all at this level, you need to select "inherit the value". Then this will apply the value from the upper layer, if any (org unit or company).
However when you set "Not set", this means that we remove the policy in the values sent to Firefox. So in Firefox it should disappear. So there's a bug in either the console (unlikely if you don't see the same behavior for other policies) or Firefox.
It would be interesting to know if you see any error in the browser console.
| Reporter | ||
Comment 2•2 months ago
|
||
Thanks for the quick response, Julien and apologies for the misunderstanding.
When the policy is null, there are no errors (only the Download Telemetry, but I've just removed that now from the JSON policies list and it stopped getting triggered )
| Assignee | ||
Comment 3•2 months ago
|
||
When the policy is null, there are no errors (only the Download Telemetry, but I've just removed that now from the JSON policies list and it stopped getting triggered )
I was interested by errors that might show up in the Browser Console (in Tools > Browser Tools > Browser Console).
| Assignee | ||
Comment 4•2 months ago
|
||
I see the Handlers policy has x-restart-required
(see https://github.com/mozilla/enterprise-firefox/blob/fb8d5384d63d48f6ca755162541a769b6382f23d/browser/components/enterprisepolicies/schemas/policies-schema.json#L2569-L2577). This was added in bug 2046462.
These policies are not updated live: https://searchfox.org/enterprise-main/rev/73feaaf3ca5b5936d44e3244c981881f73c4e3c6/toolkit/components/enterprisepolicies/EnterprisePoliciesParent.sys.mjs#675-687
In the Browser Console you might see this message: Policy Handlers requires a restart; its removal will not take effect before the next restart..
What happens if you restart Firefox? Do you still see it?
I think we could do a better job outlining that a policy update is pending a restart in about:policies. We could also show in the Console that this policy change will need a restart. It's worth filing 2 bugs for that, if you can do it?
| Reporter | ||
Comment 5•2 months ago
•
|
||
Indeed, it is worth noting that this is not a live policy and a restart is required.
I monitored the browser console in this initial use case, on Windows on the release build- 156.0 (20260910132224), by first removing the policy from the JSON for a clear slate and then:
- added the policy through the Visual management screen by adding a value
- checked browser console and about:policies
- restarted the browser
- removed the policy value through the Visual screen > check that it showed as
"null"in the JSON - checked the browser console and about:policies and both showed the error that has not yet been fixed on release but did not show the
"Policy Handlers requires a restart; its removal will not take effect before the next restart.."message.
I'll check and attach the Multi-processes log for my last try, maybe you'll see something relevant there.
As for logging the bugs, sure, I'll start asap.
| Reporter | ||
Comment 6•2 months ago
|
||
Taken from console while the policy value was moved to "not set", but before restart.
| Assignee | ||
Comment 7•2 months ago
|
||
From your video, I see that after restart the "Handlers" policy is gone in about:policies, is that right? Then I believe we can close this bug as worksforme?
| Assignee | ||
Comment 8•2 months ago
|
||
The log is output with the "warn" severity. The log is configured using hte pref browser.policies.loglevel. Do you know what is the value for this level on your instance?
| Reporter | ||
Comment 9•2 months ago
•
|
||
(In reply to Julien Wajsberg [:julienw] from comment #7)
From your video, I see that after restart the "Handlers" policy is gone in about:policies, is that right? Then I believe we can close this bug as worksforme?
Yes, that makes sense, this occurred due to the confusion of what a "Not Set" policy value should result in. On that note, is this UX improvment tracked somehow or should I add an enhancement bug for it?
The log is output with the "warn" severity. The log is configured using hte pref browser.policies.loglevel. Do you know what is the value for this level on your instance?
it's not configured. should I set it to True?
| Assignee | ||
Comment 10•2 months ago
|
||
(In reply to Miruna Curtean from comment #9)
Created attachment 9642458 [details]
browser.policies.loglevel.png(In reply to Julien Wajsberg [:julienw] from comment #7)
From your video, I see that after restart the "Handlers" policy is gone in about:policies, is that right? Then I believe we can close this bug as worksforme?
Yes, that makes sense, this occurred due to the confusion of what a "Not Set" policy value should result in. On that note, is this UX improvment tracked somehow or should I add an enhancement bug for it?
It's tracked in my mind but a bug would be better ;-)
The log is output with the "warn" severity. The log is configured using hte pref browser.policies.loglevel. Do you know what is the value for this level on your instance?
it's not configured. should I set it to True?
You can try creating it as a string and setting it to "warn" :-)
(pure speculation, I haven't tried it)
| Reporter | ||
Updated•2 months ago
|
| Assignee | ||
Comment 11•2 months ago
|
||
| Assignee | ||
Comment 12•1 month ago
|
||
From the discussion I think this bug can be closed as invalid. Other bugs were created to specifically track what we found with the video. Closing!
| Assignee | ||
Updated•1 month ago
|
Description
•