[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
8.6 Invoking srptool
The ‘srptool’ is a very simple program that emulates the programs in the Stanford SRP libraries, see http://srp.stanford.edu/. It is intended for use in places where you don’t expect SRP authentication to be the used for system users.
Traditionally libsrp used two files. One called tpasswd
which holds usernames and verifiers, and tpasswd.conf
which
holds generators and primes.
How to use srptool:
-
To create tpasswd.conf which holds the g and n values for
SRP protocol (generator and a large prime), run:
$ srptool --create-conf /etc/tpasswd.conf
-
This command will create /etc/tpasswd and will add user ’test’ (you
will also be prompted for a password). Verifiers are stored by
default in the way libsrp expects.
$ srptool --passwd /etc/tpasswd \ --passwd-conf /etc/tpasswd.conf -u test
-
This command will check against a password. If the password matches
the one in /etc/tpasswd you will get an ok.
$ srptool --passwd /etc/tpasswd \ --passwd-conf /etc/tpasswd.conf --verify -u test