Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(189)

Unified Diff: crypto/encryptor.h

Issue 10543146: Use NSS for symmetric key crypto operations on Windows and Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: removed DEPS; rebased Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « crypto/crypto.gyp ('k') | crypto/encryptor_mac.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: crypto/encryptor.h
diff --git a/crypto/encryptor.h b/crypto/encryptor.h
index 8a27a90f10d6e9f983bbf36ad48696abce880905..f2c0c8b3e22a9c88267e4368fbea7c146407b1cc 100644
--- a/crypto/encryptor.h
+++ b/crypto/encryptor.h
@@ -14,10 +14,8 @@
#include "build/build_config.h"
#include "crypto/crypto_export.h"
-#if defined(USE_NSS)
+#if defined(USE_NSS) || defined(OS_WIN) || defined(OS_MACOSX)
#include "crypto/scoped_nss_types.h"
-#elif defined(OS_WIN)
-#include "crypto/scoped_capi_types.h"
#endif
namespace crypto {
@@ -33,7 +31,7 @@ class CRYPTO_EXPORT Encryptor {
// This class implements a 128-bits counter to be used in AES-CTR encryption.
// Only 128-bits counter is supported in this class.
- class Counter {
+ class CRYPTO_EXPORT Counter {
public:
explicit Counter(const base::StringPiece& counter);
~Counter();
@@ -121,7 +119,7 @@ class CRYPTO_EXPORT Encryptor {
const base::StringPiece& input,
std::string* output);
std::string iv_;
-#elif defined(USE_NSS)
+#elif defined(USE_NSS) || defined(OS_WIN) || defined(OS_MACOSX)
bool Crypt(PK11Context* context,
const base::StringPiece& input,
std::string* output);
@@ -130,15 +128,6 @@ class CRYPTO_EXPORT Encryptor {
std::string* output);
ScopedPK11Slot slot_;
ScopedSECItem param_;
-#elif defined(OS_MACOSX)
- bool Crypt(int /*CCOperation*/ op,
- const base::StringPiece& input,
- std::string* output);
-
- std::string iv_;
-#elif defined(OS_WIN)
- ScopedHCRYPTKEY capi_key_;
- DWORD block_size_;
#endif
};
« no previous file with comments | « crypto/crypto.gyp ('k') | crypto/encryptor_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698