A C++11 single-file header-only cross-platform HTTP/HTTPS library. It's extremely easy to setup. Just include the httplib.h file in your code! This is a multi-threaded 'blocking' HTTP library. If you are looking for a 'non-blocking' library, this is not the one that you want. SSL support is available with CPPHTTPLIB_OPENSSL_SUPPORT. libssl and libcrypto should be linked. When using SSL, it seems impossible to avoid SIGPIPE in all cases, since on some operating systems, SIGPIPE can only be suppressed on a per-message basis, but there is no way to make the OpenSSL library do so for its internal communications. If your program needs to avoid being terminated on SIGPIPE, the only fully general way might be to set up a signal handler for SIGPIPE to handle or ignore it yourself. cpp-httplib officially supports only the latest Visual Studio. It might work with former versions of Visual Studio, but I can no longer verify it.

Features

  • Bind a socket to multiple interfaces and any available port
  • Static file server
  • Built-in mappings
  • Post routing handler
  • Pre routing handler
  • Receive content with a content receiver

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow cpp-httplib

cpp-httplib Web Site

Other Useful Business Software
Passwordless Authentication and Passwordless Security Icon
Passwordless Authentication and Passwordless Security

Identity is everything. Protect it with Duo.

It’s no secret — passwords can be a real headache, both for the people who use them and the people who manage them. Over time, we’ve created hundreds of passwords, it’s easy to lose track of them and they’re easily compromised. Fortunately, passwordless authentication is becoming a feasible reality for many businesses. Duo can help you get there.
Get a Free Trial
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of cpp-httplib!

Additional Project Details

Operating Systems

Windows

Programming Language

C++

Related Categories

C++ Application Servers, C++ Libraries

Registered

2021-11-22