]> Cypherpunks.ru repositories - pyderasn.git/blob - doc/install.rst
Reuse import
[pyderasn.git] / doc / install.rst
1 Install
2 =======
3
4 Preferable way is to :ref:`download <download>` tarball with the
5 signature from `official website <http://pyderasn.cypherpunks.ru/>`__::
6
7     $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-6.2.tar.xz
8     $ [fetch|wget] http://pyderasn.cypherpunks.ru/pyderasn-6.2.tar.xz.sig
9     $ gpg --verify pyderasn-6.2.tar.xz.sig pyderasn-6.2.tar.xz
10     $ xz --decompress --stdout pyderasn-6.2.tar.xz | tar xf -
11     $ cd pyderasn-6.2
12     $ python setup.py install
13     # or copy pyderasn.py (+six.py, possibly termcolor.py) to your PYTHONPATH
14
15 PyDERASN depends on `six <https://pypi.org/project/six/>`__ package
16 for keeping compatibility with Py27/Py35. It is included in the tarball.
17 You can also find it mirrored on :ref:`download <download>` page.
18
19 You could use pip (**no** OpenPGP authentication is performed!) with PyPI::
20
21     $ cat > requirements.txt <<EOF
22     pyderasn==6.2 --hash=sha256:TO-BE-FILLED
23     six==1.14.0 --hash=sha256:236bdbdce46e6e6a3d61a337c0f8b763ca1e8717c03b369e87a7ec7ce1319c0a
24     EOF
25     $ pip install --requirement requirements.txt
26
27 You have to verify downloaded tarballs integrity and authenticity to be
28 sure that you retrieved trusted and untampered software. `GNU Privacy
29 Guard <https://www.gnupg.org/>`__ is used for that purpose.
30
31 For the very first time it is necessary to get signing public key and
32 import it. It is provided below, but you should check alternative
33 resources.
34
35 ::
36
37     pub   rsa2048/0x04A933D1BA20327A 2017-09-20
38           2ED6 C846 3051 02DF 5B4E  0383 04A9 33D1 BA20 327A
39     uid   PyDERASN releases <pyderasn@cypherpunks.ru>
40
41     $ gpg --auto-key-locate dane --locate-keys pyderasn at cypherpunks dot ru
42     $ gpg --auto-key-locate wkd --locate-keys pyderasn at cypherpunks dot ru
43
44 .. literalinclude:: ../PUBKEY.asc