awesome-repositories.com
博客
awesome-repositories.com

通过 AI 驱动的搜索,发现最优秀的开源仓库。

探索精选搜索开源替代品自托管软件博客网站地图
项目关于排名机制媒体报道MCP 服务器
法律隐私政策服务条款
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
yhirose avatar

yhirose/cpp-httplib

0
View on GitHub↗
16,597 星标·2,698 分支·C++·MIT·6 次浏览yhirose.github.io/cpp-httplib↗

Cpp Httplib

This is a header-only C++ library that provides implementations for HTTP clients, HTTP servers, and a WebSocket framework. It allows for the creation of network services and the consumption of remote APIs without requiring a separate compilation step or external binary linking.

The project features backend-agnostic TLS integration for secure HTTPS and WSS communication and employs a thread-pool model to process concurrent requests. It distinguishes itself with a full-duplex WebSocket state-machine and a middleware-based request pipeline that supports regular-expression path routing.

The library covers a broad range of networking capabilities, including server-sent events for real-time streaming, multipart form data parsing, and static file serving. It also includes traffic management tools for proxy routing, as well as security features such as peer certificate validation and system certificate store integration.

The implementation can be converted into C++ modules to improve compilation speeds.

Features

  • C++ Networking Libraries - A header-only C++ library providing a full suite of HTTP client, server, and WebSocket implementations.
  • Header-Only Libraries - Distributed as a header-only library to eliminate the need for separate compilation or binary linking.
  • HTTP Client Libraries - Implements a full-featured HTTP client for sending requests and processing responses from remote servers.
  • Websocket Connection Managers - Features a full-duplex state machine for managing persistent WebSocket connection lifecycles and frame exchange.
  • WebSocket Clients and Servers - Implements both client and server capabilities for the bidirectional WebSocket protocol.
  • HTTP Clients - Provides a comprehensive C++ HTTP client for executing network requests and managing connectivity.
  • HTTP Servers - Provides a lightweight HTTP server for listening on ports and handling incoming web requests.
  • Real-Time Web Communication - Provides persistent bidirectional connections for real-time data exchange via WebSockets.
  • WebSocket Clients - Implements a WebSocket client for establishing bidirectional connections using secure or insecure schemes.
  • WebSocket Servers - Provides a WebSocket server that listens on specified paths and manages bidirectional communication channels.
  • Thread Pools - Employs a thread-pool model to distribute incoming network requests across worker threads for concurrency.
  • Network Encryption - Implements TLS encryption for secure HTTPS and WSS communication through a backend-agnostic interface.
  • Secure Network Communication - Implements encrypted data transfer using TLS for secure HTTPS and WSS communication.
  • Embedded Web Servers - Implements a lightweight HTTP server designed to be embedded directly into C++ applications.
  • HTTP Request Clients - Provides a C++ client for executing standard HTTP requests to interact with remote APIs.
  • HTTP Servers - Provides a complete C++ HTTP server implementation for handling, routing, and serving web traffic.
  • Request Routing - Maps incoming HTTP request URLs to specific handler functions using path-based and regular expression routing.
  • Route Pattern Matching - Supports mapping incoming request URLs to handler functions via regular expression patterns.
  • Response Streaming - Supports reading response bodies incrementally from the network socket to minimize memory overhead.
  • Inter-Process Communication - Enables high-performance local data exchange between processes using Unix domain sockets.
  • Lifecycle Request Handlers - Executes pre-request handlers to validate headers or authenticate requests before processing the body.
  • Middleware-Based Request Pipelines - Utilizes a middleware pipeline to intercept and modify network requests and responses.
  • Server-Sent Events - Streams real-time updates from the server to clients using a chunked provider for Server-Sent Events.
  • Transport Abstractions - Abstracts the transport layer to support both TCP/IP and Unix domain sockets.
  • Pluggable TLS Backends - Provides a pluggable architecture to integrate various TLS backends for secure communication.
  • WebSocket Security - Provides secure WebSocket communication using the wss scheme and certificate verification.
  • Response Streaming - Implements memory-efficient incremental delivery of large HTTP response bodies.
  • Multipart Form Parsing - Extracts uploaded files and text fields from multipart POST requests with integrated filename sanitization.
  • Incremental Body Processing - Processes incoming request data incrementally using a content receiver to avoid loading entire payloads into memory.
  • Request Middleware - Implements a middleware pipeline to execute custom logic before and after the routing process.
  • Web Tooling Development - Enables the creation of standalone network utilities and proxies within a single C++ binary.
  • Subprotocol Negotiation - Handles the exchange of protocol headers during the WebSocket handshake to agree on specific application protocols.
  • Networking - Cross-platform HTTP server/client.
  • Networking and Utilities - HTTP server and client library.
  • 网络库 - Header-only HTTP/HTTPS server library.
  • Web and Networking - Cross-platform HTTP and HTTPS library.

Star 历史

yhirose/cpp-httplib 的 Star 历史图表yhirose/cpp-httplib 的 Star 历史图表

AI 搜索

探索更多 awesome 仓库

用简单的语言描述您的需求 —— AI 将根据相关性为您从数千个精选开源项目中进行排序。

Start searching with AI

常见问题解答

yhirose/cpp-httplib 是做什么的?

This is a header-only C++ library that provides implementations for HTTP clients, HTTP servers, and a WebSocket framework. It allows for the creation of network services and the consumption of remote APIs without requiring a separate compilation step or external binary linking.

yhirose/cpp-httplib 的主要功能有哪些?

yhirose/cpp-httplib 的主要功能包括:C++ Networking Libraries, Header-Only Libraries, HTTP Client Libraries, Websocket Connection Managers, WebSocket Clients and Servers, HTTP Clients, HTTP Servers, Real-Time Web Communication。

yhirose/cpp-httplib 有哪些开源替代品?

yhirose/cpp-httplib 的开源替代品包括: ithewei/libhv — libhv is a high-performance C/C++ network library and event-driven I/O framework used to build TCP, UDP, SSL, HTTP,… boostorg/beast — Beast is a C++ library for implementing low-level HTTP and WebSocket clients and servers. It functions as an… encode/httpx — This project is a comprehensive Python network request framework designed for both synchronous and asynchronous HTTP… javalin/javalin — Javalin is a lightweight web framework for Java and Kotlin designed for building REST APIs and web applications. It… nanohttpd/nanohttpd — NanoHTTPD is a lightweight, embeddable HTTP server for Java applications. It allows developers to integrate web server… hyperium/hyper — Hyper is a low-level networking library designed for building high-performance HTTP clients and servers. It provides a…

Cpp Httplib 的开源替代方案

相似的开源项目,按与 Cpp Httplib 的功能重合度排序。
  • ithewei/libhvithewei 的头像

    ithewei/libhv

    7,521在 GitHub 上查看↗

    libhv is a high-performance C/C++ network library and event-driven I/O framework used to build TCP, UDP, SSL, HTTP, WebSocket, and MQTT clients and servers. It provides a non-blocking event loop for managing network sockets, timers, and system signals across multiple threads. The project is distinguished by its integrated support for specialized network roles, including a full HTTP web server with RESTful routing and middleware, an MQTT messaging client for IoT communication, and the ability to implement SOCKS5 and HTTP proxies. It also features a reliable UDP implementation to ensure ordered

    Ccurlepollhttp-client
    在 GitHub 上查看↗7,521
  • boostorg/beastboostorg 的头像

    boostorg/beast

    4,801在 GitHub 上查看↗

    Beast is a C++ library for implementing low-level HTTP and WebSocket clients and servers. It functions as an asynchronous networking framework designed to compose non-blocking I/O operations and layered stream stacks for managing concurrent network traffic, specifically utilizing the Boost.Asio asynchronous model. The library provides a comprehensive implementation of the HTTP/1.1 and WebSocket protocols. For HTTP, it includes primitives for parsing and serializing messages with support for chunked transfer encoding, incremental body reading, and request pipelining. Its WebSocket implementati

    C++asioasync-programmingboost
    在 GitHub 上查看↗4,801
  • encode/httpxencode 的头像

    encode/httpx

    15,090在 GitHub 上查看↗

    This project is a comprehensive Python network request framework designed for both synchronous and asynchronous HTTP communication. It provides a high-performance client capable of executing non-blocking requests within event-driven applications, while also supporting standard blocking calls for simpler scripts. The library is built to operate natively across diverse asynchronous runtimes, automatically detecting and utilizing the underlying event loop for concurrency. What distinguishes this library is its modular architecture, which decouples request construction from network execution thro

    Pythonasynciohttppython
    在 GitHub 上查看↗15,090
  • javalin/javalinjavalin 的头像

    javalin/javalin

    8,290在 GitHub 上查看↗

    Javalin is a lightweight web framework for Java and Kotlin designed for building REST APIs and web applications. It functions as an embedded Jetty web server, allowing applications to run as standalone processes without the need for an external servlet container. The project provides specialized frameworks for diverse communication patterns, including a REST API framework with automatic OpenAPI schema generation, a GraphQL API framework with query and mutation resolvers, and a WebSocket server for bidirectional real-time communication. It also includes a dedicated framework for pushing real-t

    Kotlinhacktoberfestjavajavalin
    在 GitHub 上查看↗8,290
  • 查看 Cpp Httplib 的所有 30 个替代方案→