Changeset View
Changeset View
Standalone View
Standalone View
src/support/allocators/secure.h
// Copyright (c) 2009-2010 Satoshi Nakamoto | // Copyright (c) 2009-2010 Satoshi Nakamoto | ||||
// Copyright (c) 2009-2016 The Bitcoin Core developers | // Copyright (c) 2009-2016 The Bitcoin Core developers | ||||
// Distributed under the MIT software license, see the accompanying | // Distributed under the MIT software license, see the accompanying | ||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | // file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
#ifndef BITCOIN_SUPPORT_ALLOCATORS_SECURE_H | #ifndef BITCOIN_SUPPORT_ALLOCATORS_SECURE_H | ||||
#define BITCOIN_SUPPORT_ALLOCATORS_SECURE_H | #define BITCOIN_SUPPORT_ALLOCATORS_SECURE_H | ||||
#include "support/cleanse.h" | #include <support/cleanse.h> | ||||
#include "support/lockedpool.h" | #include <support/lockedpool.h> | ||||
#include <string> | #include <string> | ||||
// | // | ||||
// Allocator that locks its contents from being paged | // Allocator that locks its contents from being paged | ||||
// out of memory and clears its contents before deletion. | // out of memory and clears its contents before deletion. | ||||
// | // | ||||
template <typename T> struct secure_allocator : public std::allocator<T> { | template <typename T> struct secure_allocator : public std::allocator<T> { | ||||
Show All 36 Lines |