Function at 0x404330
Capabilities:
Delete file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x202c
call fcn.0043d750
mov eax, dword [0x47b014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - method.DynamicArray_class_DEVICE_INFORMATION_WRAPPER__unsigned_int_.virtual_0], vtable.DynamicArray_class_DEVICE_INFORMATION_WRAPPER__unsigned_int_.0
lea ecx, [ebp - 0x2020]
mov dword [ebp - 0x201c], 0
mov dword [ebp - 0x2018], 0
mov dword [ebp - 0x2014], 1
mov dword [ebp - 0x2010], 0
call fcn.00404520
mov ebx, eax
test ebx, ebx
jne 0x4044f3
mov edx, 0x1000
lea ecx, [ebp - 0x2008]
call fcn.00401fc0
push ebx
push ebx
push 2
push ebx
push ebx
push 0x40000000
lea eax, [ebp - 0x2008]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x2028], eax
cmp eax, 0xffffffff
jne 0x4043d7
push eax
mov ebx, 0xb
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4044e6
lea eax, [ebp - 0x2024]
mov dword [ebp - 0x200c], 0
push eax
lea edx, [ebp - 0x200c]
mov dword [ebp - 0x2024], 0
lea ecx, [ebp - 0x2020]
call fcn.00403d20
mov ebx, eax
add esp, 4
mov dword [ebp - 0x202c], ebx
test ebx, ebx
jne 0x4044d5
mov ebx, dword [ebp - 0x200c]
mov edx, str.___DEVICE_INFORMATION_LIST___
push ebx
mov ecx, str._VendorInformation__r_n__r_n_SCANMATIK_LLC___RP1210C_Vendor_INI_File_r_n_________________________________________________________________________________r_n__r_n__Date:_November_22__2024_r_n_________________________________________________________________________________r_nNameScanmatik_SM2_Adapter_r_nAddress1Pavlova_2_r_nAddress2_r_nCityKorolev_r_nStateMSK_r_nCountryRussia_r_nPostal141072_r_nTelephone7_495_502_80_10_r_nFax7_495_502_80_10_r_nVendorURLhttp:__scanmatik.com_r_nMessageStringMS1210_MSG_r_nErrorStringMS1210_ERR_r_n_________________________________________________________________________________r_n__Each_SM2_produces_a_timestamp_weight_of_1000_microseconds__1ms__r_nTimestampWeight1000_r_n__r_n_________________________________________________________________________________r_n__Each_SM2_device_defined_in_this_INI_file_is__auto_detect__capable_r_nAutoDetectCapableYes_r_n__r_n_________________________________________________________________________________r_n__This_INI_file_version_revision_r_nVersion1.1_r_n__r_n_________________________________________________________________________________r_n__This_INI_file_is_RP1210C_compliant_r_nRP1210C_r_n__r_n_________________________________________________________________________________r_n_SM2_Supports_API_Level_Debugging__Levels_0___4__r_n__r_n__To_use_API_level_debugging__modify_the_DebugLevel_variable_to:_r_n__r_n__0__No_debugging_to_be_accomplished__default_._r_n__1__Only_Connect_Disconnect_Error_Messages._r_n__2__Add_RP1210_SendCommand_calls._r_n__3__Add_all_Sent_Messages__with_filtering_._r_n__4__Add_all_Received_Messages__with_filtering_._r_n__r_n__The_variable_DebugFile_is_the_file_where_you_want_to_write_the_information._r_n__r_n__The_DebugFileSize_variable_is_how_many_1k_chunks_you_will_allow_the_API_to_r_n__write_before_it_begins_to_write_over_previously_written_entries._A_value_r_n__of_1024_is_1_megabyte__default_._r_n__r_n__The_DebugMode_variable_describes_how_the_API_will_interact_with_the_DebugFile._r_n__Should_it_overwrite__value__0__any_previous_entries_or_should_it_append_r_n__entries__value__1__to_the_end_of_the_file._r_n_________________________________________________________________________________r_nDebugLevel0_r_nDebugFilec:_smrp1210.txt_r_nDebugMode1_r_nDebugFileSize1024_r_n__r_n_________________________________________________________________________________r_n__Scanmatik_Supports_1_RTS_CTS_session_and_BAM_session_per_each_client._r_nNumberOfRTSCTSSessions1_r_n__r_n_________________________________________________________________________________r_n__Scanmatik_Supports_all_5_CAN_connect_formats__see_RP1210C_documentation__r_n__r_n__Also_supports__Channel__parameter__where_allowed._r_n__r_n__Format_1__r_n__fpchProtocol_CAN:BaudX_SampleLocationY_SJWZ_IDSizeS__r_n__Format_2__r_n__fpchProtocol_CAN:BaudX_PROP_SEGA_PHASE_SEG1B_PHASE_SEG2C_SJWZ_IDSizeSS__r_n__Format_3__r_n__fpchProtocol_CAN:BaudX_TSEG1D_TSEG2E_SJWZ_IDSizeSS__r_n__Format_4__r_n__fpchProtocol_CAN__r_n__Format_5__r_n__fpchProtocol_CAN:BaudX__r_n_________________________________________________________________________________r_nCANFormatsSupported1_2_3_4_5_r_n__r_n_________________________________________________________________________________r_n__Scanmatik_Supports_all_5_J1939_connect_formats__see_RP1210C_documentation__r_n__r_n__Also_supports__Channel__parameter__where_allowed._r_n__r_n__Format_1__r_n__fpchProtocol_J1939:BaudX__r_n__Format_2__r_n__fpchProtocol_J1939__r_n__Format_3__r_n__fpchProtocol_J1939:BaudX_SampleLocationY_SJWZ_IDSizeS__r_n__Format_4__r_n__fpchProtocol_J1939:BaudX_PROP_SEGA_PHASE_SEG1B_PHASE_SEG2C_SJWZ_IDSizeSS__r_n__Format_5__r_n__fpchProtocol_J1939:BaudX_TSEG1D_TSEG2E_SJWZ_IDSizeSS__r_n_________________________________________________________________________________r_nJ1939FormatsSupported1_2_3_4_5_r_n__r_n_________________________________________________________________________________r_n__Scanmatik_s
call fcn.00401af0
mov edi, dword [ebp - 0x2024]
add esp, 4
mov esi, eax
mov edx, str.___DEVICES_NUMBERS___
mov ecx, esi
push edi
call fcn.00401af0
add esp, 4
mov dword [ebp - 0x2024], eax
push esi
call fcn.00430bb8
add esp, 4
push ebx
call fcn.00430bb8
add esp, 4
push edi
call fcn.00430bb8
mov ecx, dword [ebp - 0x2024]
add esp, 4
mov esi, ecx
lea edx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x404473
mov edi, dword [ebp - 0x2028]
lea eax, [ebp - 0x200c]
push 0
push eax
sub esi, edx
mov dword [ebp - 0x200c], 0
push esi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4044aa
cmp dword [ebp - 0x200c], esi
je 0x4044bf
push dword [ebp - 0x2024]
mov ebx, 0xc
call fcn.00430bb8
add esp, 4
jmp 0x4044db
push dword [ebp - 0x2024]
mov ebx, dword [ebp - 0x202c]
call fcn.00430bb8
add esp, 4
jmp 0x4044db
mov edi, dword [ebp - 0x2028]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test ebx, ebx
je 0x4044f3
lea eax, [ebp - 0x2008]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push dword [ebp - 0x2010]
call fcn.00430bb8
mov ecx, dword [ebp - 4]
add esp, 4
mov eax, ebx
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.00422009
mov esp, ebp
pop ebp
ret