IDEA block cipher added
[rofl0r-kripto.git] / lib / memwipe.c
blobb22f11473dac32d7e0c1236f9c774f046eccc346
1 /*
2 * Written in 2011 by Gregor Pintar <grpintar@gmail.com>
4 * To the extent possible under law, the author(s) have dedicated
5 * all copyright and related and neighboring rights to this software
6 * to the public domain worldwide.
7 *
8 * This software is distributed without any warranty.
10 * You should have received a copy of the CC0 Public Domain Dedication.
11 * If not, see <http://creativecommons.org/publicdomain/zero/1.0/>.
14 #include <stddef.h>
15 #include <stdint.h>
17 #include <kripto/memwipe.h>
19 void kripto_memwipe(void *dst, size_t len)
21 volatile uint8_t *x = dst;
23 while(len--) *x++ = '\0';