carlonicora/minimalism-service-encrypter

Id encrypter service for minimalism

4.0.1 2019-05-14 00:00 UTC

README

encrypter is a service for minimalism to generate short unique ids from integers.

Getting Started

To use this library, you need to have an application using minimalism. This library does not work outside this scope.

Prerequisite

You should have read the minimalism documentation and understand the concepts of services in the framework.

Encrypter requires either the BC Math or GMP extension in order to work.

Installing

Require this package, with Composer, in the root directory of your project.

$ composer require carlonicora/minimalism-service-encrypter

or simply add the requirement in composer.json

{
    "require": {
        "carlonicora/minimalism-service-encrypter": "~1.0"
    }
}

Deployment

This service requires you to set up two parameters in your .env file in order to produce unique encrypted ids.

Required parameters

#a random string used to encrypt your ids
MINIMALISM_SERVICE_ENCRYPTER_KEY=  

Optional parameters

#default to 18
MINIMALISM_SERVICE_ENCRYPTER_LENGTH=

Build With

Versioning

This project use Semantiv Versioning for its tags.

Authors

  • Carlo Nicora - Initial version - GitHub | phlow
  • Sergey Kuzminich - maintenance and expansion - GitHub |

License

This project is licensed under the MIT license - see the LICENSE.md file for details

License: MIT