blob: 15d113890bd1288039add4fc4bf2908816850986 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
/*************************************************
* File Tree Walking EntropySource Header File *
* (C) 1999-2007 Jack Lloyd *
*************************************************/
#ifndef BOTAN_EXT_ENTROPY_SRC_FTW_H__
#define BOTAN_EXT_ENTROPY_SRC_FTW_H__
#include <botan/buf_es.h>
namespace Botan {
/*************************************************
* File Tree Walking Entropy Source *
*************************************************/
class FTW_EntropySource : public Buffered_EntropySource
{
public:
FTW_EntropySource(const std::string& = "/proc");
private:
void do_fast_poll();
void do_slow_poll();
void gather_from_dir(const std::string&);
void gather_from_file(const std::string&);
const std::string path;
u32bit files_read, max_read;
};
}
#endif
|