OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CRYPTO_RANDOM_H_ | |
6 #define CRYPTO_RANDOM_H_ | |
7 #pragma once | |
8 | |
9 #include <string> | |
10 | |
11 // GetRandomBytes fills |output_length| bytes of |output| with | |
12 // cryptographically strong random data. | |
13 void GetRandomBytes(void* output, size_t output_length); | |
Ryan Sleevi
2011/04/27 02:32:24
This makes the third implementation to get random
wtc
2011/04/28 19:42:22
GetRandomBytes should be moved to base/rand_util.h
| |
14 | |
15 // Generate128BitRandomBase64String returns a string of length 22 containing | |
16 // cryptographically strong random data encoded in base64. | |
17 std::string Generate128BitRandomBase64String(); | |
wtc
2011/04/28 19:42:22
API design issue: this function is not generally u
abarth-chromium
2011/04/29 07:47:11
http://codereview.chromium.org/6904118/ contains a
wtc
2011/04/29 18:07:08
abarth: yes. Your RandString function is equivale
| |
18 | |
19 #endif // CRYPTO_RANDOM_H_ | |
OLD | NEW |