ost::SSLStream(3)

πŸ“¦ version 1.8.1, in ubuntu jammy

πŸ’– ost::SSLStream πŸ’–

okay so bestie, welcome to the SSLStream page from the Library Functions Manual β€” yeah, section 3, the library functions one, you know the vibe. this is the GNU CommonC++ SSL stream class and it's literally the moment your sockets get the little padlock. πŸ”’βœ¨


🌸 NAME 🌸

ost::SSLStream β€” no cap, that's the whole name. iconic behavior honestly.


✨ SYNOPSIS ✨

first things first, you gotta pull it in:

#include <ssl.h>

and the way that it inherits from ost::TCPStream?? yeah. it's giving "secure glow-up of a TCP stream." main character energy fr fr. πŸ’…

πŸŽ€ Public Member Functions πŸŽ€

here's the whole roster, every single one, no skipping:

SSLStream (Family family=IPV4, bool throwflag=true, timeout_t to=0)
void disconnect (void)
SSLStream (const IPV4Host &host, tpport_t port, unsigned mss=536, bool
    throwflag=true, timeout_t to=0)
SSLStream (const IPV6Host &host, tpport_t port, unsigned mss=536, bool
    throwflag=true, timeout_t to=0)
SSLStream (const char *name, Family family=IPV4, unsigned mss=536, bool
    throwflag=false, timeout_t to=0)
SSLStream (const SSLStream &ssl)
bool isSSL (void)
bool getSession (void)
void endStream (void)
virtual ~SSLStream ()
ssize_t readLine (char *str, size_t max, timeout_t to=0)
ssize_t readData (void *buf, size_t len, char separator=0, timeout_t
    to=0)
ssize_t writeData (void *buf, size_t len, timeout_t to=0)

like… five constructors, a destructor, and the whole read/write situation. she does it all. 🫢

πŸ”’ Protected Attributes πŸ”’

SSL * ssl

just the raw SSL pointer, living its protected little life. iykyk. πŸ™ˆ

🌈 Additional Inherited Members 🌈

there's more stuff inherited from the parent class, but it lives over on the TCPStream page, not here. go check her out. πŸ’œ


🧚 Constructor & Destructor Documentation 🧚

  • ost::SSLStream::SSLStream (Family family = IPV4, bool throwflag = true, timeout_t to = 0)
  • ost::SSLStream::SSLStream (const IPV4Host & host, tpport_t port, unsigned mss = 536, bool throwflag = true, timeout_t to = 0)
  • ost::SSLStream::SSLStream (const IPV6Host & host, tpport_t port, unsigned mss = 536, bool throwflag = true, timeout_t to = 0)
  • ost::SSLStream::SSLStream (const char * name, Family family = IPV4, unsigned mss = 536, bool throwflag = false, timeout_t to = 0)
  • ost::SSLStream::SSLStream (const SSLStream & ssl)
  • virtual ost::SSLStream::~SSLStream () [virtual]

okay so six of them. yes six. five constructors and one virtual destructor, and the destructor is marked [virtual] so it cleans up properly when you delete through a base pointer. she's polite like that. πŸŽ€


πŸ’« Member Function Documentation πŸ’«

  • void ost::SSLStream::disconnect (void) β€” cut the connection loose. bye bestie πŸ‘‹
  • void ost::SSLStream::endStream (void) β€” wrap up the stream, we're done here.
  • bool ost::SSLStream::getSession (void) β€” hands you back a bool about the session. yes queen, tell us. πŸ’…
  • bool ost::SSLStream::isSSL (void) [inline] β€” inline, fast, and it References ssl. that's the whole note, and honestly? valid.
  • ssize_t ost::SSLStream::readData (void * buf, size_t len, char separator = 0, timeout_t to = 0) [virtual] β€” Reimplemented from ost::Socket. so if you were looking for the OG version, she's over there.
  • ssize_t ost::SSLStream::readLine (char * str, size_t max, timeout_t to = 0) β€” reads you a line. classic.
  • ssize_t ost::SSLStream::writeData (void * buf, size_t len, timeout_t to = 0) β€” writes your data out. go off. πŸ”₯

πŸ‘‘ Member Data Documentation πŸ‘‘

  • SSL* ost::SSLStream::ssl [protected] β€” protected, and Referenced by isSSL(). so like, isSSL() is literally peeking at her. besties fr. 🫢

🌟 Author 🌟

Generated automatically by Doxygen for GNU CommonC++ from the source code.

so nobody hand-wrote this, Doxygen did it, and we respect the automation grind. πŸ€–βœ¨


and that's the whole page bestie!! πŸ’– this was GNU CommonC++, dated Sun Dec 27 2020, and it's the ost::SSLStream(3) page β€” thank you for coming to my ted talk, go secure those streams, mwah πŸ’‹πŸŒΈ

πŸ“¦ where this page comes from