Skip to content

Commit 515591b

Browse files
committed
Work toward detecting signal/compressability of entropy
1 parent d79e962 commit 515591b

File tree

9 files changed

+535
-56
lines changed

9 files changed

+535
-56
lines changed

GNUmakefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ else
4141
endif
4242

4343
# To see all pytest output, uncomment --capture=no
44-
PYTESTOPTS = -vv --doctest-modules --capture=no # --log-cli-level=INFO
44+
PYTESTOPTS = -vv --doctest-modules --capture=no --log-cli-level=INFO
4545

4646
PY3TEST = $(PY3) -m pytest $(PYTESTOPTS)
4747

slip39/defaults.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -158,15 +158,3 @@
158158
f"0x{__m}{__m}{__m}", # Medium grey,
159159
f"0x{__d}{__d}{__d}", # Dark grey,
160160
]
161-
162-
# Include any known seed bit sequences here; any seed containing any of these
163-
# segments will be printed with a "watermark" indicating that the seed is
164-
# invalid, indicating that it should probably not be used! These are clearly
165-
# non-random sequences of bits, or sequences known to be part of publicly
166-
# disclosed test sequences. The probability of these sequences showing up in a
167-
# legitimate, random seed is about 1 in 2^40 =~= 1 Trillion.
168-
KNOWN_SEQUENCES = [
169-
40 * "1",
170-
40 * "0",
171-
20 * "01",
172-
]

slip39/known/__init__.py

Whitespace-only changes.

slip39/known/__main__.py

Lines changed: 0 additions & 22 deletions
This file was deleted.

slip39/known/generator.py

Lines changed: 0 additions & 4 deletions
This file was deleted.

slip39/known/main.py

Lines changed: 0 additions & 14 deletions
This file was deleted.

slip39/recovery/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@
2424
from mnemonic import Mnemonic
2525

2626
from ..util import ordinal
27+
28+
from .entropy import shannon_entropy, signal_entropy # noqa F401
29+
2730
log = logging.getLogger( __package__ )
2831

2932

0 commit comments

Comments
 (0)