This describes how to install LinOTP community edition on your system from PyPI using pip. On PyPI the latest packages of the community edition should be available.
You might want to install it in a python virtualenv. So first prepare your virtualenv:
virtualenv --no-site-packages linotp-demo cd linotp-demo source bin/activate
Now you can install linotp:
pip install linotpLater you can upgrade your installation like this:
pip install --upgrade linotp linotpuseridresolver
You need an imaging module for creating QR codes. so do a:
pip install pil
If you want to do PAM authentication, you also can install pam_py_linotp for later use:
pip install pam_py_linotp
This installs the server and the useridresolver. Now you need to configure the server by editing the file etc/linotp2/linotp.ini.
Find the line that defines your database:
sqlalchemy.url = mysql://user:password@localhost/LinOTP2
Of course you need to create the database on your database server and grant access for the specified user.
pip search mysql pip install MySQL-python
Given that you create the database and also granted access for the user, you can now create the tables by issuing the command:
paster setup-app etc/linotp2/linotp.ini
You need to create a log directory, which was defined in your etc/linotp2/linotp.ini file:
mkdir /var/log/linotp
Check the access rights of the directry.
Finally you need to create an encrytion key:
dd if=/dev/random of=etc/linotp2/encKey bs=1 count=96
There are different possibilities to run LinOTP. The easiest way for testing ist to run via paster.
So now you can start the LinOTP server like this:
paster serve etc/linotp2/linotp.ini
You can go to http://localhost:5001/manage to take a look around through the management. Enroll your first token and try to authenticate on the test page http://localhost/auth/index.
For running LinOTP in Apache Webserver take a look at the next howto.