mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-13 17:15:11 +01:00
[test] Move test framework crypto functions to crypto/
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
"""Helper routines relevant for compact block filters (BIP158).
|
||||
"""
|
||||
from .siphash import siphash
|
||||
from .crypto.siphash import siphash
|
||||
|
||||
|
||||
def bip158_basic_element_hash(script_pub_key, N, block_hash):
|
||||
|
||||
@@ -12,7 +12,7 @@ import os
|
||||
import random
|
||||
import unittest
|
||||
|
||||
from test_framework.secp256k1 import FE, G, GE
|
||||
from test_framework.crypto.secp256k1 import FE, G, GE
|
||||
|
||||
# Precomputed constant square root of -3 (mod p).
|
||||
MINUS_3_SQRT = FE(-3).sqrt()
|
||||
@@ -13,7 +13,7 @@ import os
|
||||
import random
|
||||
import unittest
|
||||
|
||||
from test_framework import secp256k1
|
||||
from test_framework.crypto import secp256k1
|
||||
|
||||
# Point with no known discrete log.
|
||||
H_POINT = "50929b74c1a04954b78b4b6035e97a5e078a5a0f28ec96d547bfee9ace803ac0"
|
||||
|
||||
@@ -29,7 +29,7 @@ import struct
|
||||
import time
|
||||
import unittest
|
||||
|
||||
from test_framework.siphash import siphash256
|
||||
from test_framework.crypto.siphash import siphash256
|
||||
from test_framework.util import assert_equal
|
||||
|
||||
MAX_LOCATOR_SZ = 101
|
||||
|
||||
@@ -24,7 +24,7 @@ from .messages import (
|
||||
uint256_from_str,
|
||||
)
|
||||
|
||||
from .ripemd160 import ripemd160
|
||||
from .crypto.ripemd160 import ripemd160
|
||||
|
||||
MAX_SCRIPT_ELEMENT_SIZE = 520
|
||||
MAX_PUBKEYS_PER_MULTI_A = 999
|
||||
|
||||
Reference in New Issue
Block a user