Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CONTENT_RENDERER_WEBCRYPTO_SHA_DIGEST_H_ | |
| 6 #define CONTENT_RENDERER_WEBCRYPTO_SHA_DIGEST_H_ | |
| 7 | |
| 8 #include "base/compiler_specific.h" | |
| 9 | |
| 10 #if defined(USE_NSS) | |
| 11 #include <pk11pub.h> | |
| 12 #endif | |
| 13 | |
| 14 #include "third_party/WebKit/public/platform/WebCrypto.h" | |
| 15 #include "third_party/WebKit/public/platform/WebCryptoAlgorithm.h" | |
| 16 | |
| 17 namespace content { | |
| 18 | |
| 19 class WebCryptoSHADigest : public WebKit::WebCryptoOperation { | |
| 20 public: | |
| 21 WebCryptoSHADigest(const WebKit::WebCryptoAlgorithmId); | |
|
eroman
2013/07/19 01:11:13
nit: mark as "explicit"
Bryan Eyler
2013/07/24 00:33:53
Done.
| |
| 22 | |
| 23 virtual void process(const unsigned char*, size_t) OVERRIDE; | |
|
eroman
2013/07/19 01:11:13
nit: add the parameter names (blink style omits th
Bryan Eyler
2013/07/24 00:33:53
Done.
| |
| 24 | |
| 25 virtual void abort() OVERRIDE; | |
| 26 | |
| 27 virtual void finish(WebKit::WebCryptoOperationResult*) OVERRIDE; | |
|
eroman
2013/07/19 01:11:13
Add the parameter name
Bryan Eyler
2013/07/24 00:33:53
Removed param as part of new interface.
| |
| 28 | |
| 29 private: | |
| 30 virtual ~WebCryptoSHADigest(); | |
| 31 | |
| 32 #if defined(USE_NSS) | |
| 33 PK11Context* context_; | |
| 34 SECOidTag hash_algorithm_; | |
| 35 | |
| 36 bool InitializeContext(); | |
| 37 #endif | |
| 38 }; | |
| 39 | |
| 40 } // namespace content | |
| 41 | |
| 42 #endif // CONTENT_RENDERER_WEBCRYPTO_IMPL_H_ | |
|
eroman
2013/07/19 01:11:13
Update this comment
Bryan Eyler
2013/07/24 00:33:53
Done.
| |
| OLD | NEW |