Git Product home page Git Product logo

mojolicious-command-secret's Introduction

NAME

Mojolicious::Command::secret - Create application secrets() consisting of random bytes

MOJOLICIOUS VERSION

If your Mojolicious version is less than 4.63 then you must use version 0.02 of this module.

DESCRIPTION

Tired of manually creating and adding secrets? Me too! Use this command to create secrets and automatically add them to your Mojolicous or Mojolicious::Lite application:

./script/your_app secret
./lite_app secret

This will modify the appropriate application file, though existing secrets will not be overridden unless the -f option is used.

It is assumed that your file contains UTF-8 data and that you use $self or app to refer to your application instance.

If you do not want to automatically add secrets to your application use the mojo secret command or the -p option and the secrets will be printed to STDOUT instead:

mojo secret
./script/your_app secret -p

OPTIONS

-c, --count     N              Generate N secrets. Defaults to 1.
-f, --force                    Overwrite an existing secret. Defaults to 0.
-g, --generator MODULE=method  Module & method to generate the secret. The method must
                               accept an integer argument. Defaults to Crypt::URandom=urandom.
                               and Crypt::OpenSSL::Random=random_bytes
-p, --print                    Print the secret, do not add it to your application.
-s, --size      SIZE           Number of bytes to use. Defaults to 32.

Default options can be added to the MOJO_SECRET_OPTIONS environment variable.

SEE ALSO

Crypt::URandom, Crypt::OpenSSL::Random

AUTHOR

(c) 2012 Skye Shaw

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

mojolicious-command-secret's People

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.