{"name": "hostapd_wps_enrollee_seen_cb", "code": "__int64 __fastcall hostapd_wps_enrollee_seen_cb ( __int64 @@a1@@ , unsigned __int8 * @@a2@@ , __int64 @@a3@@ , __int64 @@a4@@ , unsigned __int16 @@a5@@ , unsigned __int16 @@a6@@ , unsigned __int8 @@a7@@ , const char * @@a8@@ ) { __int64 result ; const char * v9 ; char @@v13@@ [ Number ] ; char @@v14@@ [ Number ] ; __int64 @@v15@@ ; @@v15@@ = @@a1@@ ; result = uuid_bin2str ( @@a3@@ , @@v14@@ , Number L ) ; if ( ! ( _DWORD ) result ) { if ( ! @@a8@@ ) @@a8@@ = ( const char * ) & unk_4629 ; v9 = ( const char * ) wps_dev_type_bin2str ( @@a4@@ , @@v13@@ , Number L ) ; result = wpa_msg_ctrl ( * ( _QWORD * ) ( @@v15@@ + Number ) , Number L , String , * @@a2@@ , @@a2@@ [ Number ] , @@a2@@ [ Number ] , @@a2@@ [ Number ] , @@a2@@ [ Number ] , @@a2@@ [ Number ] , @@v14@@ , v9 , @@a5@@ , @@a6@@ , @@a7@@ , @@a8@@ ) ; } return result ; }", "source": [{"n": "a3", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r16"}, {"n": "a4", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r24"}, {"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 3, "t": "unsigned __int8"}, "location": "r64"}, {"n": "a5", "t": {"T": 1, "n": "unsigned __int16", "s": 2}, "location": "r72"}, {"n": "a6", "t": {"T": 1, "n": "unsigned __int16", "s": 2}, "location": "r80"}, {"n": "a7", "t": {"T": 1, "n": "unsigned __int8", "s": 1}, "location": "s-16"}, {"n": "a8", "t": {"T": 3, "t": "const char"}, "location": "s-24"}, {"n": "v13", "t": {"T": 2, "n": 32, "s": 1, "t": "char"}, "location": "s112"}, {"n": "v15", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s40"}, {"n": "v14", "t": {"T": 2, "n": 40, "s": 1, "t": "char"}, "location": "s80"}]}
{"name": "hostapd_init_wps", "code": "__int64 __fastcall hostapd_init_wps ( _QWORD * * @@a1@@ , __int64 @@a2@@ ) { __int64 v3 ; __int64 v4 ; __int64 v5 ; __int64 v6 ; char * v7 ; char * v8 ; char * v9 ; char * v10 ; char * v11 ; __int16 v12 ; int v13 ; char v14 ; char * v15 ; size_t v16 ; void * v17 ; _BOOL4 v18 ; __int64 v19 ; __int64 @@s@@ [ Number ] ; _QWORD * @@v21@@ ; __int64 @@v22@@ ; if ( ! * ( _DWORD * ) ( @@a2@@ + Number ) ) { hostapd_wps_clear_ies ( @@a1@@ , Number ) ; return Number L ; } @@v22@@ = os_zalloc ( Number L ) ; if ( ! @@v22@@ ) return Number ; * ( _QWORD * ) ( @@v22@@ + Number ) = hostapd_wps_cred_cb ; * ( _QWORD * ) ( @@v22@@ + Number ) = hostapd_wps_event_cb ; * ( _QWORD * ) ( @@v22@@ + Number ) = hostapd_wps_rf_band_cb ; * ( _QWORD * ) ( @@v22@@ + Number ) = @@a1@@ ; memset ( @@s@@ , Number , sizeof ( @@s@@ ) ) ; * ( _DWORD * ) ( @@v22@@ + Number ) = * ( ( _DWORD * ) @@a1@@ [ Number ] + Number ) ; * ( _DWORD * ) ( @@v22@@ + Number ) = * ( ( _DWORD * ) @@a1@@ [ Number ] + Number ) ; if ( ( unsigned int ) is_nil_uuid ( ( char * ) @@a1@@ [ Number ] + Number ) ) { @@v21@@ = ( _QWORD * ) get_own_uuid ( * @@a1@@ ) ; if ( ! @@v21@@ || * ( _DWORD * ) ( @@a2@@ + Number ) ) { uuid_gen_mac_addr ( ( char * ) @@a1@@ + Number , @@v22@@ + Number ) ; wpa_hexdump ( Number L , String , @@v22@@ + Number , Number L ) ; } else { v3 = @@v22@@ + Number ; v4 = @@v21@@ [ Number ] ; * ( _QWORD * ) ( @@v22@@ + Number ) = * @@v21@@ ; * ( _QWORD * ) ( v3 + Number ) = v4 ; wpa_hexdump ( Number L , String , @@v22@@ + Number , Number L ) ; } } else { v5 = @@v22@@ + Number ; v6 = * ( _QWORD * ) ( ( char * ) @@a1@@ [ Number ] + Number ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = * ( _QWORD * ) ( ( char * ) @@a1@@ [ Number ] + Number ) ; * ( _QWORD * ) ( v5 + Number ) = v6 ; wpa_hexdump ( Number L , String , @@v22@@ + Number , Number L ) ; } * ( _QWORD * ) ( @@v22@@ + Number ) = @@a1@@ [ Number ] [ Number ] ; memcpy ( ( void * ) ( @@v22@@ + Number ) , @@a1@@ [ Number ] + Number , * ( _QWORD * ) ( @@v22@@ + Number ) ) ; * ( _DWORD * ) @@v22@@ = Number ; memcpy ( ( void * ) ( @@v22@@ + Number ) , ( char * ) @@a1@@ + Number , Number ) ; if ( @@a1@@ [ Number ] [ Number ] ) v7 = strdup ( ( const char * ) @@a1@@ [ Number ] [ Number ] ) ; else v7 = Number L ; * ( _QWORD * ) ( @@v22@@ + Number ) = v7 ; if ( @@a1@@ [ Number ] [ Number ] ) v8 = strdup ( ( const char * ) @@a1@@ [ Number ] [ Number ] ) ; else v8 = Number L ; * ( _QWORD * ) ( @@v22@@ + Number ) = v8 ; if ( @@a1@@ [ Number ] [ Number ] ) v9 = strdup ( ( const char * ) @@a1@@ [ Number ] [ Number ] ) ; else v9 = Number L ; * ( _QWORD * ) ( @@v22@@ + Number ) = v9 ; if ( @@a1@@ [ Number ] [ Number ] ) v10 = strdup ( ( const char * ) @@a1@@ [ Number ] [ Number ] ) ; else v10 = Number L ; * ( _QWORD * ) ( @@v22@@ + Number ) = v10 ; if ( @@a1@@ [ Number ] [ Number ] ) v11 = strdup ( ( const char * ) @@a1@@ [ Number ] [ Number ] ) ; else v11 = Number L ; * ( _QWORD * ) ( @@v22@@ + Number ) = v11 ; v12 = wps_config_methods_str2bin ( @@a1@@ [ Number ] [ Number ] ) ; * ( _WORD * ) ( @@v22@@ + Number ) = v12 ; if ( ( * ( _WORD * ) ( @@v22@@ + Number ) & Number ) == Number ) { wpa_printf ( Number L , String ) ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } if ( ( * ( _WORD * ) ( @@v22@@ + Number ) & Number ) == Number ) { wpa_printf ( Number L , String ) ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } * ( _QWORD * ) ( @@v22@@ + Number ) = @@a1@@ [ Number ] [ Number ] ; if ( ( int ) hostapd_wps_set_vendor_ext ( ( __int64 ) @@a1@@ , @@v22@@ ) < Number ) goto LABEL_86 ; v13 = WPA_GET_BE32 ( ( unsigned int * ) @@a1@@ [ Number ] + Number ) ; * ( _DWORD * ) ( @@v22@@ + Number ) = v13 ; if ( * ( _BYTE * ) ( @@a2@@ + Number ) ) { * ( _BYTE * ) ( @@v22@@ + Number ) = * ( _BYTE * ) ( @@a2@@ + Number ) ; } else { if ( * ( ( _DWORD * ) @@a1@@ [ Number ] + Number ) == Number ) { v14 = Number ; } else if ( * ( ( _DWORD * ) @@a1@@ [ Number ] + Number ) == Number ) { v14 = Number ; } else { v14 = Number ; } * ( _BYTE * ) ( @@v22@@ + Number ) = v14 ; } if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } } if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } if ( ( * ( _DWORD * ) ( @@a2@@ + Number ) & Number ) != Number ) { * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } } if ( ! * ( _DWORD * ) ( @@a2@@ + Number ) ) { * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; * ( _WORD * ) ( @@v22@@ + Number ) |= Number ; } if ( ! * ( _QWORD * ) ( @@a2@@ + Number ) ) { if ( * ( _QWORD * ) ( @@a2@@ + Number ) ) { v15 = strdup ( * ( const char * * ) ( @@a2@@ + Number ) ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = v15 ; v16 = strlen ( * ( const char * * ) ( @@a2@@ + Number ) ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = v16 ; } else if ( * ( _QWORD * ) ( @@a2@@ + Number ) ) { * ( _QWORD * ) ( @@v22@@ + Number ) = malloc ( Number ) ; if ( ! * ( _QWORD * ) ( @@v22@@ + Number ) ) goto LABEL_86 ; wpa_snprintf_hex ( * ( _QWORD * ) ( @@v22@@ + Number ) , Number L , * ( _QWORD * ) ( @@a2@@ + Number ) + Number L , Number L ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = Number L ; } else if ( * ( _DWORD * ) ( @@a2@@ + Number ) && * ( _QWORD * ) ( @@a2@@ + Number ) ) { v17 = malloc ( * ( _QWORD * ) ( @@a2@@ + Number ) ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = v17 ; if ( ! * ( _QWORD * ) ( @@v22@@ + Number ) ) goto LABEL_86 ; memcpy ( * ( void * * ) ( @@v22@@ + Number ) , * ( const void * * ) ( @@a2@@ + Number ) , * ( _QWORD * ) ( @@a2@@ + Number ) ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = * ( _QWORD * ) ( @@a2@@ + Number ) ; } } if ( * ( _QWORD * ) ( @@a2@@ + Number ) ) { memcpy ( ( void * ) ( @@v22@@ + Number ) , ( const void * ) ( * ( _QWORD * ) ( @@a2@@ + Number ) + Number L ) , Number ) ; * ( _DWORD * ) ( @@v22@@ + Number ) = Number ; } * ( _WORD * ) ( @@v22@@ + Number ) = * ( _WORD * ) ( @@v22@@ + Number ) ; * ( _WORD * ) ( @@v22@@ + Number ) = * ( _WORD * ) ( @@v22@@ + Number ) ; if ( * ( _DWORD * ) ( @@a2@@ + Number ) == Number ) { * ( _WORD * ) ( @@v22@@ + Number ) = Number ; * ( _WORD * ) ( @@v22@@ + Number ) = Number ; * ( _WORD * ) ( @@v22@@ + Number ) = Number ; * ( _WORD * ) ( @@v22@@ + Number ) = Number ; } * ( _QWORD * ) ( @@v22@@ + Number ) = * ( _QWORD * ) ( @@a2@@ + Number ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = * ( _QWORD * ) ( @@a2@@ + Number ) ; @@s@@ [ Number ] = ( __int64 ) hostapd_wps_new_psk_cb ; @@s@@ [ Number ] = ( __int64 ) hostapd_wps_set_ie_cb ; @@s@@ [ Number ] = ( __int64 ) hostapd_wps_pin_needed_cb ; @@s@@ [ Number ] = ( __int64 ) hostapd_wps_reg_success_cb ; @@s@@ [ Number ] = ( __int64 ) hostapd_wps_enrollee_seen_cb ; @@s@@ [ Number ] = ( __int64 ) @@a1@@ ; LODWORD ( @@s@@ [ Number ] ) = * ( _DWORD * ) ( @@a2@@ + Number ) ; @@s@@ [ Number ] = * ( _QWORD * ) ( @@a2@@ + Number ) ; @@s@@ [ Number ] = * ( _QWORD * ) ( @@a2@@ + Number ) ; v18 = * ( ( _DWORD * ) @@a1@@ [ Number ] + Number ) == Number && * ( _DWORD * ) ( @@a2@@ + Number ) ; LODWORD ( @@s@@ [ Number ] ) = v18 ; if ( * ( _DWORD * ) ( @@a2@@ + Number ) == Number ) HIDWORD ( @@s@@ [ Number ] ) = Number ; LODWORD ( @@s@@ [ Number ] ) = ( int ) interface_count ( * @@a1@@ ) > Number ; if ( ( * ( _BYTE * ) ( @@v22@@ + Number ) & Number ) == Number ) LODWORD ( @@s@@ [ Number ] ) = Number ; if ( LODWORD ( @@s@@ [ Number ] ) ) wpa_printf ( Number L , String ) ; HIDWORD ( @@s@@ [ Number ] ) = * ( _DWORD * ) ( @@a2@@ + Number ) ; v19 = wps_registrar_init ( @@v22@@ , @@s@@ ) ; * ( _QWORD * ) ( @@v22@@ + Number ) = v19 ; if ( * ( _QWORD * ) ( @@v22@@ + Number ) ) { hostapd_register_probereq_cb ( @@a1@@ , hostapd_wps_probe_req_rx , @@a1@@ ) ; @@a1@@ [ Number ] = ( _QWORD * ) @@v22@@ ; return Number L ; } wpa_printf ( Number L , String ) ; LABEL_86 : hostapd_free_wps ( @@v22@@ ) ; return Number ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "_QWORD *"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}, {"n": "s", "t": {"T": 2, "n": 12, "s": 8, "t": "__int64"}, "location": "s112"}, {"n": "v21", "t": {"T": 3, "t": "_QWORD"}, "location": "s16"}, {"n": "v22", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s8"}]}