{"repo":"miladrahimi/php-jwt","free":true,"listed":false,"github":"https://github.com/miladrahimi/php-jwt","clone":"git clone https://github.com/miladrahimi/php-jwt.git","description":"A PHP implementation of JWT (JSON Web Token) generator, parser, verifier, and validator.","language":"PHP","stars":73,"topics":["jwt","php-jwt","json-web-token","php","jose"],"license":"MIT","category":"auth-billing-email","readme_excerpt":"PHP-JWT PHP-JWT is a PHP package built for encoding (generating), decoding (parsing), verifying, and validating JSON Web Tokens (JWTs). Its design emphasizes a fluent, user-friendly, and object-oriented interface, crafted with performance in mind. This package is listed in the official JWT.io PHP libraries directory. Supported algorithms: HMAC : HS256 , HS384 , and HS512 RSA : RS256 , RS384 , and RS512 RSA-PSS : PS256 , PS384 , and PS512 ECDSA : ES256 , ES256K , ES384 , and ES512 EdDSA : EdDSA and Ed25519 (require the sodium PHP extension), and Ed448 (requires PHP 8.4+) Supported features: Built-in and custom validations Multiple keys and kid header handling Documentation What is JWT? If you're not familiar with JWTs, you can refer to the Wikipedia page or visit JWT.io for more information. Installation Include the package in your Composer dependencies using the following command: Quick Start Here's an example demonstrating how to generate a JWT and parse it using the HS256 algorithm: Runnable examples: the examples/ directory has a self-contained script per algorithm using the sample keys in assets/keys/ . Run one with e.g. php examples/rs256.php , and swap in your own key where marked. HMAC Algorithms HMAC algorithms rely on symmetric keys, allowing a single key to encode (sign) and decode (verify) JWTs. The PHP-JWT package supports HS256 , HS384 , and HS512 HMAC algorithms. The example above showcases the utilization of an HMAC algorithm to both sign and verify a JWT. RSA ","default_branch":null,"files":null,"tree":[],"storefront":"/r/miladrahimi","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/miladrahimi/php-jwt/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}