Bobby Holley
3a117d4c6b
Bug 956382 - Remove unused CAPS gunk. r=mrbkap
2014-02-13 18:57:36 -08:00
Bobby Holley
a2e8a0648e
Bug 956382 - Hoist nsScriptSecurityManager::CheckSameOriginPrincipal into nsPrincipal::EqualsConsideringDomain. r=mrbkap
2014-02-13 18:57:36 -08:00
Bobby Holley
7247f806d7
Bug 957688 - Remove checkObjectAccess security callback. r=mrbkap
...
There's no need for the JS shell stuff either, since vm/Runtime.cpp already
sets up NullSecurityCallbacks by default.
2014-01-24 16:08:25 -08:00
Bobby Holley
1ed0579127
Bug 794943 - Remove CheckXPCPermissions. r=mrbkap
2014-01-16 15:45:40 -08:00
Bobby Holley
c9af969104
Bug 794943 - Remove checks for nsISecurityCheckedComponent in caps. r=mrbkap
2014-01-16 15:45:40 -08:00
Luke Wagner
71c1b711b8
Bug 924905 - Do a subsumes check inside the stack iterator. r=jandem
2014-01-03 10:32:56 -06:00
Bobby Holley
d7c54ab6df
Bug 913734 - Remove now-unused policy machinery. r=mrbkap
2013-12-13 19:15:43 -08:00
Bobby Holley
444f4a2501
Bug 913734 - Stop storing security policies on XPCWrappedNativeProtos. r=mrbkap
...
This is just a cache, so we can safely remove it without impacting correctness.
The rest of this mechanism goes away in subsequent patches.
2013-12-13 19:15:43 -08:00
Bobby Holley
60fb15ef2c
Bug 840488 - New domain policy API. r=bz
...
Note that this patch changes the semantics of javascript.enabled so that changes
to the pref do not apply to compartments that have already been created. This is
a significant change, but is necessary to support the new domain policy API.
After one cycle or so, we'll rip out the old API.
2013-11-12 16:43:35 -08:00
Bobby Holley
3e8be8901b
Bug 840488 - Compute immunity from caps checks exactly once, and kill nsScriptSecurityManager::CanExecuteScripts. r=bz
2013-11-12 16:43:35 -08:00
Bobby Holley
26de26f994
Bug 840488 - Get rid of aAllowIfNoScriptContext. r=bz
...
The old code seemed to feel that the lack of a script context was some sort of
showdown that required either unconditional allow or deny. Instead, let's just
make the scriptcontext-relevant checks conditional on there being a script
context, which lets us switch CheckFunctionAccess over to ScriptAllowed.
2013-11-12 16:43:32 -08:00
Bobby Holley
7e04f43d8e
Bug 917009 - Remove old-style object principal calculation. r=bz
2013-09-17 15:29:11 -07:00
Terrence Cole
88384d4002
Bug 908750 - Fix a rooting hazard in nsScriptSecurityManger::LookupPolicy; r=bholley
2013-08-23 08:51:40 -07:00
Jan Varga
f354bdf37d
Bug 785884 - Implement support for temporary storage (aka shared pool). r=ehsan, r=bent
2013-09-11 06:18:36 +02:00
Bobby Holley
b8e43398f3
Bug 905364 - Stop using the SafeJSContext in nsScriptSecurityManager::Init. r=mrbkap
...
With this patch, I've confirmed that we instantiate the SafeJSContext much later
in startup, during nsAppStartupNotifier::Observe (which ends up invoking an
XPCWrappedJS). As such, this should solve a number of our startup ordering woes.
2013-09-06 11:35:12 -07:00
Nicholas Nethercote
d0f640378a
Bug 911020 - Introduce js/TypeDecls.h, which holds very commonly used type declarations from the JS engine. r=luke.
2013-08-27 19:59:14 -07:00
Nicholas Nethercote
9fc605b8f3
Bug 905017 (part 1) - Minimize inclusions of JS engine headers in .h and .idl files. r=billm.
2013-08-17 15:50:18 -07:00
Phil Ringnalda
f52eb1b949
Back out c39d60483813 (bug 905364) for xpcshell and b2g desktop bustage
2013-08-16 22:38:48 -07:00
Bobby Holley
dd777f6a02
Bug 905364 - Stop using the SafeJSContext in nsScriptSecurityManager::Init. r=mrbkap
...
With this patch, I've confirmed that we instantiate the SafeJSContext much later
in startup, during nsAppStartupNotifier::Observe (which ends up invoking an
XPCWrappedJS). As such, this should solve a number of our startup ordering woes.
2013-08-16 20:28:17 -07:00
Nicholas Nethercote
f7d6f07d24
Bug 898914 (part 1) - Remove JSBool.
2013-08-08 15:53:04 -07:00
Ehsan Akhgari
6d396d8bcb
Bug 872127 - Part 2: Replace mozilla/StandardInteger.h with stdint.h; r=Waldo,ted
2013-07-30 10:25:31 -04:00
Bobby Holley
be84b54b9e
Bug 885668 - Removed specialized function object principal machinery from CAPS. r=bz
2013-07-15 11:22:10 -07:00
Jon Coppeard
5f0e17f56a
Bug 885310 - 1 Rename JSHandleFoo in the browser r=bz
2013-06-21 14:12:46 +01:00
Bobby Holley
e46615bfec
Bug 884362 - Use AutoJSContext in nsScriptSecurityManager::LoadPolicy. r=bz
...
This cx is just used for rooting etc. As such, we really just want whatever
cx is on the stack, but want a default if the stack-top cx is null (which it
sometimes is, here). And that's exactly what AutoJSContext gives us.
2013-06-20 11:05:32 -07:00
Jon Coppeard
6ac7794926
Bug 884371 - Remove JSMutableHandleXXX from the browser r=bz
2013-06-19 11:32:27 +01:00
Trevor Saunders
f9522d1d32
bug 873622 - remove nsScriptSecurityManager::sXPConnect r=bholley
2013-05-29 19:49:11 -04:00
Boris Zbarsky
41ec301773
Bug 873735 part 1. Fix the more or less mechanical browser rooting hazards. r=terrence
2013-05-20 08:40:06 -04:00
Ehsan Akhgari
9c0f40be9f
Bug 871262 - Fix rooting hazards in the CAPS code; r=till
2013-05-12 15:52:21 -04:00
David Zbarsky
8a2838f566
Bug 867459 - Fix caps rooting hazards r=terrence
2013-05-02 22:02:40 -04:00
Bobby Holley
ff3bf1b100
Bug 865729 - Use sXPConnect directly in caps. r=gabor
...
It's tempting to go through nsContentUtils here, but I'm pretty sure caps is
initialized before nsContentUtils.
2013-04-29 11:16:21 -07:00
matekm
9c0f150108
Bug 784739 - Switch from NULL to nullptr in caps/; r=ehsan
2013-04-02 20:16:25 -04:00
Jan de Mooij
97c93376ae
Bug 833817 part 2 - Remove unused frame argument from GetFunctionObjectPrincipal. r=bholley
2013-01-24 20:39:27 +01:00
Nicholas Nethercote
9cbec4ea66
Bug 826154 - Remove unused field nsScriptSecurityManager::mIsWritingPrefs. r=bz.
2013-01-02 21:47:50 -08:00
Boris Zbarsky
60f6dfd055
Bug 817284. When none of our code is associated with a window in an obvious way, assume that scripts should be allowed to execute for a WebIDL callback. r=bholley
2012-12-06 15:21:18 -05:00
Bobby Holley
47161f9569
Bug 797206 - Remove GetPrincipalAndFrame. r=bz
2012-10-29 15:55:35 +01:00
Mounir Lamouri
49af133f34
Bug 777467 - Update the same-origin policy for principals to include appid/isinbrowserelement. r=bholley
2012-10-24 18:50:25 +01:00
Matt Brubeck
4b3a53c808
Back out fb62d8b9800a (bug 777467) because of debug browser-chrome crashes on a CLOSED TREE
2012-10-22 09:52:35 -07:00
Mounir Lamouri
750b9aa29d
Bug 777467 - Update the same-origin policy for principals to include appid/isinbrowserelement. r=bholley
2012-10-22 16:20:38 +01:00
Bobby Holley
8045f49817
Bug 789224 - Remove CAPS_HACKER debugging instrumentation. r=mrbkap
...
This stuff is super ugly and confusing. I think we're better off without it.
2012-10-22 08:29:56 +02:00
Bobby Holley
2f2a64b5a0
Bug 789224 - Separate certificate principals out from CAPS. r=dveditz
...
There's no longer any reason why "certificate principals" need to be principals at all.
I tried to rip them out entirely, but it looks like they're still used vestigially at XPI
install time to display author information. But there's no reason that they have to be
porkbarreled into the security-critical objects that we pass around all over the place.
So let's make them their own deal.
I was tempted to call them "certificate holders", but that would involve renaming methods and
cause more compat fuss than necessary.
2012-10-22 08:29:56 +02:00
Bobby Holley
e447d2e865
Bug 789224 - Remove principal capability and preference infrastructure. r=mrbkap
2012-10-22 08:29:55 +02:00
Bobby Holley
0881fa53e9
Bug 789224 - Remove capability manager stuff in nsScriptSecurityManager. r=mrbkap
2012-10-22 08:29:55 +02:00
Terrence Cole
4bb6f51dae
Bug 787580 - Root all jsval at the API surface; r=sfink sr=dmandelin
2012-09-04 16:40:12 -07:00
Luke Wagner
bf165e064f
Bug 784551 - remove JSSecurityCallbacks::findObjectPrincipals (r=mrbkap)
2012-08-23 09:51:09 -07:00
Ehsan Akhgari
243c878d26
Bug 579517 - Part 1: Automated conversion of NSPR numeric types to stdint types in Gecko; r=bsmedberg
...
This patch was generated by a script. Here's the source of the script for
future reference:
function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
! -wholename "*security/nss*" \
! -wholename "*/.hg*" \
! -wholename "obj-ff-dbg*" \
! -name nsXPCOMCID.h \
! -name prtypes.h \
-type f \
\( -iname "*.cpp" \
-o -iname "*.h" \
-o -iname "*.c" \
-o -iname "*.cc" \
-o -iname "*.idl" \
-o -iname "*.ipdl" \
-o -iname "*.ipdlh" \
-o -iname "*.mm" \) | \
xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}
convert PRInt8 int8_t
convert PRUint8 uint8_t
convert PRInt16 int16_t
convert PRUint16 uint16_t
convert PRInt32 int32_t
convert PRUint32 uint32_t
convert PRInt64 int64_t
convert PRUint64 uint64_t
convert PRIntn int
convert PRUintn unsigned
convert PRSize size_t
convert PROffset32 int32_t
convert PROffset64 int64_t
convert PRPtrdiff ptrdiff_t
convert PRFloat64 double
2012-08-22 11:56:38 -04:00
Aryeh Gregor
8b4a23fc4c
Bug 777292 part 2 - Change all nsnull to nullptr
2012-07-30 17:20:58 +03:00
Jonas Sicking
63e0465fc6
Bug 774585: Rename getCodebasePrincipal to getSimpleCodebasePrincipal since the behavior has semantically changed. r=mounir
2012-07-21 00:29:40 -07:00
Mounir Lamouri
fdd58dc358
Bug 758258 - part 5 - Add GetAppCodebasePrincipal and GetNoAppCodebasePrincipal to nsIScriptSecurityManager. r=mrbkap sr=sicking
2012-07-19 20:28:08 -07:00
Mounir Lamouri
5491c3b0d3
Bug 758258 - part 4 - Update CreateCodebasePrincipal() to take app/inbrowser info. r=sicking
2012-07-19 15:32:08 -07:00
Mounir Lamouri
7534c3f5b2
Bug 758258 - part 3 - Add extendedOrigin, appStatus and appId to nsIPrincipal. r=bholley sr=sicking
2012-07-19 22:44:03 -07:00