Commit Graph

181 Commits

Author SHA1 Message Date
Ehsan Akhgari
9de6bbbaec Bug 1261019 - Part 3: Remove Navigator.mozApps and code depending on it; r=myk,jryans,fabrice,mcmanus,peterv 2016-10-13 13:18:41 -04:00
Gijs Kruitbosch
7de765df42 Bug 1290668 - unbreak view-source links between http and https pages, r=smaug
MozReview-Commit-ID: B4nXTkMC5LE

--HG--
extra : rebase_source : ad7086b7ff58f44b12c3eaaf9b7be8c8955762a5
2016-09-27 13:31:53 +01:00
Tracy Walker
ab9e34053d Bug 1279087 - In caps/tests/mochitests/bug995943.xul, widen range of assertion check for OSX 10.10 to 5-9 to reduce intermittent test timeouts. r=emk 2016-09-26 08:13:38 -05:00
Ehsan Akhgari
e45aad00ec Bug 1297687 - Part 3: Ensure that the expanded principal of a sandbox has a sensible OriginAttributes; r=bholley
This patch allows specifying an OriginAttributes when creating a sandbox
using Components.utils.Sandbox() by specifying an originAttributes
member on the options dictionary.

If an OA is specified in this way, it is used for creating codebase
principals from the string arguments passed to the function.  Otherwise,
if one or more principals are passed in the array argument to Sandbox(),
the OA of the principal(s) is used to construct codebase principals from
the strings inside the array.  In this case, we check to make sure that
all of the passed principals have the same OA, otherwise we'll throw an
exception.

In case no explicit OA is specified and no principals are passed in the
array argument, we create the codebase principals using a default OA.
2016-09-22 13:27:51 -04:00
Ehsan Akhgari
6b65aceec2 Bug 1297687 - Part 1: Remove nsIScriptSecurityManager.createExpandedPrincipal(); r=bholley 2016-09-22 13:27:33 -04:00
Yoshi Huang
85a594681d Bug 1260931 - Part 1: add firstPartyDomain. r=smaug
Add an origin attribute called 'firstPartyDomain'.
This value will be extracted from the URL bar.

And the purpose of this attribute is used to isolate the data-jars.
Please see the tor documentation.
https://www.torproject.org/projects/torbrowser/design/#identifier-linkability

The idea is like a superset of 'reject third party cookies', but not
only apply for cookies, it also applies to all data-jars like localStorage,
indexedDB and so on.

So basically an iframe will have its own data-jar, and this data-jar is
isolated by the URL from URL bar, for instance, an iframe
https://facebook.com inside https://cnn.com won't share data-jar with
the iframe (https://facebook.com) in https://bbc.com
2016-09-06 10:25:48 +08:00
Sebastian Hengst
60d03b201e Backed out changeset 935ffd53f193 (bug 1260931) for failing xpcshell test test_packaged_app_service.js. r=backout 2016-09-05 21:16:10 +02:00
Yoshi Huang
6c3b62e2fb Bug 1260931 - Part 1: add firstPartyDomain. r=smaug
Add an origin attribute called 'firstPartyDomain'.
This value will be extracted from the URL bar.

And the purpose of this attribute is used to isolate the data-jars.
Please see the tor documentation.
https://www.torproject.org/projects/torbrowser/design/#identifier-linkability

The idea is like a superset of 'reject third party cookies', but not
only apply for cookies, it also applies to all data-jars like localStorage,
indexedDB and so on.

So basically an iframe will have its own data-jar, and this data-jar is
isolated by the URL from URL bar, for instance, an iframe
https://facebook.com inside https://cnn.com won't share data-jar with
the iframe (https://facebook.com) in https://bbc.com
2016-09-06 01:50:15 +08:00
Kan-Ru Chen
29b9a17a92 Bug 1295103 - Use MOZ_MUST_USE in OriginAttributes. r=allstars
MozReview-Commit-ID: PWUb81L8ya

--HG--
extra : rebase_source : 2bdc7adc7a6b5fd121a4621086fab6f87834dd20
2016-08-15 18:22:44 +08:00
Thomas Wisniewski
6a1fb99d2b Bug 709991 - Fire onerror instead of throwing on network errors for async XHRs. r=bz 2016-07-30 00:24:56 -04:00
Fabrice Desré
7846da76d6 Bug 1287107 - Making transition alive with gaia as chrome:// r=bholley,fabrice
MozReview-Commit-ID: 9uVUrmuVFXQ

--HG--
extra : rebase_source : 20f6f0235667530c21aca4889b5d33e39c2d1a48
2016-03-03 09:58:47 -08:00
Carsten "Tomcat" Book
c7846e126c Backed out changeset 16aa7041c009 (bug 1287107) for causing xpcshell and mac tests 2016-07-22 11:30:23 +02:00
Fabrice Desré
f5b619fb28 Bug 1287107 - Making transition alive with gaia as chrome:// r=bholley,fabrice
MozReview-Commit-ID: 9uVUrmuVFXQ

--HG--
extra : rebase_source : d0c19fcda5c72ecdce3b0d0bbbafa5a7954d7a4c
2016-03-03 09:58:47 -08:00
Tom Tromey
5538d692d3 Bug 1286877 - do not set c-basic-offset for python-mode; r=gps
This removes the unnecessary setting of c-basic-offset from all
python-mode files.

This was automatically generated using

    perl -pi -e 's/; *c-basic-offset: *[0-9]+//'

... on the affected files.

The bulk of these files are moz.build files but there a few others as
well.

MozReview-Commit-ID: 2pPf3DEiZqx

--HG--
extra : rebase_source : 0a7dcac80b924174a2c429b093791148ea6ac204
2016-07-14 10:16:42 -06:00
Gijs Kruitbosch
30cb692f62 Bug 1277583, tests, r=ckerschb
MozReview-Commit-ID: J3r7krW8dSH

--HG--
extra : rebase_source : 9505f797a770560c02461184dbc5cd0b8ac6bbe8
2016-06-02 19:42:29 +01:00
Gijs Kruitbosch
6b557997b2 Bug 1274480 - followup: use image that exists on android, rs=bustage
MozReview-Commit-ID: 86ioFu6GrmB
2016-06-09 15:35:11 +01:00
Paolo Amadini
5797203ab2 Bug 1274480 - Part 1 - Use SVG for permission icons and notifications. r=Gijs
MozReview-Commit-ID: Dk0PajOppVL

--HG--
extra : rebase_source : eed692400919f5c126debb14b3ae2c2d17c7cb7d
2016-06-08 16:34:10 +01:00
Masatoshi Kimura
107cbffdc0 Bug 1205027 - Only size <img> to broken-image size if it's actually broken. r=dholbert 2016-06-03 07:05:46 +09:00
Joel Maher
b6788df19c Bug 1067022 - add expected assertion on windows for test_bug995943.xul. r=RyanVM
MozReview-Commit-ID: 3cg9fQgorhG

--HG--
extra : rebase_source : 76c75b2fab084240c33eab1311ebb6c8f7b9f856
2016-05-16 06:47:59 -04:00
Dave Huseby
c01e63f1a5 Bug 1238177 - fix extension content needs to use the correct user context id origin attribute. r=sicking
(HEAD -> oa, refs/patches/oa/Bug_1238177)
Fixes Bug 1238177 -- extension content needs to use the correct user context id origin attribute
2016-04-04 12:20:00 +02:00
Chris Manchester
f7a1b3fb60 Bug 1242051 - Add inter-directory test support file dependencies to ini manifests. r=gps
Previously, every test and support file would be synced to the objdir
when running any test. Now that only those support files and tests requested
are synced, we note support files required beyond those in a test's
directory in ini manifests.

MozReview-Commit-ID: EmlDz9d4lqt
2016-04-04 14:56:52 -07:00
Carsten "Tomcat" Book
394034a83e Backed out changeset 0519406b6e57 (bug 1238177) for eslint test failures 2016-04-03 09:30:03 +02:00
Dave Huseby
32251ddc37 Bug 1238177 - Extension content needs to use the correct user context id origin attribute. r=bholley
--HG--
extra : amend_source : f8d3bb6f6b1426ac73669491b651900614f6461c
2016-04-02 13:14:00 -04:00
Matthew Wein
9c7f3d9e91 Bug 1185773 - Enable the moz-extension mochitest on android. r=kmag
MozReview-Commit-ID: ICxmwE1BI8A

--HG--
extra : transplant_source : %9B%BDd%0B%18%EC9Y%09%B9%25k%3F%9924%F2AaW
2016-03-28 10:04:59 -07:00
J. Ryan Stinnett
798c13a0fa Bug 1238160 - Test frame principal when toggling isolation. r=bz
Test frame principals in different configurations to verify the new isolated
attribute works as expected.

MozReview-Commit-ID: CQNRo2bK9iU
2016-03-02 10:35:56 -06:00
J. Ryan Stinnett
2a55d065b7 Bug 1238160 - Rename OriginAttributes.mInBrowser and associated methods. r=bz,mayhemer
This change renames OriginAttributes.mInBrowser to mInIsolatedMozBrowser and
nsIPrincipal::GetIsInBrowserElement to GetIsInIsolatedMozBrowserElement.  Other
methods that pass these values around also have name changes.

Tokens such as "inBrowser" have previously been serialized into cache keys, used
as DB column names, stored in app registries, etc.  No changes are made to any
serialization formats.  Only runtime method and variable names are updated.

No behavior changes are made in this patch, so some renamed methods may have
nonsensical implementations.  These are corrected in subsequent patches
focused on behavior.

MozReview-Commit-ID: 66HfMlsXFLs
2016-03-02 10:35:56 -06:00
Dave Huseby
4fdeeb7cf9 Bug 1229222 - tests for bug 1229222. r=sicking
(HEAD -> oa, refs/patches/oa/Bug_1229222_Tests)
Tests Bug 1229222

--HG--
extra : rebase_source : baf12ec8819e0e82b7d6f7cf4975636172d98eb6
2016-02-29 12:27:00 +01:00
Dave Huseby
0c0cf070cf Bug 1229222 - add chromeutils for the creation of origin attributes with the correct default values. r=sicking
(HEAD -> oa, refs/patches/oa/Bug_1229222)
Fixes Bug 1229222

--HG--
extra : rebase_source : 299742335452d5b5ac3cf25a3bd2d71ec655049f
2016-02-29 12:26:00 +01:00
Carsten "Tomcat" Book
9164177faa Backed out changeset 736daf4b4a56 (bug 1229222) for bc6 test failures in browser_339445.js 2016-02-19 15:56:27 +01:00
Dave Huseby
4f029016db Bug 1229222 - tests bug 1229222. r=sicking
(HEAD -> oa, refs/patches/oa/Bug_1229222_Tests)
Tests Bug 1229222
2016-02-17 12:19:00 +01:00
Blake Kaplan
5749c2ed94 Bug 1237141 - Make this test pass in e10s. r=felipe
--HG--
extra : rebase_source : e9aad0388bea8401c08f137357ca10720622bc05
2016-01-07 10:28:27 -08:00
Andrea Marchesini
a365470b87 Bug 1235657 - Session storage needs to handle origin attributes correctly - part 1 - createOriginAttributesWithUserContextId, r=huseby 2016-01-06 10:08:30 +00:00
Yoshi Huang
4b500464f5 Bug 1209162 - Create OriginAttributes subtypes. IGNORE IDL r=sicking. 2015-11-03 09:50:54 +08:00
Gijs Kruitbosch
f1d4d15e39 Bug 1210703 - followup: fix test file used in caps and fix assertions to have actual/expected value in the right order, rs=bustage on a CLOSED TREE
--HG--
extra : commitid : 29mAEwGdSuM
2015-11-09 19:10:23 +00:00
Bobby Holley
86c97bb3f4 Bug 1218039 - Add a nice interface for both C++ and JS to access the principal kind. r=gabor 2015-10-26 11:18:14 -07:00
Yoshi Huang
fb57af4ae6 Bug 1191653 - Listen to clear-origin-data in nsPermissionManager. r=bholley 2015-10-13 10:27:42 +08:00
Wes Kocher
5dc7315e7b Merge b2ginbound to central, a=merge 2015-10-07 11:04:26 -07:00
Carsten "Tomcat" Book
08997000eb Backed out 2 changesets (bug 1202902) to recking bug 1202902 to be able to reopen inbound on a CLOSED TREE
Backed out changeset 647025383676 (bug 1202902)
Backed out changeset d70c7fe532c6 (bug 1202902)
2015-10-07 14:03:21 +02:00
Carsten "Tomcat" Book
e7ef778c9d Backed out 1 changesets (bug 1202902) for causing merge conflicts to mozilla-central
Backed out changeset cfc1820361f5 (bug 1202902)

--HG--
extra : rebase_source : 5d3db72337754bc7ab0ed0c30b2896100411ff92
2015-10-07 12:13:45 +02:00
Shu-yu Guo
d06b6030f6 Bug 1202902 - Scripted fix the world. 2015-10-06 14:00:31 -07:00
Yoshi Huang
02f27f9218 Bug 1211636 - use ToInteger64 in PopulateFromSuffix. r=bholley
From 76c9c3f887d6bce8b15abd37d5921887a187e18d Mon Sep 17 00:00:00 2001
---
 caps/BasePrincipal.cpp                    | 16 ++++++-------
 caps/moz.build                            |  3 +++
 caps/tests/gtest/TestOriginAttributes.cpp | 37 +++++++++++++++++++++++++++++++
 caps/tests/gtest/moz.build                | 13 +++++++++++
 4 files changed, 61 insertions(+), 8 deletions(-)
 create mode 100644 caps/tests/gtest/TestOriginAttributes.cpp
 create mode 100644 caps/tests/gtest/moz.build
2015-10-06 15:36:10 +08:00
Bobby Holley
073c406ca3 Bug 1208756 - Tests. r=billm 2015-10-02 15:02:09 -07:00
Bobby Holley
ca4a8095de Bug 1209843 - Stop checking for UNKNOWN_APP_ID in all places except those where AppId() is explicitly queried. r=sicking 2015-09-30 16:29:36 -07:00
Stephanie Ouillon
5e14a3b3a8 Bug 1178533 - Add nsIInstallPackagedWebapp for registering permissions when navigating to signed packages r=bholley,fabrice,valentin 2015-08-26 13:12:13 +02:00
Yoshi Huang
d38b78ae54 Bug 1165466 - Fix up docshell and loadcontext inheriting code in nsIScriptSecurityManager. r=bholley 2015-09-23 16:10:21 +08:00
Henry Chang
b6b5862949 Bug 1163254 - Add signedPkg to OriginAttributes. r=bholley 2015-09-18 15:11:58 +08:00
Bobby Holley
43144ea83c Bug 1205456 - Check for UNKNOWN_APP_ID when serializing principals. r=sicking 2015-09-18 16:20:06 -07:00
Carsten "Tomcat" Book
c5551bace9 Backed out 2 changesets (bug 1169633, bug 1163254) for linux Mn-e10s test bustage on a CLOSED TREE
Backed out changeset 47ccf6689101 (bug 1169633)
Backed out changeset 503eab197a2d (bug 1163254)
2015-09-17 16:01:25 +02:00
hchang
2e884ff477 Bug 1163254 - Add signedPkg to OriginAttributes. r=bholley 2015-09-16 19:42:00 +02:00
Michael Layzell
274d644ee1 Bug 1192666 - Emit '[]' around origin strings for ipv6 origins, r=ehsan 2015-08-11 15:09:52 -04:00