Tue, 06 Jan 2015 21:39:09 +0100
Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4 #ifndef nsSyncJPAKE_h__
5 #define nsSyncJPAKE_h__
7 #include "nsISyncJPAKE.h"
9 #define NS_SYNCJPAKE_CONTRACTID \
10 "@mozilla.org/services-crypto/sync-jpake;1"
12 #define NS_SYNCJPAKE_CID \
13 {0x0b9721c0, 0x1805, 0x47c3, {0x86, 0xce, 0x68, 0x13, 0x79, 0x5a, 0x78, 0x3f}}
15 typedef struct PK11SymKeyStr PK11SymKey;
17 class nsSyncJPAKE : public nsISyncJPAKE
18 {
19 public:
20 NS_DECL_ISUPPORTS
21 NS_DECL_NSISYNCJPAKE
22 nsSyncJPAKE();
23 virtual ~nsSyncJPAKE();
24 private:
25 enum { JPAKENotStarted, JPAKEBeforeRound2, JPAKEAfterRound2 } round;
26 PK11SymKey * key;
27 };
29 NS_IMPL_ISUPPORTS(nsSyncJPAKE, nsISyncJPAKE)
31 #endif // nsSyncJPAKE_h__