{"name": "process_thread_servreg_hack_process", "code": "__int64 __fastcall process_thread_servreg_hack_process ( _WORD * @@a1@@ , char @@a2@@ , void * @@a3@@ ) { unsigned __int16 v3 ; unsigned __int16 v4 ; __int64 result ; char @@v7@@ ; @@v7@@ = Number ; if ( ! * @@a1@@ ) { outconn_4485 = ( __int64 ) udp_broadcast_new ( Number , Number L ) ; * ( _WORD * ) ( outconn_4485 + Number ) = Number ; inconn_4486 = ( __int64 ) udp_new ( Number L , Number , Number L ) ; * ( _WORD * ) ( inconn_4486 + Number ) = Number ; etimer_set ( ( __int64 ) & periodic_4484 , Number L ) ; v3 = random_rand ( ) ; etimer_set ( ( __int64 ) & sendtimer , v3 % Number ) ; goto LABEL_5 ; } if ( * @@a1@@ == Number ) { while ( @@v7@@ ) { if ( @@a2@@ == Number && @@a3@@ == & periodic_4484 ) { etimer_reset ( ( __int64 ) & periodic_4484 ) ; v4 = random_rand ( ) ; etimer_set ( ( __int64 ) & sendtimer , v4 % Number ) ; } else if ( @@a2@@ == Number && @@a3@@ == & sendtimer ) { send_udp_packet ( outconn_4485 ) ; } else if ( @@a2@@ == tcpip_event ) { parse_incoming_packet ( ( unsigned __int8 * ) uip_appdata ) ; } LABEL_5 : @@v7@@ = Number ; * @@a1@@ = Number ; } result = Number L ; } else { * @@a1@@ = Number ; result = Number L ; } return result ; }", "source": [{"n": "a3", "t": {"T": 3, "t": "void"}, "location": "r16"}, {"n": "a1", "t": {"T": 3, "t": "_WORD"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "char", "s": 1}, "location": "r64"}, {"n": "v7", "t": {"T": 1, "n": "char", "s": 1}, "location": "s1"}]}
{"name": "etimer_set", "code": "__int64 __fastcall etimer_set ( __int64 @@a1@@ , __int64 @@a2@@ ) { timer_set ( @@a1@@ , @@a2@@ ) ; return add_timer ( @@a1@@ ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}]} {"name": "etimer_reset", "code": "__int64 __fastcall etimer_reset ( __int64 @@a1@@ ) { timer_reset ( @@a1@@ ) ; return add_timer ( @@a1@@ ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}]} {"name": "udp_new", "code": "char * __fastcall udp_new ( _QWORD * @@a1@@ , __int16 @@a2@@ , __int64 @@a3@@ ) { char * @@v5@@ ; @@v5@@ = uip_udp_new ( @@a1@@ , @@a2@@ ) ; if ( ! @@v5@@ ) return Number L ; * ( ( _QWORD * ) @@v5@@ + Number ) = process_current ; * ( ( _QWORD * ) @@v5@@ + Number ) = @@a3@@ ; return @@v5@@ ; }", "source": [{"n": "a3", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r16"}, {"n": "a1", "t": {"T": 3, "t": "_QWORD"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "r64"}, {"n": "v5", "t": {"T": 3, "t": "char"}, "location": "s8"}]} {"name": "udp_broadcast_new", "code": "char * __fastcall udp_broadcast_new ( __int16 @@a1@@ , __int64 @@a2@@ ) { __int64 @@v3@@ ; __int16 @@v4@@ ; __int16 @@v5@@ ; __int16 @@v6@@ ; __int16 @@v7@@ ; char * @@v8@@ ; @@v3@@ = Number L ; @@v4@@ = Number ; @@v5@@ = Number ; @@v6@@ = Number ; @@v7@@ = Number ; @@v8@@ = udp_new ( & @@v3@@ , @@a1@@ , @@a2@@ ) ; if ( @@v8@@ ) * ( ( _WORD * ) @@v8@@ + Number ) = @@a1@@ ; return @@v8@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}, {"n": "v7", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s18"}, {"n": "v6", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s20"}, {"n": "v5", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s22"}, {"n": "v4", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s24"}, {"n": "v3", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s32"}, {"n": "v8", "t": {"T": 3, "t": "char"}, "location": "s8"}]} {"name": "send_udp_packet", "code": "__int64 __fastcall send_udp_packet ( __int64 @@a1@@ ) { _QWORD * v1 ; char * v2 ; __int64 v3 ; int v4 ; int v5 ; _QWORD * v6 ; char * v7 ; __int64 v8 ; int v9 ; int v10 ; __int64 result ; char @@v12@@ [ Number ] ; __int64 @@i@@ ; int @@v14@@ ; unsigned int @@v15@@ ; @@v12@@ [ Number ] = Number ; @@v15@@ = Number ; @@v14@@ = Number ; for ( @@i@@ = list_head ( own_services ) ; @@v14@@ <= Number && @@i@@ ; @@i@@ = list_item_next ( @@i@@ ) ) { v1 = ( _QWORD * ) servreg_hack_item_address ( @@i@@ ) ; v2 = & @@v12@@ [ @@v14@@ ] ; v3 = v1 [ Number ] ; * ( _QWORD * ) v2 = * v1 ; * ( ( _QWORD * ) v2 + Number ) = v3 ; v4 = @@v14@@ + Number ; @@v12@@ [ v4 ] = servreg_hack_item_id ( @@i@@ ) ; v5 = @@v14@@ + Number ; @@v12@@ [ @@v14@@ + Number ] = Number ; @@v12@@ [ @@v14@@ + Number ] = @@v12@@ [ v5 ] ; @@v12@@ [ @@v14@@ + Number ] = * ( _BYTE * ) ( @@i@@ + Number ) ; @@v14@@ += Number ; ++ @@v15@@ ; } for ( @@i@@ = servreg_hack_list_head ( ) ; @@v14@@ <= Number && @@i@@ ; @@i@@ = list_item_next ( @@i@@ ) ) { v6 = ( _QWORD * ) servreg_hack_item_address ( @@i@@ ) ; v7 = & @@v12@@ [ @@v14@@ ] ; v8 = v6 [ Number ] ; * ( _QWORD * ) v7 = * v6 ; * ( ( _QWORD * ) v7 + Number ) = v8 ; v9 = @@v14@@ + Number ; @@v12@@ [ v9 ] = servreg_hack_item_id ( @@i@@ ) ; v10 = @@v14@@ + Number ; @@v12@@ [ @@v14@@ + Number ] = Number ; @@v12@@ [ @@v14@@ + Number ] = @@v12@@ [ v10 ] ; @@v12@@ [ @@v14@@ + Number ] = * ( _BYTE * ) ( @@i@@ + Number ) ; @@v14@@ += Number ; ++ @@v15@@ ; } result = @@v15@@ ; @@v12@@ [ Number ] = @@v15@@ ; if ( ( int ) @@v15@@ > Number ) result = uip_udp_packet_send ( @@a1@@ , @@v12@@ , ( unsigned int ) @@v14@@ ) ; return result ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "v12", "t": {"T": 2, "n": 96, "s": 1, "t": "char"}, "location": "s128"}, {"n": "v15", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s20"}, {"n": "v14", "t": {"T": 1, "n": "int", "s": 4}, "location": "s24"}, {"n": "i", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s32"}]} {"name": "parse_incoming_packet", "code": "__int64 __fastcall parse_incoming_packet ( unsigned __int8 * @@a1@@ ) { __int64 @@result@@ ; int @@v2@@ ; unsigned int @@i@@ ; @@v2@@ = * @@a1@@ ; for ( @@i@@ = Number ; ; ++ @@i@@ ) { @@result@@ = @@i@@ ; if ( ( int ) @@i@@ >= @@v2@@ ) break ; handle_incoming_reg ( @@a1@@ + Number , @@a1@@ [ Number ] , @@a1@@ [ Number ] ) ; } return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "unsigned __int8"}, "location": "r56"}, {"n": "result", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r8"}, {"n": "i", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4"}, {"n": "v2", "t": {"T": 1, "n": "int", "s": 4}, "location": "s8"}]} {"name": "parse", "code": "__int64 parse ( ) { unsigned __int16 v0 ; unsigned int @@v1@@ ; __int64 v2 ; char @@v4@@ [ Number ] ; char @@v5@@ ; unsigned __int8 @@v6@@ ; __int16 @@v7@@ ; _BYTE @@v8@@ [ Number ] ; __int16 @@v9@@ ; unsigned __int8 @@v10@@ ; int @@v11@@ ; v0 = packetbuf_datalen ( ) ; @@v11@@ = v0 ; @@v1@@ = ( unsigned __int8 ) v0 ; v2 = packetbuf_dataptr ( ) ; if ( ! ( unsigned __int8 ) frame802154_parse ( v2 , @@v1@@ , @@v4@@ ) || ! ( unsigned int ) packetbuf_hdrreduce ( @@v11@@ - ( unsigned int ) @@v10@@ ) ) return Number ; if ( @@v5@@ ) { if ( @@v7@@ != Number && @@v7@@ != Number ) return Number ; if ( ! ( unsigned int ) is_broadcast_addr ( @@v5@@ , ( __int64 ) @@v8@@ ) ) packetbuf_set_addr ( Number L , @@v8@@ ) ; } packetbuf_set_addr ( Number L , & @@v9@@ ) ; packetbuf_set_attr ( Number L , ( unsigned __int8 ) @@v4@@ [ Number ] ) ; packetbuf_set_attr ( Number L , @@v6@@ ) ; return @@v11@@ - ( unsigned int ) @@v10@@ ; }", "source": [{"n": "v1", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r32"}, {"n": "v11", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v10", "t": {"T": 1, "n": "unsigned __int8", "s": 1}, "location": "s32"}, {"n": "v9", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s74"}, {"n": "v8", "t": {"T": 2, "n": 10, "s": 1, "t": "_BYTE"}, "location": "s84"}, {"n": "v7", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s86"}, {"n": "v6", "t": {"T": 1, "n": "unsigned __int8", "s": 1}, "location": "s88"}, {"n": "v5", "t": {"T": 1, "n": "char", "s": 1}, "location": "s91"}, {"n": "v4", "t": {"T": 2, "n": 5, "s": 1, "t": "char"}, "location": "s96"}]} {"name": "timer_set", "code": "__time_t __fastcall timer_set ( __time_t * @@a1@@ , __time_t @@a2@@ ) { __time_t @@result@@ ; @@a1@@ [ Number ] = @@a2@@ ; @@result@@ = clock_time ( ) ; * @@a1@@ = @@result@@ ; return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "__time_t"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__time_t", "s": 8}, "location": "r64"}, {"n": "result", "t": {"T": 1, "n": "__time_t", "s": 8}, "location": "r8"}]} {"name": "timer_reset", "code": "_QWORD * __fastcall timer_reset ( _QWORD * @@a1@@ ) { _QWORD * @@result@@ ; @@result@@ = @@a1@@ ; * @@a1@@ += @@a1@@ [ Number ] ; return @@result@@ ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "_QWORD"}, "location": "r56"}, {"n": "result", "t": {"T": 3, "t": "_QWORD"}, "location": "r8"}]} {"name": "send", "code": "__int64 __fastcall send ( __int64 @@a1@@ , unsigned __int16 @@a2@@ ) { prepare ( @@a1@@ , @@a2@@ ) ; return transmit ( @@a2@@ ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "unsigned __int16", "s": 2}, "location": "r64"}]}