|
OpenXPKI::Template::Plugin::RandomPasswordThis module implements a Template Toolkit plugin that generates randomly generated passwords in RFC2307 syntax. The used alphabet is Base64.How to useIn your template, use the following line at the beginning of the file to load the plugin:[% USE password = RandomPassword -%] After doing so, you can use the class like this: ... <digest>[% password.generate(scheme => 'ssha', callback => 'sub { print STDERR "*** NOTE: Password for user <John Doe> is: $_\n" }') %]</digest> ... This invocation will call the generate() method on the template's password instance variable. It passes the named parameters 'scheme' and 'callback' to the function. The return value of the method is rendered into the template output. generateGenerates a random password and returns the encrypted value.Named parameters:
Visit the GSP FreeBSD Man Page Interface. |