---
name: "RAND_cleanup"
section: "3ssl"
platform: "linux"
package: "openssl"
version: "3.6.5-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/RAND_cleanup"
---

# RAND\_cleanup(3ssl)

erase the PRNG state

## NAME

RAND\_cleanup - erase the PRNG state

## SYNOPSIS

```
 #include <openssl/rand.h>
```

The following function has been deprecated since OpenSSL 1.1.0, and can be hidden entirely by defining **OPENSSL\_API\_COMPAT** with a suitable version value, see **openssl\_user\_macros**(7):

```
 void RAND_cleanup(void);
```

## DESCRIPTION

Prior to OpenSSL 1.1.0, **RAND\_cleanup()** released all resources used by the PRNG.  As of version 1.1.0, it does nothing and should not be called, since no explicit initialisation or de-initialisation is necessary. See **OPENSSL\_init\_crypto**(3).

## RETURN VALUES

**RAND\_cleanup()** returns no value.

## SEE ALSO

**RAND**(7)

## HISTORY

**RAND\_cleanup()** was deprecated in OpenSSL 1.1.0; do not use it. See **OPENSSL\_init\_crypto**(3)

## COPYRIGHT

Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the Apache License 2.0 (the "License").  You may not use this file except in compliance with the License.  You can obtain a copy in the file LICENSE in the source distribution or at \<https://www.openssl.org/source/license.html\>.
