Download the PHP package petrknap/data-signer without Composer
On this page you can find all versions of the php package petrknap/data-signer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download petrknap/data-signer
More information about petrknap/data-signer
Files in petrknap/data-signer
Package data-signer
Short Description Data Signer
License LGPL-3.0-or-later
Homepage https://github.com/petrknap/php-data-signer
Informations about the package data-signer
Data Signer
This library provides a logic for digital signing and validating of a binary data.
Inputs and outputs are binary data, don't be afraid to use the petrknap/binary.
Implementations
- Edwards-curve Digital Signature Algorithm (Ed25519)
- Hash-based Message Authentication Code (HMAC)
- Sodium (Ed25519)
Usage
The basic use of a Data Signer interface is quite simple:
Domain-specific signing
If you need to limit the validity of the signature to a specific purpose (domain), just set it to the Data Signer service:
Time-limited signing
If you need to limit the validity of the signature to specific time (expiration), just give it to the Data Signer's method sign:
Signable data transfer object
If you communicate through data transfer objects, you can use a Signable Data interface:
Communication trough 3rd party machine
If you need to sign data forwarded trough 3rd party machine (f.e. by token or cookie), you can use the Signature with data:
WARNING: The data are only signed (readable), use the petrknap/crypto-sodium if you need to encrypt them.
Run composer require petrknap/data-signer to install it.
You can support this project via donation.
The project is licensed under the terms of the LGPL-3.0-or-later.
All versions of data-signer with dependencies
petrknap/binary Version ^4.0|^5.0
petrknap/optional Version ^3.3
petrknap/shorts Version ^3.0
psr/clock Version ^1.0