about:support shows broken information for sandboxing
Categories
(Core :: Security: Process Sandboxing, defect, P5)
Tracking
()
Tracking | Status | |
---|---|---|
firefox72 | --- | fixed |
People
(Reporter: gaston, Assigned: gcp)
Details
Attachments
(3 files)
Displays the string coming from https://searchfox.org/mozilla-central/source/toolkit/modules/Troubleshoot.jsm#172 but ... in a broken way, to say the least.
removing all those null bits and rebuilding the string says sandboxTypeError: Cc['@mozilla.org/sandbox/syscall-reporter;1'] is undefined
Just a cosmetic thing for a Tier3 platform, sure, but what could be improved there ? There's no way for a process itself to know after the fact if it's been pledged/unveiled on OpenBSD, that kind of introspection is not available on purpose, but since we call those syscalls we can store the params used/information somewhere and display it ?
Reporter | ||
Comment 1•5 years ago
|
||
That feels strange to me as https://searchfox.org/mozilla-central/source/toolkit/modules/Troubleshoot.jsm#792 shouldnt be reached on OpenBSD, unless AppConstants.platform
lies for us...
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
removing all those null bits and rebuilding the string says sandboxTypeError: Cc['@mozilla.org/sandbox/syscall-reporter;1'] is undefined
Sounds like a bug with assuming unixy platforms are always using seccomp filtering, which of course only Linux is.
Assignee | ||
Comment 3•5 years ago
|
||
Oops, should have checked your link. Indeed the code is properly conditional on "linux", so it does look like AppConstants lies.
Assignee | ||
Comment 4•5 years ago
|
||
https://searchfox.org/mozilla-central/source/toolkit/modules/AppConstants.jsm#158
Anything using GTK widgets is identified as "linux". I don't think we want to change that as almost all the code assumes the platforms are "win", "macos", "android" or "linux". (And Android is Linux of course, but as it is not using GTK, it's not "linux" to us).
I think I want to add an AppConstant for either OpenBSD or for "platform with seccomp" so we can fix that part.
Reporter | ||
Comment 5•5 years ago
|
||
Hah, how.. infortunate. Pretty sure lots of things depend on this hidden behaviour... so yeah maybe matching on seccomp or by sandbox type would be better.
Assignee | ||
Comment 6•5 years ago
|
||
Assignee | ||
Comment 7•5 years ago
|
||
Landry, can you check if this patch resolves the issues?
Pushed by gpascutto@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f6bcd354c056 Don't display seccomp-bpf info on non-Linux. r=jld,froydnj
Comment 9•5 years ago
|
||
bugherder |
Updated•5 years ago
|
Reporter | ||
Comment 10•5 years ago
|
||
Finally got around to test this, and it nicely displays the sandbox level now. Thanks :gcp !
Description
•