Add example and fix links

This commit is contained in:
Luke Murphy 2019-10-06 16:19:11 +02:00
parent 980a1e8218
commit 2c50616ab8
No known key found for this signature in database
GPG Key ID: 5E2EF5A63E3718CC
1 changed files with 22 additions and 4 deletions

View File

@ -31,17 +31,35 @@ Cryptography primitives for Hypercore
Cryptography primitives for `Hypercore`_ (WIP).
.. _Hypercore: https://hypercore.readthedocs.io/en/latest/
.. _Hypercore: https://hypercore.readthedocs.io
.. _example:
Example
*******
.. code-block:: python
from hypercore_crypto import key_pair, sign, verify
public_key, secret_key = key_pair()
signature = sign(b'hello world', secret_key)
verify(message, signature, public_key)
.. _documentation:
Documentation
*************
* https://hypercore-crypto.readthedocs.io/
* `hypercore-crypto.readthedocs.io`_
.. _hypercore-crypto.readthedocs.io: https://hypercore-crypto.readthedocs.io/
Mirroring
*********
* https://hack.decentral1.se/datpy/hypercore-crypto (primary)
* https://github.com/datpy/hypercore-crypto
* `hack.decentral1.se/datpy/hypercore-crypto`_
* `github.com/datpy/hypercore-crypto`_
.. _hack.decentral1.se/datpy/hypercore-crypto: https://hack.decentral1.se/datpy/hypercore-crypto
.. _github.com/datpy/hypercore-crypto: https://github.com/datpy/hypercore-crypto