gecko-dev/layout
norris%netscape.com 51842ef45e Fix 18553 [DOGFOOD] addEventListener allows sniffing keystrokes
Add checks to nsScriptSecurityManager::CheckCanListenTo that take
a principal and ensure that the currently executing script code
either is from the same origin as that principal or has the
UniversalBrowserRead privilege enabled. (chrome code has all
privileges enabled by default.) It's okay for the principal passed in
to be null. That just signifies a privileged window/document that only
can be listened to with privileges.

I added GetPrincipal/SetPrincipal methods to nsIEventListenerManager.
nsDocument::GetNewListenerManager sets a principal on the listener
manager when it creates one. Obviously there are other places that
create listener managers, but scripts seem to go through this one.

Another change is to save some memory usage. Currently I allocate an
array of PolicyType that is NS_DOM_PROP_MAX elements long.
Unfortunately, compilers appear to allocate four bytes for each
PolicyType, so the array takes around 2400 bytes. I've added changes
to use two bit vectors that should consume about 1/16 that space.

r=joki

There are also changes that push nsnull onto the JSContext stack when
entering a nested event loop.

r=jband
1999-11-25 05:28:18 +00:00
..
base Fix 18553 [DOGFOOD] addEventListener allows sniffing keystrokes 1999-11-25 05:28:18 +00:00
build just a comment for future webshell work 1999-11-19 07:32:20 +00:00
doc updated document regardling block and line-layout operation; this is html documents that are not part of the build nor part of any install process, etc. 1999-11-03 21:11:37 +00:00
events Fix 18553 [DOGFOOD] addEventListener allows sniffing keystrokes 1999-11-25 05:28:18 +00:00
forms added back in the code that hook it up to the form for submission 1999-11-24 21:37:34 +00:00
generic Changed nsIPresContext& to nsIPresContext*. Changed nsEventStatus& to nsEventStatus*. Now more compatible with XPIDL. a=vidur r=scc 1999-11-24 06:03:41 +00:00
html Fixes for 19650 and 15133. Added nsHTMLDocument::Resolve(). Script event handler compilation is deferred till when the event handler is first invoked. Atoms used for event name comparisions instead of strings. R=joki 1999-11-25 00:05:21 +00:00
macbuild First Checked In. 1999-11-22 22:30:12 +00:00
mathml Changed nsIPresContext& to nsIPresContext*. Changed nsEventStatus& to nsEventStatus*. Now more compatible with XPIDL. a=vidur r=scc 1999-11-24 06:03:41 +00:00
style 12520 "GFX select elements need to be able to turn off text". Changed nsFrame::DisplaySelection to use the parent's mUserSelect similarly to what we do with mCursor in nsFrame::GetCursor. r=mjudge. 1999-11-23 01:07:56 +00:00
tables Changed nsIPresContext& to nsIPresContext*. Changed nsEventStatus& to nsEventStatus*. Now more compatible with XPIDL. a=vidur r=scc 1999-11-24 06:03:41 +00:00
tools updated license boilerplate to xPL 1.1, a=chofmann@netscape.com,r=endico@mozilla.org 1999-11-06 03:40:37 +00:00
xml Changed nsIPresContext& to nsIPresContext*. Changed nsEventStatus& to nsEventStatus*. Now more compatible with XPIDL. a=vidur r=scc 1999-11-24 06:03:41 +00:00
xsl updated license boilerplate to xPL 1.1, a=chofmann@netscape.com,r=endico@mozilla.org 1999-11-06 03:40:37 +00:00
xul Changed nsIPresContext& to nsIPresContext*. Changed nsEventStatus& to nsEventStatus*. Now more compatible with XPIDL. a=vidur r=scc 1999-11-24 06:03:41 +00:00
.cvsignore Add cvsignore entries for makefiles generated bu autoconf. 1998-12-05 09:07:33 +00:00
Makefile.in updated license boilerplate to xPL 1.1, a=chofmann@netscape.com,r=endico@mozilla.org 1999-11-06 03:40:37 +00:00
makefile.win updated license boilerplate to xPL 1.1, a=chofmann@netscape.com,r=endico@mozilla.org 1999-11-06 03:40:37 +00:00