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

Side by Side Diff: chrome/common/extensions/api/networking_private/networking_private_crypto.h

Issue 1548153002: Switch to standard integer types in chrome/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CRYPT O_H_ 5 #ifndef CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CRYPT O_H_
6 #define CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CRYPT O_H_ 6 #define CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CRYPT O_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 #include "base/basictypes.h"
14 13
15 namespace networking_private_crypto { 14 namespace networking_private_crypto {
16 15
17 // Verify that the credentials described by |certificate| and |signed_data| 16 // Verify that the credentials described by |certificate| and |signed_data|
18 // are valid as follows: 17 // are valid as follows:
19 // 1) The MAC address listed in the certificate matches |connected_mac|. 18 // 1) The MAC address listed in the certificate matches |connected_mac|.
20 // 2) The certificate is a valid PEM encoded certificate signed by trusted CA. 19 // 2) The certificate is a valid PEM encoded certificate signed by trusted CA.
21 // 3) |signature| is a valid signature for |data|, using the public key in 20 // 3) |signature| is a valid signature for |data|, using the public key in
22 // |certificate| 21 // |certificate|
23 bool VerifyCredentials( 22 bool VerifyCredentials(
(...skipping 18 matching lines...) Expand all
42 // EncryptByteString. Used in NetworkingPrivateCryptoTest::EncryptString test. 41 // EncryptByteString. Used in NetworkingPrivateCryptoTest::EncryptString test.
43 // Returns true on success, storing the decrypted result in 42 // Returns true on success, storing the decrypted result in
44 // |decrypted_output|. 43 // |decrypted_output|.
45 bool DecryptByteString(const std::string& private_key_pem, 44 bool DecryptByteString(const std::string& private_key_pem,
46 const std::vector<uint8_t>& encrypted_data, 45 const std::vector<uint8_t>& encrypted_data,
47 std::string* decrypted_output); 46 std::string* decrypted_output);
48 47
49 } // namespace networking_private_crypto 48 } // namespace networking_private_crypto
50 49
51 #endif // CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CR YPTO_H_ 50 #endif // CHROME_COMMON_EXTENSIONS_API_NETWORKING_PRIVATE_NETWORKING_PRIVATE_CR YPTO_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698