BIO_S_NULL(3ossl)

✨ BIO_S_NULL(3ossl) ✨

okay bestie, welcome to the BIO_s_null page β€” the OpenSSL 3ossl manual, but make it cute πŸ’–


🌸 NAME 🌸

BIO_s_null β€” a null data sink, aka the void that eats your bytes πŸ•³οΈβœ¨


πŸŽ€ SYNOPSIS πŸŽ€

#include <openssl/bio.h>

const BIO_METHOD *BIO_s_null(void);

πŸ’… DESCRIPTION πŸ’…

BIO_s_null() hands you back the null sink BIO method. That's it, that's the whole vibe. Whatever you write into the null sink? Discarded. Gone. Poof. 🫧 And if you try to read from it, the reads just return EOF. It's giving "no thoughts, head empty" and honestly? Iconic. πŸ’€


πŸ¦‹ NOTES πŸ¦‹

A null sink BIO is lowkey the OpenSSL twin of the Unix /dev/null device. Same energy, different era. ✨

You can slap a null bio on the end of a chain and it'll just absorb any data that passes through it, no drama, no notes. 🧚

And here's the main character use case, iykyk: say an application wants to digest some data by writing through a digest bio, but doesn't actually want to send the digested data anywhere. Normally a BIO chain has to include a source/sink BIO, so the move is β€” you guessed it β€” add a null sink BIO to the end of the chain. Problem solved, data digested, nothing shipped. Slay. πŸ‘‘


⭐ RETURN VALUES ⭐

BIO_s_null() returns the null sink BIO method. Every single time. No surprises, no plot twists. πŸŽ€


Copyright 2000-2016 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>.


k that's the whole page bestie, tysm for reading 🫢 this was OpenSSL 3.5.9, dated 2026-09-29, and yes it's still BIO_S_NULL(3ossl) β€” go forth and discard your data responsibly πŸ’–βœ¨πŸŒˆ

πŸ“¦ where this page comes from