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

Side by Side Diff: base/sha1.cc

Issue 2052713002: Remove the CryptoAPI implementation of SHA-1 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix a few stragglers Created 4 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 unified diff | Download patch
« no previous file with comments | « base/base.gypi ('k') | base/sha1_portable.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/sha1.h" 5 #include "base/sha1.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string.h> 9 #include <string.h>
10 10
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 void SHA1HashBytes(const unsigned char* data, size_t len, 208 void SHA1HashBytes(const unsigned char* data, size_t len,
209 unsigned char* hash) { 209 unsigned char* hash) {
210 SecureHashAlgorithm sha; 210 SecureHashAlgorithm sha;
211 sha.Update(data, len); 211 sha.Update(data, len);
212 sha.Final(); 212 sha.Final();
213 213
214 memcpy(hash, sha.Digest(), SecureHashAlgorithm::kDigestSizeBytes); 214 memcpy(hash, sha.Digest(), SecureHashAlgorithm::kDigestSizeBytes);
215 } 215 }
216 216
217 } // namespace base 217 } // namespace base
OLDNEW
« no previous file with comments | « base/base.gypi ('k') | base/sha1_portable.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698