Граф коммитов

74 Коммитов

Автор SHA1 Сообщение Дата
David Keeler 905443cc71 bug 1264771 - randomize key IDs in WebCrypto r=ttaubert
To import private keys, WebCrypto creates a generic PKCS#11 object with a chosen
key ID with PK11_CreateGenericObject and then looks up that object as a
SECKEYPrivateKey using PK11_FindKeyByKeyID. It turns out that this is only safe
to do as long as the ID is unique. If another SECKEYPrivateKey exists that has
the same key ID (realistically this will only happen if an identical key is
imported again), PK11_FindKeyByKeyID may return the other key. Since
SECKEYPrivateKey objects are unique and not meant to be shared, this causes
problems in that when one key is destroyed, the resources backing the other key
are no longer valid, and any cryptographic operations using that key will fail.
The solution is to use random IDs and check for preexisting keys. NSS doesn't
yet expose an elegant API for this, but this patch implements a workaround.

MozReview-Commit-ID: EvYMZxnBxTv

--HG--
extra : rebase_source : 50408e1af9eb3934b51a0f01e02aa4890e57ed03
2016-05-04 12:48:37 -07:00
David Keeler cbc656ba88 bug 1271350 - work around PK11_CreatePBEV2AlgorithmID generating a random salt when it shouldn't r=ttaubert
MozReview-Commit-ID: KHjiwPg2SBb

--HG--
extra : rebase_source : b712a557064a6b278f085bac2cbd9bbbc4591c42
2016-05-12 11:12:57 -07:00
Boris Zbarsky 20a2c90769 Bug 1268845. Make sure to set up an XPCWrappedNativeScope for SimpleGlobalObject globals on the main thread. r=bholley,ttaubert,ejpbruel 2016-05-10 20:57:29 -04:00
Kit Cambridge 33ba9ca5c8 Bug 1256488 - Use Base64 URL-encoding in `CryptoBuffer`. r=ttaubert
MozReview-Commit-ID: AGtDUBuDuu0

--HG--
extra : rebase_source : d4d6edbc9e6b66ea6b2f93bf1875f52621569dfc
2016-03-17 14:13:09 -07:00
Tim Taubert b89ffb551c Bug 842818 - Enable structured cloning for CryptoKeys across threads r=baku,keeler 2016-01-20 23:22:41 +01:00
Tim Taubert 22b4a52212 Bug 842818 - Run WebCrypto tests in Workers r=mt,rbarnes 2015-09-21 19:53:01 +02:00
Tim Taubert 7703774589 Bug 1243311 - Add structured cloning tests for CryptoKeys r=rbarnes 2016-03-09 21:18:38 +01:00
Tim Taubert d18dba5486 Bug 1250930 - Add test to ensure we're using the right global when creating WebCrypto objects r=bz 2016-03-08 11:16:29 +01:00
Martin Thomson e612132ce4 Bug 1241757 - Permit export of JWK with empty key_ops field, r=rbarnes
--HG--
extra : rebase_source : 65bfd25c8c814a236028ddf611f4a0ef0beb7031
2016-01-22 18:07:39 +11:00
Tim Taubert eb297346b0 Bug 1191936 - Add more test vectors and a test for deterministic signatures r=rbarnes 2016-01-22 15:37:35 +01:00
Tim Taubert 49dd294551 Bug 1191936 - Implement SPKI/PKCS#8/JWK import/export for RSA-PSS r=rbarnes 2015-10-14 13:38:05 +02:00
Tim Taubert 38e4db6e5e Bug 1191936 - Implement RSA-PSS signing and verification r=rbarnes,smaug 2015-10-13 20:22:43 +02:00
Tim Taubert ae3b4977e3 Bug 1191936 - Implement RSA-PSS key generation r=rbarnes 2015-10-13 18:48:18 +02:00
Tim Taubert d01d161b5e Bug 1200341 - Implement HKDF for WebCrypto r=rbarnes,smaug 2016-01-26 14:57:52 +01:00
Tim Taubert b6e7b0db70 Bug 1216109 - Enable SHA-2 test for the WebCrypto API's PBKDF2 implementation r=mt 2015-11-17 11:50:24 +01:00
Tim Taubert a12e738be5 Bug 1214597 - Ensure that we check the actual result of calling crypto.subtle.verify() in tests r=mt 2015-10-14 13:40:14 +02:00
Tim Taubert ec47fbba39 Bug 1188750 - Add test to ensure NSS is initialized before the WebCrypto API tries to deserialize a key f=keeler r=khuey 2015-09-01 11:03:27 +02:00
Tim Taubert 9a87f6a0e5 Bug 1050175 - Add raw import/export for EC public keys to the WebCrypto API r=rbarnes,smaug 2015-04-28 09:13:16 +02:00
Tim Taubert c71dd812ff Bug 1106087 - Add test to ensure we can export newly generated ECDH private keys r=rbarnes 2015-04-24 16:07:56 +02:00
Tim Taubert 46997cc8c2 Bug 1133747 - Fix intermittent test_WebCrypto_Reject_Generating_Keys_Without_Usages.html failures by requesting a longer timeout r=rbarnes 2015-05-22 01:56:18 -04:00
Tim Taubert fd7b810617 Bug 1074139 - Bump test timeout to fix intermittent test_WebCrypto_RSA_OAEP.html timeouts r=rbarnes 2015-04-27 10:02:12 +02:00
Tim Taubert 5167199f60 Bug 1166031 - Use 1024-bit prime for WebCrypto's DH tests. r=mt
--HG--
extra : rebase_source : 1dcaa181e58700328cae8662386ddcb742a6df9d
2015-05-20 19:51:00 -04:00
Martin Thomson 4c2b709af0 Bug 1158296 - Allow ECDSA key export in WebCrypto, r=rbarnes
--HG--
extra : rebase_source : 40b14fe47652045c063ac40974147b5bfcc91630
2015-04-24 12:56:46 -07:00
Mark Banner d4d7432759 Bug 1147940 - Remove the dom.webcrypto.enabled pref as it is no longer necessary. r=smaug,r=rbarnes 2015-04-08 19:23:05 +01:00
Tim Taubert a281818e46 Bug 1085369 - Move other long-running tests to separate test files r=keeler 2015-01-06 12:03:22 +01:00
Tim Taubert 73d0b18acc Bug 1085369 - Move key wrapping/unwrapping tests to their own test file r=rbarnes 2014-10-20 18:08:51 +02:00
Guilherme Goncalves 2997c4e001 Bug 1088042 - Fix JsonWebKey object in test_WebCrypto_JWK. r=rbarnes 2014-10-23 09:07:00 +02:00
Tim Taubert 96e8ed9b9a Bug 1034856 - Implement SPKI public key import/export for DH r=rbarnes 2014-08-22 15:32:15 +02:00
Tim Taubert c1d2b2fa82 Bug 1034856 - Implement raw public key import/export for DH r=rbarnes,smaug 2014-08-22 12:02:14 +02:00
Tim Taubert 1d4ba08090 Bug 1034856 - Implement deriveBits() for DH r=rbarnes,smaug 2014-08-21 17:51:51 +02:00
Tim Taubert 5fc05b064c Bug 1034856 - Implement generateKey() for DH r=rbarnes 2014-07-20 06:38:44 +02:00
Richard Barnes f5092e255e Bug 1034854 - Add support for ECDSA to WebCrypto API r=ttaubert,dkeeler r=bz 2014-10-13 23:19:00 +02:00
Tim Taubert a164f4b49a Bug 1078847 - GenerateAsymmetricKeyTask should allow generating key pairs where only the public key or the private key has any usages r=rbarnes 2014-10-07 00:47:21 +02:00
David Keeler 0dd623409d bug 1080746 - WebCrypto: test import/export of an RSA private key with p < q r=rbarnes 2014-10-09 14:43:26 -07:00
Richard Barnes 63afe24da8 Bug 1037892 - Implement changes to WebCrypto API from latest Editor's Draft r=bz,ttaubert 2014-09-27 14:22:57 -04:00
Wes Kocher 6341575225 Backed out changeset 398bdeea30b0 (bug 1037892) for build bustage 2014-09-26 15:35:38 -07:00
Richard Barnes 8a9d1659d6 Bug 1037892 - Implement changes to WebCrypto API from latest Editor's Draft r=bz,ttaubert
* * *
Add check for old structured clone format.
2014-09-26 17:36:39 -04:00
Tim Taubert afff23ff06 Bug 1050318 - Split WebCrypto tests into multiple files to prevent timeouts r=rbarnes 2014-08-19 10:52:58 +02:00
Tim Taubert 87275fa3d8 Bug 1048133 - Check key algorithms before using them for encryption/signatures r=rbarnes a=abillings 2014-08-04 14:31:17 +02:00
Tim Taubert 0b53ce7ae8 Bug 1050318 - Split WebCrypto tests into multiple files to prevent timeouts r=rbarnes 2014-08-07 22:24:52 +02:00
Tim Taubert 340058c912 Bug 1050785 - RSA-OAEP encrypt/decrypt should accept strings as AlgorithmIdentifiers r=rbarnes 2014-08-08 16:45:08 +02:00
Tim Taubert e51e01cadd Bug 1050202 - Take length parameter into account when deriving HMAC keys r=rbarnes,smaug 2014-08-07 12:52:28 +02:00
Tim Taubert d3f757e062 Bug 1034855 - Implement SPKI import/export for ECDH r=keeler,rbarnes 2014-08-04 09:39:12 +02:00
Tim Taubert 454efc0d1e Bug 1034855 - Implement deriveKey() for ECDH r=rbarnes 2014-07-29 12:37:06 +02:00
Tim Taubert a04d2cdc94 Bug 1034855 - Implement JWK import/export for ECDH r=rbarnes,keeler 2014-07-29 11:10:07 +02:00
Tim Taubert 40e956b12c Bug 1034855 - Implement deriveBits() for ECDH r=rbarnes,smaug 2014-07-29 11:11:26 +02:00
Tim Taubert d4733a1ad7 Bug 1034855 - Implement generateKey() for ECDH r=rbarnes,keeler 2014-07-26 08:01:14 +02:00
Ryan VanderMeulen cdc1306825 Backed out 6 changesets (bug 1034855) for LSAN leaks on a CLOSED TREE.
Backed out changeset 0dc569f74991 (bug 1034855)
Backed out changeset 4eb0ee62db1e (bug 1034855)
Backed out changeset 4af8993f1534 (bug 1034855)
Backed out changeset f4f5f5b8421d (bug 1034855)
Backed out changeset 33510bb7ad60 (bug 1034855)
Backed out changeset 50b8670329aa (bug 1034855)
2014-08-05 14:04:08 -04:00
Tim Taubert 2d06be68cb Bug 1034855 - Implement SPKI import/export for ECDH r=keeler,rbarnes 2014-08-04 09:39:12 +02:00
Tim Taubert ad2acd36ae Bug 1034855 - Implement deriveKey() for ECDH r=rbarnes 2014-07-29 12:37:06 +02:00