awesome-repositories.com
Blog
awesome-repositories.com

Découvrez les meilleurs dépôts open-source grâce à notre recherche par IA.

ExplorerRecherches sélectionnéesAlternatives open sourceLogiciels auto-hébergésBlogPlan du site
ProjetÀ proposNotre méthodologiePresseServeur MCP
Mentions légalesConfidentialitéConditions d'utilisation
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
php-fig avatar

php-fig/http-message

0
View on GitHub↗
7,049 stars·186 forks·PHP·MIT·1 vuewww.php-fig.org/psr/psr-7↗

Http Message

PSR-7 HTTP Message Interfaces is a set of standardized PHP interfaces for representing HTTP request and response messages, URIs, streams, and uploaded files as immutable value objects. These interfaces define a common contract that enables interoperability between PHP frameworks and libraries when handling HTTP messages, ensuring that any implementation can be used interchangeably.

The interfaces model HTTP messages as immutable value objects where any modification produces a new instance, guaranteeing message integrity throughout the request lifecycle. They provide case-insensitive header access and retrieval, support for multi-valued headers, and stream-based body handling that enables efficient processing of large payloads without loading them entirely into memory. For server-side requests, the interfaces abstract PHP superglobals into structured objects with attributes for application-specific routing, and normalize uploaded file trees into consistent nested structures with safe file movement and stream access methods.

URI handling is provided through immutable value objects that parse RFC 3986 URIs once and expose individual component accessors for scheme, authority, path, query, and fragment. The interfaces also include validation mechanisms that reject malformed header names and values to prevent injection attacks and parsing errors. The package consists solely of interfaces and does not include any implementations, serving as a foundational contract for the PHP ecosystem.

Features

  • Immutable HTTP Message Models - Models HTTP messages as immutable value objects, the foundational concept of the PSR-7 standard.
  • Immutable HTTP Message - Models HTTP messages as immutable value objects, the core architectural pattern of this package.
  • PHP Interface Standards - Defines the PSR-7 standard interfaces for HTTP messages, the core contract for PHP interoperability.
  • Uploaded File Interfaces - Defines the PSR-7 UploadedFileInterface for safe file handling from PHP superglobals.
  • Streamed Message Body Interfaces - Defines a stream interface for HTTP message bodies as a core part of the PSR-7 standard.
  • Uploaded File Tree Normalizations - Provides a standard interface for normalizing PHP uploaded file data into structured objects.
  • Parameter Bag Abstractions - Wraps PHP superglobals into structured request objects with typed parameter bag access.
  • Multi-Value Headers - Supports returning header values as comma-separated strings or arrays for multi-valued headers.
  • Casing Normalization - Normalizes HTTP header casing for case-insensitive retrieval while preserving original casing.
  • Case-Insensitive Header Normalizers - Provides case-insensitive header normalization as a core part of the PSR-7 HTTP message interface.
  • URI Construction and Parsing - Parses and composes HTTP and HTTPS URIs according to RFC 3986 with component accessors.
  • URI Segment Readers and Modifiers - Provides accessors for individual URI segments like scheme, authority, path, query, and fragment.
  • URI Value Object Interfaces - Defines the PSR-7 UriInterface for immutable URI value objects with component accessors.
  • URI Value Object Parsings - Parses URIs once into value objects for efficient component access without repeated parsing.
  • URI Value Object Representations - Represents URIs as immutable value objects parsed once for efficient segment access.
  • HTTP Message Mapping - Models HTTP messages as immutable value objects, the foundational concept of the PSR-7 standard.
  • Unified Message Element Accessors - Provides unified access to protocol version, headers, and body as a core part of the PSR-7 message interface.
  • Standardized HTTP Message Interfaces - Provides the standardized interface for HTTP request and response messages, the core of the PSR-7 standard.
  • HTTP Header Accessors - Provides case-insensitive header access and retrieval as a core part of the PSR-7 HTTP message interface.
  • PHP Superglobal Request Abstractions - Abstracts PHP superglobals into structured request objects as a core part of the PSR-7 server request interface.
  • Standardized HTTP Request Interfaces - Defines the standard interface for HTTP request messages as a core part of the PSR-7 standard.
  • Standardized HTTP Response Interfaces - Defines the standard interface for HTTP response messages as a core part of the PSR-7 standard.
  • Server-Side Request Parameter Accessors - Provides access to server-side request parameters as a core part of the PSR-7 server request interface.
  • Body Streaming - Models message bodies as streamable objects for efficient processing of large payloads.
  • Stream Interfaces - Provides the PSR-7 StreamInterface for efficient body handling without full memory loading.
  • PHP Superglobal Abstractions - Abstracts PHP superglobals into structured request objects as a core part of the PSR-7 server request interface.
  • Uploaded File Tree Normalizations - Normalizes PHP uploaded file data into a predictable tree of file objects.
  • Host Header Rewriting - Synchronizes the Host header with the URI's host component as a feature of the PSR-7 request interface.
  • URI-Based Host Header Synchronizers - Synchronizes the Host header with the URI's host component as a feature of the PSR-7 request interface.
  • Safe Uploaded File Movers - Provides safe file movement for uploaded files as a feature of the PSR-7 uploaded file interface.
  • Uploaded File Tree Normalizers - Normalizes the PHP $_FILES array into a consistent tree structure as a feature of the PSR-7 uploaded file interface.
  • HTTP Header Validations - Enforces standardized naming and value constraints on HTTP headers to prevent injection attacks.
  • Header Name and Value Validations - Rejects malformed header names and values to prevent CRLF injection and parsing attacks.
  • Request Target Overrides - Allows overriding the default request target to support specialized HTTP request forms.
  • Request-Target Form Handlers - Supports all four forms of the HTTP request-target as a feature of the PSR-7 request interface.
  • Request Target Representations - Defines the four standard forms of HTTP request targets for message representation.

Historique des stars

Graphique de l'historique des stars pour php-fig/http-messageGraphique de l'historique des stars pour php-fig/http-message

Recherche par IA

Explorez plus de dépôts awesome

Décrivez vos besoins en langage naturel — l'IA classe des milliers de projets open source sélectionnés par pertinence.

Start searching with AI

Questions fréquentes

Que fait php-fig/http-message ?

PSR-7 HTTP Message Interfaces is a set of standardized PHP interfaces for representing HTTP request and response messages, URIs, streams, and uploaded files as immutable value objects. These interfaces define a common contract that enables interoperability between PHP frameworks and libraries when handling HTTP messages, ensuring that any implementation can be used interchangeably.

Quelles sont les fonctionnalités principales de php-fig/http-message ?

Les fonctionnalités principales de php-fig/http-message sont : Immutable HTTP Message Models, Immutable HTTP Message, PHP Interface Standards, Uploaded File Interfaces, Streamed Message Body Interfaces, Uploaded File Tree Normalizations, Parameter Bag Abstractions, Multi-Value Headers.

Quelles sont les alternatives open-source à php-fig/http-message ?

Les alternatives open-source à php-fig/http-message incluent : boostorg/beast — Beast is a C++ library for implementing low-level HTTP and WebSocket clients and servers. It functions as an… ralouphie/getallheaders — This project is a PHP environment compatibility library and polyfill designed to provide a consistent interface for… codeigniter4/codeigniter4 — CodeIgniter is a PHP web framework built on the Model-View-Controller pattern, designed for building full-stack web… aplus-framework/http — This library provides a foundational set of tools for managing HTTP communication within PHP web applications. It… zendframework/zendframework — Zend Framework is a comprehensive set of decoupled components for building modular, event-driven web applications. It… elastic/elasticsearch-php — This project is a software development kit and cluster management tool for PHP. It serves as a full-text search SDK…

Alternatives open source à Http Message

Projets open source similaires, classés selon le nombre de fonctionnalités partagées avec Http Message.
  • boostorg/beastAvatar de boostorg

    boostorg/beast

    4,801Voir sur 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
    Voir sur GitHub↗4,801
  • codeigniter4/codeigniter4Avatar de codeigniter4

    codeigniter4/CodeIgniter4

    5,924Voir sur GitHub↗

    CodeIgniter is a PHP web framework built on the Model-View-Controller pattern, designed for building full-stack web applications. It provides a lightweight toolkit with minimal configuration, organizing application logic into controllers, models, and views for clean separation of concerns. The framework includes a fluent query builder for constructing SQL statements programmatically, PSR-4 autoloading with namespace mapping, and a service-based dependency injection container for managing shared class instances. The framework distinguishes itself through its comprehensive set of built-in tools

    PHPcodeignitercodeigniter4framework-php
    Voir sur GitHub↗5,924
  • ralouphie/getallheadersAvatar de ralouphie

    ralouphie/getallheaders

    3,795Voir sur GitHub↗

    This project is a PHP environment compatibility library and polyfill designed to provide a consistent interface for retrieving all incoming HTTP request headers. It functions as a request header parser that extracts and normalizes raw server variables into a predictable associative array. The library ensures cross-platform behavior by detecting missing native functions at runtime and injecting fallback implementations. This allows for standardized request header retrieval and server variable normalization across diverse server architectures and configurations.

    PHP
    Voir sur GitHub↗3,795
  • aplus-framework/httpAvatar de aplus-framework

    aplus-framework/http

    237Voir sur GitHub↗

    This library provides a foundational set of tools for managing HTTP communication within PHP web applications. It focuses on the lifecycle of client-server interactions by parsing incoming request data into structured objects and facilitating the construction of protocol-compliant server responses. The architecture is built around immutable data structures that ensure state consistency throughout the application lifecycle. It incorporates lazy header parsing to reduce memory overhead and utilizes stream-based management for handling request and response payloads. By adhering to established co

    PHPanti-csrfaplusaplus-framework
    Voir sur GitHub↗237
Voir les 30 alternatives à Http Message→