2015-01-20 21:23:25 -03:00
|
|
|
// Copyright (c) 2009-2010 Satoshi Nakamoto
|
2019-12-30 06:39:22 -03:00
|
|
|
// Copyright (c) 2009-2019 The Bitcoin Core developers
|
2015-01-20 21:23:25 -03:00
|
|
|
// Distributed under the MIT software license, see the accompanying
|
|
|
|
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
|
|
|
|
|
|
|
#ifndef BITCOIN_SUPPORT_CLEANSE_H
|
|
|
|
#define BITCOIN_SUPPORT_CLEANSE_H
|
|
|
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
2019-06-05 16:44:04 -04:00
|
|
|
/** Secure overwrite a buffer (possibly containing secret data) with zero-bytes. The write
|
|
|
|
* operation will not be optimized out by the compiler. */
|
2015-01-20 21:23:25 -03:00
|
|
|
void memory_cleanse(void *ptr, size_t len);
|
|
|
|
|
|
|
|
#endif // BITCOIN_SUPPORT_CLEANSE_H
|