Commit Graph
123 Commits
Author SHA1 Message Date
David Keeler 58a0201d3e bug 1349312 - part 1/2: patch CT implementation to include debug-only test logs r=Cykesiopka,jcj
MozReview-Commit-ID: Gay4bliuiDc

This modifies getCTKnownLogs.py to inject 3 debug-only Certificate Transparency
log keys and 2 organizations ("Mozilla Test Org 1" and "2") for use with
integration tests. Also updates CTKnownLogs.h as generated by the python script.

The debug logs use the "default", "secp256r1", and "alternate" keys that are
already present in our testing infrastructure (see pykey.py).
2017-04-19 14:02:26 -07:00
David Keeler 44b297ed96 bug 1356499 - put NCSCCS pins into production mode r=mgoodwin
As requested by James Burton<[email protected]> and vouched for (via email) by
Lucas Garron <[email protected]>.

MozReview-Commit-ID: HD9laXzJpRg
2017-04-25 14:33:07 -07:00
Franziskus Kiefer 1bb1d92d05 Bug 1345368 - root hashes follow-up 2017-04-13 10:42:05 +02:00
Franziskus Kiefer 85f31a7ad5 Bug 1345368 - land NSS 7228445b43ac, r=me 2017-04-10 06:00:57 +02:00
Mark Banner 7945b07153 Bug 1342459 - Enable no-undef on browser/base, and clean up unnecessary no-undef references. r=mossop
MozReview-Commit-ID: KVrAnAjMD1E
2017-04-03 11:46:56 +01:00
Cykesiopka 9e9b4824a1 Bug 1350868 - Make HSTS preload script preload test domains for use in tests. r=keeler
This lets us migrate off depending on real preloaded domains and onto
domains that are guaranteed to have the correct characteristics.

MozReview-Commit-ID: 4TyOfdIA9I7
2017-03-29 07:21:01 +08:00
Cykesiopka d490973d2b Bug 1319252 - Remove nsIX509Cert.getAllTokenNames(). r=keeler,mossop
nsIX509Cert.getAllTokenNames() is only used (improperly) to determine if a
certificate is a built-in. nsIX509Cert.isBuiltInRoot should be used instead.

MozReview-Commit-ID: LBwI8nTc05C
2017-03-19 16:02:26 +08:00
Sam Foster 56364d223b Bug 1344308 - Extend toolkit's eslint rules and fix lint errors in PSM r=jaws
* Remove eslint rules for PSM which are redundant with toolkit/.eslintrc.js
* Fix missing plugins block in mochitest.eslintrc.js
* Disable brace-style checking in mixed-content mochitests which use boilerplate where calls to runTest and afterNavigationTest all use opening brace on newline. I've left this for a follow-up.
* Fix lint errors resulting from new rules defined by toolkit's eslintrc.js

MozReview-Commit-ID: EepCLrzAsdM
2017-03-07 10:15:49 -08:00
Jonathan Hao b00c3630c6 Bug 1323644 - Isolate the HSTS and HPKP storage by first party domain (PSM) r=Cykesiopka,keeler
MozReview-Commit-ID: HhFFqtpBNjO
2017-02-14 10:29:10 +08:00
David Major c93b8c136b Bug 1335294: Remove const from data tables under security/ for better codegen on Windows. r=keeler
MozReview-Commit-ID: 3k1Gpm0ugY2
2017-02-13 09:41:20 +13:00
Cykesiopka e99d55a74b Bug 1331983 - Avoid non-smart string IDL types in nsIX509CertDB.idl. r=gcp,keeler,nwgh
Smart string classes like nsCString are safer to use than raw |char*| strings,
and are typically easier to deal with as well.

MozReview-Commit-ID: 2PdrCa6cbpe
2017-02-09 23:11:29 +08:00
Phil Ringnalda c71c5d0871 Merge m-c to a CLOSED TREE autoland 2017-02-01 20:42:06 -08:00
Phil Ringnalda 9854db1db2 Backed out changeset b03c9f4ac1b0 (bug 1335294) for Windows PGO bustage
CLOSED TREE
2017-02-01 19:17:21 -08:00
David Major 4f2b90c05d Bug 1335294: Add constexpr to data tables under security/ for better codegen on Windows. r=keeler
MozReview-Commit-ID: 3OMBGfLKP9I
2017-02-01 14:59:57 +13:00
J.C. Jones 9aece17c3b Bug 1335466 - Regenerate the CA RootHashes.inc r=keeler
This is a maintenance re-run since Firefox 50, to include new roots.

MozReview-Commit-ID: HSs2P6S65A7
2017-02-01 16:45:07 -07:00
Cykesiopka 76ae0bbf79 Bug 1329248 - Enable 26 more ESLint rules for PSM. r=mgoodwin
The "no-mixed-spaces-and-tabs" rule is also disabled since there's no point
having it enabled when the "no-tabs" rule is also enabled.

MozReview-Commit-ID: 49addnnmmvf
2017-01-14 13:18:03 +08:00
Florian Quèze 6459975a67 Bug 1329182 - remove trailing newURI null parameters in the rest of the tree, r=jaws. 2017-01-09 20:27:26 +01:00
Cykesiopka 702c39b3be Bug 1324184 - Enable "no-tabs", "no-template-curly-in-string" and "quotes" ESLint rules for PSM. r=keeler
Also sorts the rule list alphabetically.

MozReview-Commit-ID: 9LwgwfiViom
2016-12-21 00:43:17 +08:00
David Keeler 0cad676aa4 bug 857627 - 2/4: remove nsIX509Cert.nickname r=Cykesiopka,jcj
In general, any code that was using nsIX509Cert.nickname should be able to use
the attribute displayName (if using nickname for display purposes) or the
attribute dbKey (if using nickname as a unique identifier for a certificate).

MozReview-Commit-ID: G9CfMJDfLqe
2016-11-18 13:12:29 -08:00
Sergei Chernov f507518bbf Bug 1317951, part 2 - Certificate Transparency - basic support for disqualified logs. r=keeler
MozReview-Commit-ID: 4y2JYFnO9Xm
2016-11-29 22:51:46 +02:00
Julien Vehent 172b2851ad bug 1301956 - add more Mozilla resources to preloaded pins r=keeler,rbarnes DONTBUILD NPOTB
Also trims the pinset for said Mozilla resources to just DigiCert and Let's
Encrypt (as a backup).
2016-11-29 13:15:32 -08:00
Sergei Chernov bb2e3bd410 Bug 1308787 - Certificate Transparency - script for generating the static list of known logs. r=Cykesiopka,keeler
MozReview-Commit-ID: 9z7Ac5OQqOP
2016-11-08 13:54:39 +02:00
Mark Banner 233309fbe2 Bug 1251003 - Change .eslintrc files to .eslintrc.js to avoid obsolete config file format. r=mossop
MozReview-Commit-ID: JrbFxQ5rj6I
2016-10-18 08:38:10 +01:00
David Keeler 057bec9813 bug 1282008 - update CNNIC whitelist to remove expired certificates r=rbarnes
MozReview-Commit-ID: 1OopsrAxXrv
2016-10-06 14:45:51 -07:00
Carsten "Tomcat" Book 9c3068b78c merge mozilla-inbound to mozilla-central a=merge 2016-09-08 12:01:17 +02:00
Thomas Wisniewski a1a4c002e4 Bug 918751 - Throw NetworkErrors instead of failures where appropriate for some XHR web platform tests. r=bz, r=keeler, r=Mossop, r=paul 2016-09-03 18:45:08 -04:00
David Keeler 302a6a8ceb bug 1300305 - update preloaded HPKP information to deal with "Equifax Secure CA" removal DONTBUILD NPOTB r=Cykesiopka
The root with the nickname "Equifax Secure CA" was removed from NSS in bug
1296689 (confusingly, "Equifax Secure CA" doesn't appear in the subject DN of
that certificate, which is "OU=Equifax Secure Certificate
Authority,O=Equifax,C=US"). This removes the dependency on that root as well as
fixes dumpGoogleRoots.js to automatically handle this sort of thing in the
future.

MozReview-Commit-ID: KIEPBnliufX
2016-09-06 10:45:48 -07:00
David Keeler edc5ae373b bug 1298056 - fix HSTS preload update script so it will continue when requests result in errors r=jcj DONTBUILD NPOTB a=KWierso
MozReview-Commit-ID: b697Aa4iqQ
2016-08-26 14:18:39 -07:00
Thomas Wisniewski a23b5fbd86 Bug 709991 - Fire onerror instead of throwing on network errors for async XHRs. r=bz 2016-07-30 00:24:56 -04:00
Cykesiopka c4adadea47 Bug 1280331 - Update HPKP preload script URL to deal with renaming of transport_security_state_static.certs. r=keeler
https://chromium.googlesource.com/chromium/src/net/+/4361f2ad66b6af0a8acfb42f34b95bfbcad3926a
renamed transport_security_state_static.certs to
transport_security_state_static.pins, so the URL needs to be updated to avoid
a 404.

MozReview-Commit-ID: 1FmYdi0mMcI
2016-06-21 16:11:57 -07:00
David Keeler f7bdcad952 bug 1266563 - regenerate CA telemetry hash table r=jcj
MozReview-Commit-ID: 1NXDU2ejfzl
2016-06-03 16:12:38 -07:00
Nathan Froyd ce69e56e22 Bug 1255425 - part 2 - pack kSTSPreloadList into a more efficient format; r=keeler
Entries in kSTSPreloadList currently look like:

class nsSTSPreload
{
  public:
    const char *mHost;
    const bool mIncludeSubdomains;
};

This is inefficient for a couple of reasons:

* The structure has a bunch of wasted space: it takes 8 bytes on 32-bit
  platforms and 16 bytes on 64-bit platforms, even though it only uses 5
  and 9 bytes, respectively.

* The |const char*| requires additional space in the form of relocations
  (at least on Linux/Android), which doubles the space cost of
  individual entries.  (The space cost of the relocations is mitigated
  somewhat on Linux and Android because of elfhack, but there's still
  extra cost in the on-disk format and during the load of libxul to
  process those relocations.)

* The relocations the structure requires means that the data in it can't
  be shared between processes, which is important for e10s with multiple
  content processes.

We can make it more efficient by structuring it like so:

static const char kSTSPreloadHosts[] = {
  // One giant character array containing the hosts, in order:
  //   "example.com\0example.org\0example.test\0..."
  // Use an array rather than a literal string due to compiler limitations.
};

struct nsSTSPreload
{
  // An index into kSTSPreloadHosts for the hostname.
  uint32_t mHostIndex: 31;
  // We use the same datatype for both members so that MSVC will pack
  // the bitfields into a single uint32_t.
  uint32_t mIncludeSubdomains: 1;
};

nsSTSPreload now has no wasted space and is significantly smaller,
especially on 64-bit platforms (saves ~29K on 32-bit platforms and ~85K
on 64-bit platforms).  This organization does add a couple extra
operations to searching for preload list entries, depending on your
platform, but the space savings make it worth it.
2016-03-24 15:09:28 -04:00
Nathan Froyd 0102478fd1 Bug 1255425 - part 1 - clearly delineate steps when outputting HSTS preload list; r=keeler
The main loop of |output| tweaks entries, filters out entries based on
some conditions, and writes out the actual entries we're going to use.
Let's separate those three steps so it's clearer what's happening where.
2016-03-11 15:35:47 -05:00
Cykesiopka 2f86602233 Bug 1253108 - Enable ESLint "strict" rule for PSM. r=keeler
MozReview-Commit-ID: 4wElZ8Guq9z
2016-03-19 03:07:13 -07:00
Cykesiopka 6c90f0c49c Bug 1251011 - Enable ESLint "no-undef" rule for PSM. r=keeler r=mossop
MozReview-Commit-ID: 1lbwWWkJjqq
2016-03-16 16:50:33 -07:00
Nicholas Nethercote 010738d0b0 Bug 1255655 - Const-ify kPinset_* arrays. r=cykesiopka. 2016-03-11 13:54:41 +11:00
Cykesiopka fe6f41d55e Bug 1253958 - Make getHSTSPreloadList.js and genHPKPStaticPins.js gracefully handle trailing whitespace in URL entries. r=dkeeler
MozReview-Commit-ID: Kyc7JzxVEo0
2016-03-06 16:02:52 -08:00
Cykesiopka d004b449f6 Bug 1250254 - Enable ESLint "no-throw-literal" rule for PSM. r=dkeeler
MozReview-Commit-ID: LZcitO0FTWH
2016-02-29 20:05:55 -08:00
Cykesiopka 847979f65a Bug 1249595 - Enable 11 more ESLint rules for PSM. r=keeler
MozReview-Commit-ID: FxS9SPRMMxf
2016-02-26 12:35:34 -08:00
Cykesiopka 7dcf95f70f Bug 1246365 - Enable eslint "comma-spacing" and "semi" rules for PSM. r=keeler
MozReview-Commit-ID: 7FVcD7O9mpG
2016-02-18 21:16:50 -08:00
Cykesiopka cb9e9286ee Bug 1244245 - Enable eslint "curly" rule for PSM. r=keeler
Also includes minor cleanup.

MozReview-Commit-ID: CHgbTIa3s2O
2016-02-16 17:27:49 -08:00
ISHIKAWA, Chiaki 9ee69e3ce0 Bug 1248252 - Improper outdated octal constant syntax in M-C tree. Use '0o' prefix. r=dao
Be warned. Do not attemp to change the .js "test" source code in ./js
They are meant to check

 - the outdated 0666 octal constant is still parsed correctly,
 - the outdated 0666 octal constant raises syntax error flag
   in strict mode, etc.

So leave them alone.
2016-02-15 08:57:00 +01:00
David Keeler 4791c2e567 bug 1246765 - remove unnecessary resource://app/ registration from getHSTSPreloadList.js r=Cykesiopka DONTBUILD NPOTB 2016-02-08 12:56:34 -08:00
Cykesiopka 1fb0f58774 Bug 1243182 - Enable eslint "space-infix-ops" rule for PSM. r=keeler
Also includes minor cleanups.
2016-02-06 21:05:02 -08:00
Cykesiopka 766c803884 Bug 1242254 - Enable initial set of eslint rules for PSM. r=dkeeler
These rules are copied from toolkit/.eslintrc (with non-passing rules excluded and previously commented out and passing rules included).
2016-01-24 02:35:36 -08:00
Cykesiopka f1b973c2ec Bug 1233328 - Part 2: Use SHA-256 StaticFingerprints directly instead of StaticPinset since the SHA-1 StaticFingerprints entry will always be null. r=keeler 2016-01-20 20:45:29 -08:00
David Keeler a143125769 bug 1232766 - update the preloaded pinset for Google domains r=rbarnes
Also includes a script for making this process faster in the future.
2015-12-28 12:30:14 -08:00
Cykesiopka b4e37d3f4b Bug 1229284 - Remove support for SHA-1 hashes in genHPKPStaticPins.js. r=keeler 2015-12-17 07:52:00 +01:00
Cykesiopka 881cd1f94b Bug 1224968 - Support public key input to unbreak periodic HPKP updates. r=keeler
https://chromium.googlesource.com/chromium/src/net/+/be448badb1982bfa13572d430774ff6f275aeb0c%5E!/#F0 switched SHA1 hashes to public keys for static pins. This broke genHPKPStaticPins.js and thus periodic HPKP updates, since the file doesn't handle public keys.

The changes here mostly mirror https://github.com/agl/transport-security-state-generate/commit/ba1f296240ceed7a84ee4a79a4eb23afea965621.
2015-12-01 00:30:00 +01:00
Cykesiopka 0df7640219 Bug 1224481 - Comment out CA certs removed in NSS 3.21 in PreloadedHPKPins.json to keep periodic Static HPKP updates working. r=dkeeler 2015-11-13 07:28:28 -08:00