SLH-DSA 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- slh_dsa-0.1.0.dist-info/METADATA +44 -0
- slh_dsa-0.1.0.dist-info/RECORD +18 -0
- slh_dsa-0.1.0.dist-info/WHEEL +4 -0
- slh_dsa-0.1.0.dist-info/licenses/COPYING +674 -0
- slh_dsa-0.1.0.dist-info/licenses/COPYING.LESSER +165 -0
- slhdsa/__init__.py +10 -0
- slhdsa/exception.py +8 -0
- slhdsa/lowlevel/__init__.py +1 -0
- slhdsa/lowlevel/_utils.py +24 -0
- slhdsa/lowlevel/addresses.py +89 -0
- slhdsa/lowlevel/fors.py +70 -0
- slhdsa/lowlevel/hypertree.py +38 -0
- slhdsa/lowlevel/parameters.py +135 -0
- slhdsa/lowlevel/slhdsa.py +74 -0
- slhdsa/lowlevel/wots.py +82 -0
- slhdsa/lowlevel/xmss.py +62 -0
- slhdsa/parameters.py +3 -0
- slhdsa/slhdsa.py +67 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: SLH-DSA
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: The pure python impl of the slh-das algorithm(based on fips205).
|
|
5
|
+
Author-Email: Colinxu2020 <colinxu2020@gmail.com>
|
|
6
|
+
License: AGPL-3.0-or-later
|
|
7
|
+
Requires-Python: >=3.9
|
|
8
|
+
Requires-Dist: pytest-cov>=5.0.0
|
|
9
|
+
Description-Content-Type: text/markdown
|
|
10
|
+
|
|
11
|
+
# SLH-DSA
|
|
12
|
+
The SLH-DSA project implements the stateless-hash digital signing algorithm(standardizing fips 205, adopted on Sphincs-Plus algorithm) in pure Python.
|
|
13
|
+
|
|
14
|
+
This project offers those future:
|
|
15
|
+
1. :beers: Zero dependencies;
|
|
16
|
+
2. :label: 100% type hint for all the codes;
|
|
17
|
+
3. :white_check_mark: Extreme good 98% test coverage;
|
|
18
|
+
4. :bookmark: This project doesn't use any c-extension so it can be run in any version of Python or any kind of system.
|
|
19
|
+
5. :tada: More futures coming soon!
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
The functionality is extremely simple to use, as demonstrated by the following example:
|
|
23
|
+
```python
|
|
24
|
+
from slhdsa import KeyPair, shake_256f, PublicKey
|
|
25
|
+
|
|
26
|
+
kp = KeyPair.gen(shake_256f) # generate the keypair
|
|
27
|
+
sig = kp.sign(b"Hello World!") # sign the message
|
|
28
|
+
kp.verify(b"Hello World!", sig) # -> True
|
|
29
|
+
kp.verify(b"Hello World!", b"I'm the hacker!") # -> False
|
|
30
|
+
kp.verify(b"hello world!", sig) # -> False
|
|
31
|
+
sig = kp.sign(b"Hello World!", randomize = True) # sign the message randomized
|
|
32
|
+
kp.verify(b"Hello World!", sig) # -> True
|
|
33
|
+
|
|
34
|
+
digest = kp.pub.digest() # generate the digest of the public key so that other device could verify the sign
|
|
35
|
+
pub = PublicKey.from_digest(digest) # generate public key
|
|
36
|
+
pub.verify(b"Hello World!", sig) # -> True
|
|
37
|
+
pub.verify(b"Hello World", sig) # -> False
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Copyright
|
|
41
|
+
|
|
42
|
+
Copyright(c) Colinxu2020 2024 All Rights Reserved.
|
|
43
|
+
|
|
44
|
+
This software is licensed under GNU Lesser General Public License Version 3 or later(on your option).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
slh_dsa-0.1.0.dist-info/METADATA,sha256=TA6z_8TJFwSY4Ogx0UNXYjNcEn3hoc-SBdUNLw6TjZ0,1733
|
|
2
|
+
slh_dsa-0.1.0.dist-info/WHEEL,sha256=mbxFTmdEUhG7evcdMkR3aBt9SWcoFBJ4CDwnfguNegA,90
|
|
3
|
+
slh_dsa-0.1.0.dist-info/licenses/COPYING,sha256=gcuuhKKc5-dwvyvHsXjlC9oM6N5gZ6umYbC8ewW1Yvg,35821
|
|
4
|
+
slh_dsa-0.1.0.dist-info/licenses/COPYING.LESSER,sha256=-DHn7tV3SBaHqbwLSAJOXkC29lX83gc-3pZLUL5dVdk,7815
|
|
5
|
+
slhdsa/__init__.py,sha256=G5yrLmJMIly2JC63W9BmVCnVu50ML1nxyeF3Tgbayeo,475
|
|
6
|
+
slhdsa/exception.py,sha256=4spZ-FlhJoDAaU68YjjeaaZubSt6hKSRkgGhuyOr1Zo,161
|
|
7
|
+
slhdsa/lowlevel/__init__.py,sha256=XT3oVrrYiLQJwn8UxrOvndd9HuqwKqSPMP8ysE0YKyA,20
|
|
8
|
+
slhdsa/lowlevel/_utils.py,sha256=7awmUr-m1yZAm_4cTVioT7KRtWj_myk1liM2XeMa0Gc,588
|
|
9
|
+
slhdsa/lowlevel/addresses.py,sha256=LaaxIGRuKXd1Gln0UEJWTEGT8nbWZRIHmX7DFJPjYtw,2279
|
|
10
|
+
slhdsa/lowlevel/fors.py,sha256=NRabsNA3Ovci4qR8FpcNdb4KtLEUmeMTIp0c3C8_yxc,3456
|
|
11
|
+
slhdsa/lowlevel/hypertree.py,sha256=4Lr4BHe1pdGoXEp3H8Q_M3rcfdO6-oDe53RTznLwtq0,1683
|
|
12
|
+
slhdsa/lowlevel/parameters.py,sha256=kAcF8M3HEKDxLDVvl3nqTQ6Mf6Yks56Qhs0422x9z4Y,6185
|
|
13
|
+
slhdsa/lowlevel/slhdsa.py,sha256=9zPasBtLNntiuU_urGG0RRJaUPgdZepUotHMFfSDXDo,3542
|
|
14
|
+
slhdsa/lowlevel/wots.py,sha256=GvAUAK4on9fGfVJjOEfSspvQdzG2wtWMEyVQt_EZhPY,3420
|
|
15
|
+
slhdsa/lowlevel/xmss.py,sha256=8hq6hU6ER-0HPot1RQCguozNHoQrRZVe9Wz9LEZoOKA,2828
|
|
16
|
+
slhdsa/parameters.py,sha256=DTqEJ9tNLoEGMm7ws8lSRb5ooJsOc-YD3qdm83_HN2M,268
|
|
17
|
+
slhdsa/slhdsa.py,sha256=c87EtFJNeZd6XMCiL0VuSABCovSnaizkeEZssoQwG0Y,2018
|
|
18
|
+
slh_dsa-0.1.0.dist-info/RECORD,,
|