{"name": "BF_encrypt", "code": "__int64 __fastcall BF_encrypt ( _DWORD * @@a1@@ , unsigned int @@a2@@ , unsigned int @@a3@@ , unsigned int * @@a4@@ , unsigned __int64 @@a5@@ ) { unsigned int * @@v5@@ ; unsigned int @@v9@@ ; unsigned int @@v10@@ ; int @@i@@ ; do { @@v9@@ = * @@a1@@ ^ @@a2@@ ; for ( @@i@@ = Number ; @@i@@ <= Number ; @@i@@ += Number ) { @@a3@@ ^= ( @@a1@@ [ ( unsigned __int8 ) @@v9@@ + Number ] + ( @@a1@@ [ BYTE1 ( @@v9@@ ) + Number ] ^ ( @@a1@@ [ HIBYTE ( @@v9@@ ) + Number ] + @@a1@@ [ BYTE2 ( @@v9@@ ) + Number ] ) ) ) ^ @@a1@@ [ @@i@@ + Number ] ; @@v9@@ ^= ( @@a1@@ [ ( unsigned __int8 ) @@a3@@ + Number ] + ( @@a1@@ [ BYTE1 ( @@a3@@ ) + Number ] ^ ( @@a1@@ [ HIBYTE ( @@a3@@ ) + Number ] + @@a1@@ [ BYTE2 ( @@a3@@ ) + Number ] ) ) ) ^ @@a1@@ [ @@i@@ + Number ] ; } @@v10@@ = @@a3@@ ; @@a3@@ = @@v9@@ ; @@a2@@ = @@v10@@ ^ @@a1@@ [ Number ] ; * @@a4@@ = @@a2@@ ; @@v5@@ = @@a4@@ + Number ; @@a4@@ += Number ; * @@v5@@ = @@a3@@ ; } while ( ( unsigned __int64 ) @@a4@@ < @@a5@@ ) ; return @@a2@@ ; }", "source": [{"n": "a3", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r16"}, {"n": "a4", "t": {"T": 3, "t": "unsigned int"}, "location": "r24"}, {"n": "a1", "t": {"T": 3, "t": "_DWORD"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r64"}, {"n": "a5", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "r72"}, {"n": "v5", "t": {"T": 3, "t": "unsigned int"}, "location": "r8"}, {"n": "i", "t": {"T": 1, "n": "int", "s": 4}, "location": "s12"}, {"n": "v10", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s16"}, {"n": "v9", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s44"}]}
{"name": "BF_crypt", "code": "_BYTE * __fastcall BF_crypt ( _BYTE * @@a1@@ , char * @@a2@@ , _BYTE * @@a3@@ , unsigned int @@a4@@ ) { unsigned int @@v6@@ ; unsigned int @@v7@@ ; unsigned int @@v8@@ [ Number ] ; int @@v9@@ ; int @@v10@@ ; _BYTE @@v11@@ [ Number ] ; _BYTE @@v12@@ [ Number ] ; unsigned int @@v13@@ ; unsigned int @@v14@@ ; unsigned int @@v15@@ ; unsigned int @@v16@@ ; unsigned int @@v17@@ ; unsigned int @@v18@@ ; unsigned int @@v19@@ ; unsigned int @@v20@@ ; unsigned int @@v21@@ ; int @@v22@@ ; unsigned int * @@i@@ ; unsigned int @@v24@@ ; int @@v25@@ ; int @@j@@ ; unsigned int @@v27@@ ; if ( * @@a2@@ != Number || @@a2@@ [ Number ] != Number || ( unsigned int ) ( @@a2@@ [ Number ] - Number ) > Number || ! flags_by_subtype_1637 [ @@a2@@ [ Number ] - Number ] || @@a2@@ [ Number ] != Number || ( unsigned int ) ( @@a2@@ [ Number ] - Number ) > Number || ( unsigned int ) ( @@a2@@ [ Number ] - Number ) > Number || @@a2@@ [ Number ] != Number ) { return Number L ; } @@v27@@ = Number << ( Number * ( @@a2@@ [ Number ] - Number ) + @@a2@@ [ Number ] - Number ) ; if ( @@v27@@ < @@a4@@ || ( unsigned int ) BF_decode ( & @@v13@@ , ( unsigned __int8 * ) @@a2@@ + Number , Number ) ) return Number L ; BF_swap ( & @@v13@@ , Number ) ; BF_set_key ( @@a1@@ , ( __int64 ) @@v12@@ , @@v8@@ , flags_by_subtype_1637 [ @@a2@@ [ Number ] - Number ] ) ; memcpy ( @@v11@@ , & unk_88 , sizeof ( @@v11@@ ) ) ; @@v25@@ = Number ; @@v24@@ = Number ; for ( @@i@@ = @@v8@@ ; ; @@i@@ += Number ) { @@v25@@ = BF_encrypt ( @@v8@@ , @@v25@@ ^ @@v13@@ , @@v24@@ ^ @@v14@@ , @@i@@ , ( unsigned __int64 ) @@i@@ ) ; @@v24@@ = @@i@@ [ Number ] ; @@i@@ += Number ; if ( @@i@@ >= ( unsigned int * ) @@v12@@ ) break ; @@v25@@ = BF_encrypt ( @@v8@@ , @@v25@@ ^ @@v15@@ , @@v24@@ ^ @@v16@@ , @@i@@ , ( unsigned __int64 ) @@i@@ ) ; @@v24@@ = @@i@@ [ Number ] ; } do { for ( @@j@@ = Number ; @@j@@ <= Number ; @@j@@ += Number ) { @@v8@@ [ @@j@@ ] ^= @@v8@@ [ @@j@@ + Number ] ; @@v8@@ [ @@j@@ + Number ] ^= @@v8@@ [ @@j@@ + Number ] ; } @@v22@@ = Number ; while ( Number ) { BF_encrypt ( @@v8@@ , Number , Number , @@v8@@ , ( unsigned __int64 ) @@v12@@ ) ; if ( @@v22@@ ) break ; @@v22@@ = Number ; @@v20@@ = @@v13@@ ; @@v19@@ = @@v14@@ ; @@v18@@ = @@v15@@ ; @@v17@@ = @@v16@@ ; for ( @@j@@ = Number ; @@j@@ <= Number ; @@j@@ += Number ) { @@v8@@ [ @@j@@ ] ^= @@v20@@ ; @@v8@@ [ @@j@@ + Number ] ^= @@v19@@ ; @@v8@@ [ @@j@@ + Number ] ^= @@v18@@ ; @@v8@@ [ @@j@@ + Number ] ^= @@v17@@ ; } @@v9@@ ^= @@v20@@ ; @@v10@@ ^= @@v19@@ ; } -- @@v27@@ ; } while ( @@v27@@ ) ; for ( @@j@@ = Number ; @@j@@ <= Number ; @@j@@ += Number ) { @@v21@@ = BF_magic_w [ @@j@@ ] ; @@v7@@ = BF_magic_w [ @@j@@ + Number ] ; @@v27@@ = Number ; do { @@v21@@ = BF_encrypt ( @@v8@@ , @@v21@@ , @@v7@@ , & @@v6@@ , ( unsigned __int64 ) & @@v6@@ ) ; -- @@v27@@ ; } while ( @@v27@@ ) ; @@v8@@ [ @@j@@ + Number ] = @@v21@@ ; @@v8@@ [ @@j@@ + Number ] = @@v7@@ ; } memcpy ( @@a3@@ , @@a2@@ , Number ) ; @@a3@@ [ Number ] = BF_itoa64 [ BF_atoi64 [ @@a2@@ [ Number ] - Number ] & Number ] ; BF_swap ( & @@v13@@ , Number ) ; BF_encode ( @@a3@@ + Number , ( unsigned __int8 * ) & @@v13@@ , Number ) ; @@a3@@ [ Number ] = Number ; return @@a3@@ ; }", "source": [{"n": "a3", "t": {"T": 3, "t": "_BYTE"}, "location": "r16"}, {"n": "a4", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r24"}, {"n": "a1", "t": {"T": 3, "t": "_BYTE"}, "location": "r56"}, {"n": "a2", "t": {"T": 3, "t": "char"}, "location": "r64"}, {"n": "v27", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s12"}, {"n": "j", "t": {"T": 1, "n": "int", "s": 4}, "location": "s16"}, {"n": "v12", "t": {"T": 2, "n": 72, "s": 1, "t": "_BYTE"}, "location": "s160"}, {"n": "v25", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v24", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s24"}, {"n": "i", "t": {"T": 3, "t": "unsigned int"}, "location": "s32"}, {"n": "v22", "t": {"T": 1, "n": "int", "s": 4}, "location": "s36"}, {"n": "v21", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s40"}, {"n": "v11", "t": {"T": 2, "n": 4096, "s": 1, "t": "_BYTE"}, "location": "s4256"}, {"n": "v10", "t": {"T": 1, "n": "int", "s": 4}, "location": "s4260"}, {"n": "v9", "t": {"T": 1, "n": "int", "s": 4}, "location": "s4264"}, {"n": "v8", "t": {"T": 2, "n": 16, "s": 4, "t": "unsigned int"}, "location": "s4328"}, {"n": "v7", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4332"}, {"n": "v6", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4336"}, {"n": "v20", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s44"}, {"n": "v19", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s48"}, {"n": "v18", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s52"}, {"n": "v17", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s56"}, {"n": "v16", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s76"}, {"n": "v15", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s80"}, {"n": "v14", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s84"}, {"n": "v13", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s88"}]}