Closed
Bug 127252
Opened 24 years ago
Closed 23 years ago
about:config should use redirector, doesn't work, js error
Categories
(Core :: Networking, defect)
Core
Networking
Tracking
()
VERIFIED
FIXED
mozilla0.9.9
People
(Reporter: alexeyc2003, Assigned: Biesinger)
References
Details
Attachments
(2 files, 4 obsolete files)
|
2.42 KB,
patch
|
Biesinger
:
review+
|
Details | Diff | Splinter Review |
|
3.62 KB,
patch
|
Biesinger
:
review+
darin.moz
:
superreview+
asa
:
approval+
|
Details | Diff | Splinter Review |
about:config should use redirector introduced in bug 68086
trivial modifications should be made to following files:
/mozilla/netwerk/build/nsNetModule.cpp
/mozilla/netwerk/protocol/about/src/nsAboutRedirector.cpp
and these 2 files should be removed:
/mozilla/netwerk/protocol/about/src/nsAboutConfig.cpp
/mozilla/netwerk/protocol/about/src/nsAboutConfig.h
| Assignee | ||
Comment 1•24 years ago
|
||
| Assignee | ||
Comment 2•24 years ago
|
||
taking
Assignee: gagan → cbiesinger
Target Milestone: --- → mozilla0.9.9
| Assignee | ||
Comment 3•24 years ago
|
||
sigh, ok, I forgot to change the makefiles... please review both patches
| Assignee | ||
Comment 4•24 years ago
|
||
dougt, can you review?
darin, can you super-review?
Status: NEW → ASSIGNED
Comment on attachment 70920 [details] [diff] [review]
patch
r=gagan
Attachment #70920 -
Flags: review+
Comment on attachment 70921 [details] [diff] [review]
makefile changes
r=gagan
This is ok but please also make the relevant changes in the mac projects as
needed.
Attachment #70921 -
Flags: review+
Comment 8•24 years ago
|
||
Comment on attachment 70921 [details] [diff] [review]
makefile changes
mac project changes? with that, sr=darin
Attachment #70921 -
Flags: superreview+
Comment 9•24 years ago
|
||
Comment on attachment 70920 [details] [diff] [review]
patch
sr=darin
Attachment #70920 -
Flags: superreview+
| Assignee | ||
Comment 11•23 years ago
|
||
checked in
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 12•23 years ago
|
||
about:config is broken
Error: uncaught exception: Permission denied to get property UnnamedClass.classes
Not enough security privileges in the redirector?
Can it be easily fixed or will it has to be backed out?
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
| Assignee | ||
Comment 13•23 years ago
|
||
I won't have time to look at this until this weekend; if you want about:config
to work earlier, please back it out.
Comment 14•23 years ago
|
||
*** Bug 128292 has been marked as a duplicate of this bug. ***
Comment 15•23 years ago
|
||
*** Bug 128476 has been marked as a duplicate of this bug. ***
| Assignee | ||
Comment 16•23 years ago
|
||
changing summary in hope to avoid more dups
Summary: about:config should use redirector → about:config should use redirector, doesn't work, js error
| Assignee | ||
Comment 17•23 years ago
|
||
Attachment #70920 -
Attachment is obsolete: true
Attachment #70921 -
Attachment is obsolete: true
| Assignee | ||
Comment 18•23 years ago
|
||
ok, gagan/dougt, can you review?
darin, can you super-review?
(I will convert the tab to spaces before checking in)
| Reporter | ||
Comment 19•23 years ago
|
||
Comment on attachment 72219 [details] [diff] [review]
make about:config work again
+static const int kConfigNum = 3;
is this needed?
nits:
+ { "plugins", "chrome://global/content/plugins.html", DROP},
DROP has 2 spaces in front and no space after it.
+ // these privileges
align this comment with others :o)
| Assignee | ||
Comment 20•23 years ago
|
||
>+static const int kConfigNum = 3;
>is this needed?
no, it isn't... I'll remove it.
>+ { "plugins", "chrome://global/content/plugins.html", DROP},
>DROP has 2 spaces in front and no space after it.
Oh, I thought I had already corrected this... Will really fix it before checking in.
>+
// these privileges
>align this comment with others :o)
This is the tab I talked about :)
Status: REOPENED → ASSIGNED
Comment 21•23 years ago
|
||
MY favorite resolution is to wontfix this and back out the change.
<about:config> could live just fine in its own class, given that it has
different needs than <about:credits>.
About the patch (This is no r=):
s/kRedirMap[i][2]/kRedirMap[i][2] != DONTDROP/
Comment 22•23 years ago
|
||
Comment on attachment 72219 [details] [diff] [review]
make about:config work again
>? .nsAboutRedirector.cpp.swp
>Index: nsAboutRedirector.cpp
>===================================================================
>RCS file: /cvsroot/mozilla/netwerk/protocol/about/src/nsAboutRedirector.cpp,v
>retrieving revision 1.6
>diff -u -r1.6 nsAboutRedirector.cpp
>--- nsAboutRedirector.cpp 2002/02/27 11:53:26 1.6
>+++ nsAboutRedirector.cpp 2002/03/02 13:51:03
>@@ -50,14 +50,20 @@
>
> NS_IMPL_ISUPPORTS1(nsAboutRedirector, nsIAboutModule)
>
>+static const char* DROP = (const char*)1;
>+static const char* DONTDROP = (const char*)0;
>+
Eww, use a struct.
>+static const int kConfigNum = 3;
Not needed, just loop for sizeof(foo)/sizeof(sturct whatever*)
This will return about:config to what it was before, but mstoltz should look at
this.
Attachment #72219 -
Flags: needs-work+
| Assignee | ||
Comment 23•23 years ago
|
||
doesn't use the sizeof method to calculate the length of the struct, because
the original code contains this:
static const int kRedirTotal = 4; // sizeof(kRedirMap)/sizeof(*kRedirMap)
so I thought there was a reason why it was commented out
but if you want me to use it, I'll do it
| Assignee | ||
Updated•23 years ago
|
Attachment #72219 -
Attachment is obsolete: true
| Assignee | ||
Comment 24•23 years ago
|
||
mstoltz, could you take a look at this patch?
It makes it possible for pages using the about: redirector to get chrome
privileges, if they need to - this is needed for about:config
Comment 25•23 years ago
|
||
Comment on attachment 72294 [details] [diff] [review]
new patch
>? .nsAboutRedirector.cpp.swp
>Index: nsAboutRedirector.cpp
>===================================================================
>RCS file: /cvsroot/mozilla/netwerk/protocol/about/src/nsAboutRedirector.cpp,v
>retrieving revision 1.6
>diff -u -r1.6 nsAboutRedirector.cpp
>--- nsAboutRedirector.cpp 2002/02/27 11:53:26 1.6
>+++ nsAboutRedirector.cpp 2002/03/03 12:17:36
>@@ -50,12 +50,18 @@
>
> NS_IMPL_ISUPPORTS1(nsAboutRedirector, nsIAboutModule)
>
>+struct RedirEntry {
>+ const char* id;
>+ const char* url;
>+ bool dropChromePrivs; // if true, the page will not have chrome privileges
>+};
>+
Need to use PRBool and PR_TRUE/PR_FALSE.
Attachment #72294 -
Flags: needs-work+
| Assignee | ||
Comment 27•23 years ago
|
||
Comment on attachment 72295 [details] [diff] [review]
hopefully final patch
bbaetz gave me r=bbaetz on irc provided mstoltz says the changes are OK
Attachment #72295 -
Flags: review+
Comment 28•23 years ago
|
||
*** Bug 129114 has been marked as a duplicate of this bug. ***
Comment 29•23 years ago
|
||
Your change looks fine, but I want to make sure about:config is safe before we
give it chrome privs again. The attached patch includes a change to config.js
that html-escapes the pref names as well as the pref values. This should
prevent future exploits. I've included your patch in mine, with the addition of
a warning comment to avoid turning on chrome privileges unnecessarily.
Christian, you've got my r= on your changes, could you review mine?
| Assignee | ||
Comment 30•23 years ago
|
||
Comment on attachment 72716 [details] [diff] [review]
New patch - added a warning comment and a related security improvement
ok, r=cbiesinger@web.de on your changes
Attachment #72716 -
Flags: review+
Comment 31•23 years ago
|
||
Comment on attachment 72716 [details] [diff] [review]
New patch - added a warning comment and a related security improvement
sr=darin
Attachment #72716 -
Flags: superreview+
Comment 32•23 years ago
|
||
Comment on attachment 72716 [details] [diff] [review]
New patch - added a warning comment and a related security improvement
a=asa (on behalf of drivers) for checkin to the 1.0 trunk
Attachment #72716 -
Flags: approval+
| Assignee | ||
Comment 33•23 years ago
|
||
checked into trunk
leaving open for branch checkin (asa gave me a= via mail/irc)
| Assignee | ||
Comment 34•23 years ago
|
||
checked into branch
Status: ASSIGNED → RESOLVED
Closed: 23 years ago → 23 years ago
Resolution: --- → FIXED
Comment 35•23 years ago
|
||
If this was branch checked, which branch and should it have a branch keyword?
Comment 38•23 years ago
|
||
.
Status: REOPENED → RESOLVED
Closed: 23 years ago → 23 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•