Bitcoin Core 28.99.0
P2P Digital Currency
Functions | Variables
test_vectors_musig2_generate Namespace Reference

Functions

def hexstr_to_intarray (str)
 
def create_init (name)
 
def init_array (key)
 
def init_arrays (key)
 
def init_indices (array)
 
def init_is_xonly (case)
 
def init_optional_expected (case)
 
def init_cases (cases, f)
 
def finish_init ()
 
def comment_to_error (case)
 
def init_array_maybe (array)
 
def filter_msg32 (k)
 
def sign_error (case)
 
def verify_error (case)
 

Variables

int max_pubkeys = 0
 
tuple s
 
 data = json.load(f)
 
 max_key_indices
 
 max_tweak_indices
 
 num_pubkeys = len(data["pubkeys"])
 
 num_tweaks = len(data["tweaks"])
 
 num_valid_cases = len(data["valid_test_cases"])
 
 num_error_cases = len(data["error_test_cases"])
 
 num_tests = len(data["test_cases"])
 
 num_pnonces = len(data["pnonces"])
 
int pnonce_indices_len = 2
 
 num_secnonces = len(data["secnonces"])
 
 num_pubnonces = len(data["pnonces"])
 
 num_aggnonces = len(data["aggnonces"])
 
 num_msgs = len(data["msgs"])
 
 num_sign_error_cases = len(data["sign_error_test_cases"])
 
 num_verify_fail_cases = len(data["verify_fail_test_cases"])
 
 num_verify_error_cases = len(data["verify_error_test_cases"])
 
tuple all_cases
 
 max_nonce_indices
 
 num_psigs = len(data["psigs"])
 
 max_psig_indices = max(len(test_case["psig_indices"]) for test_case in all_cases)
 

Function Documentation

◆ comment_to_error()

def test_vectors_musig2_generate.comment_to_error (   case)

Definition at line 165 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ create_init()

def test_vectors_musig2_generate.create_init (   name)

Definition at line 21 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ filter_msg32()

def test_vectors_musig2_generate.filter_msg32 (   k)

Definition at line 308 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ finish_init()

def test_vectors_musig2_generate.finish_init ( )

Definition at line 68 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ hexstr_to_intarray()

def test_vectors_musig2_generate.hexstr_to_intarray (   str)

Definition at line 17 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ init_array()

def test_vectors_musig2_generate.init_array (   key)

Definition at line 30 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_array_maybe()

def test_vectors_musig2_generate.init_array_maybe (   array)

Definition at line 227 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_arrays()

def test_vectors_musig2_generate.init_arrays (   key)

Definition at line 34 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ init_cases()

def test_vectors_musig2_generate.init_cases (   cases,
  f 
)

Definition at line 60 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ init_indices()

def test_vectors_musig2_generate.init_indices (   array)

Definition at line 43 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ init_is_xonly()

def test_vectors_musig2_generate.init_is_xonly (   case)

Definition at line 50 of file test_vectors_musig2_generate.py.

Here is the caller graph for this function:

◆ init_optional_expected()

def test_vectors_musig2_generate.init_optional_expected (   case)

Definition at line 56 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sign_error()

def test_vectors_musig2_generate.sign_error (   case)

Definition at line 431 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ verify_error()

def test_vectors_musig2_generate.verify_error (   case)

Definition at line 454 of file test_vectors_musig2_generate.py.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ all_cases

test_vectors_musig2_generate.all_cases
Initial value:
1= (
2 data["valid_test_cases"]
3 + data["sign_error_test_cases"]
4 + data["verify_error_test_cases"]
5 + data["verify_fail_test_cases"]
6 )

Definition at line 327 of file test_vectors_musig2_generate.py.

◆ data

test_vectors_musig2_generate.data = json.load(f)

Definition at line 98 of file test_vectors_musig2_generate.py.

◆ max_key_indices

test_vectors_musig2_generate.max_key_indices
Initial value:
1= max(
2 len(test_case["key_indices"]) for test_case in data["valid_test_cases"]
3 )

Definition at line 100 of file test_vectors_musig2_generate.py.

◆ max_nonce_indices

test_vectors_musig2_generate.max_nonce_indices
Initial value:
1= max(
2 len(test_case["nonce_indices"]) if "nonce_indices" in test_case else 0
3 for test_case in all_cases
4 )

Definition at line 334 of file test_vectors_musig2_generate.py.

◆ max_psig_indices

test_vectors_musig2_generate.max_psig_indices = max(len(test_case["psig_indices"]) for test_case in all_cases)

Definition at line 589 of file test_vectors_musig2_generate.py.

◆ max_pubkeys

test_vectors_musig2_generate.max_pubkeys = 0

Definition at line 7 of file test_vectors_musig2_generate.py.

◆ max_tweak_indices

test_vectors_musig2_generate.max_tweak_indices
Initial value:
1= max(
2 len(test_case["tweak_indices"]) for test_case in data["error_test_cases"]
3 )

Definition at line 103 of file test_vectors_musig2_generate.py.

◆ num_aggnonces

test_vectors_musig2_generate.num_aggnonces = len(data["aggnonces"])

Definition at line 320 of file test_vectors_musig2_generate.py.

◆ num_error_cases

test_vectors_musig2_generate.num_error_cases = len(data["error_test_cases"])

Definition at line 110 of file test_vectors_musig2_generate.py.

◆ num_msgs

test_vectors_musig2_generate.num_msgs = len(data["msgs"])

Definition at line 321 of file test_vectors_musig2_generate.py.

◆ num_pnonces

test_vectors_musig2_generate.num_pnonces = len(data["pnonces"])

Definition at line 254 of file test_vectors_musig2_generate.py.

◆ num_psigs

test_vectors_musig2_generate.num_psigs = len(data["psigs"])

Definition at line 582 of file test_vectors_musig2_generate.py.

◆ num_pubkeys

test_vectors_musig2_generate.num_pubkeys = len(data["pubkeys"])

Definition at line 106 of file test_vectors_musig2_generate.py.

◆ num_pubnonces

test_vectors_musig2_generate.num_pubnonces = len(data["pnonces"])

Definition at line 319 of file test_vectors_musig2_generate.py.

◆ num_secnonces

test_vectors_musig2_generate.num_secnonces = len(data["secnonces"])

Definition at line 318 of file test_vectors_musig2_generate.py.

◆ num_sign_error_cases

test_vectors_musig2_generate.num_sign_error_cases = len(data["sign_error_test_cases"])

Definition at line 323 of file test_vectors_musig2_generate.py.

◆ num_tests

test_vectors_musig2_generate.num_tests = len(data["test_cases"])

Definition at line 197 of file test_vectors_musig2_generate.py.

◆ num_tweaks

test_vectors_musig2_generate.num_tweaks = len(data["tweaks"])

Definition at line 108 of file test_vectors_musig2_generate.py.

◆ num_valid_cases

test_vectors_musig2_generate.num_valid_cases = len(data["valid_test_cases"])

Definition at line 109 of file test_vectors_musig2_generate.py.

◆ num_verify_error_cases

test_vectors_musig2_generate.num_verify_error_cases = len(data["verify_error_test_cases"])

Definition at line 325 of file test_vectors_musig2_generate.py.

◆ num_verify_fail_cases

test_vectors_musig2_generate.num_verify_fail_cases = len(data["verify_fail_test_cases"])

Definition at line 324 of file test_vectors_musig2_generate.py.

◆ pnonce_indices_len

int test_vectors_musig2_generate.pnonce_indices_len = 2

Definition at line 258 of file test_vectors_musig2_generate.py.

◆ s

tuple test_vectors_musig2_generate.s
Initial value:
1= (
2
3 % sys.argv[0]
4)

Definition at line 72 of file test_vectors_musig2_generate.py.