# import output_c_sse as O

args = U.parse_args()

c_template = 'raw'
algo_file = 'sha256'

c_code = U.load_code_template(c_template)

size = 4
endianity = 'be'

args['args'] = {'size': size}

O.apply_size(size)
O.apply_endianity(endianity)

bs_size = 64
O.apply_bs_size(bs_size)

# Format setup

tests = '''
{"d63dc919e201d7bc4c825630d2cf25fdc93d4b2f0d46706d29038d01", "password"},
{"$SHA224$d63dc919e201d7bc4c825630d2cf25fdc93d4b2f0d46706d29038d01", "password"},
{"$SHA224$7e6a4309ddf6e8866679f61ace4f621b0e3455ebac2e831a60f13cd1", "12345678"},
{"$SHA224$d14a028c2a3a2bc9476102bb288234c415a2b01f828ea62ac5b3e42f", ""},
'''

vs = {
    'fmt_struct_name': 'raw1_sha224',
Exemplo n.º 2
0
# import output_c_sse as O

args = U.parse_args()

c_template = 'raw'
algo_file = 'sha1'

c_code = U.load_code_template(c_template)

size = 4
endianity = 'be'

args['args'] = { 'size': size }

O.apply_size(size)
O.apply_endianity(endianity)

bs_size = 64
O.apply_bs_size(bs_size)

# Format setup

tests = '''
{"c3e337f070b64a50e9d31ac3f9eda35120e29d6c", "digipalmw221u"},
{ "da39a3ee5e6b4b0d3255bfef95601890afd80709", ""                },
{ "AC80BAA235B7FB7BDFC593A976D40B24B851F924", "CAPSLOCK"        },
{ "86f7e437faa5a7fce15d1ddcb9eaeaea377667b8", "a"               },
{ "da23614e02469a0d7c7bd1bdab5c9c474b1904dc", "ab"              },
{ "a9993e364706816aba3e25717850c26c9cd0d89d", "abc"             },
{ "81fe8bfe87576c3ecb22426f8e57847382917acf", "abcd"            },
{ "03de6c570bfe24bfc328ccd7ca46b76eadaf4334", "abcde"           },