Function at 0x10082d20
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x26c
mov eax, dword [0x103b1004]
xor eax, esp
mov dword [esp + 0x268], eax
push ebx
mov eax, ecx
push esi
push edi
xor edi, edi
mov dword [esp + 0x10], eax
mov ebx, dword [eax + 0x10]
test ebx, ebx
jne 0x10082d8d
mov ebx, 0x1036fe24
lea esi, [edi + 1]
mov eax, 0xc
push eax
push dword [0x103cc55c]
call dword [0x103cc560]
mov edx, eax
add esp, 8
mov dword [esp + 0x18], edx
test edx, edx
jne 0x10082df6
mov ecx, dword [0x103fb118]
mov eax, dword [sym.python310.dll_PyExc_MemoryError]
cmp dword [eax + 4], edi
je 0x10083139
jmp 0x10082dc0
mov esi, ebx
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x10082d92
sub esi, ecx
sar esi, 1
lea eax, [esi + 5]
cmp eax, 0x3fffffff
jbe 0x10082db1
mov dword [esp + 0x18], edi
jmp 0x10082d77
add eax, eax
cmp eax, 0x7fffffff
jbe 0x10082d59
mov dword [esp + 0x18], edi
jmp 0x10082d77
push 0
push eax
push ecx
call sym.python310.dll__PyErr_SetObject
add esp, 0xc
push dword [esp + 0x18]
push dword [0x103cc55c]
call dword [0x103cc56c]
mov ecx, dword [esp + 0x27c]
add esp, 8
mov eax, edi
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1024a596
mov esp, ebp
pop ebp
ret
mov ecx, edx
sub ecx, ebx
nop word [eax + eax]
movzx eax, word [ebx]
lea ebx, [ebx + 2]
mov word [ecx + ebx - 2], ax
test ax, ax
jne 0x10082e00
test esi, esi
jle 0x10082e41
movzx eax, word [edx + esi*2 - 2]
cmp eax, 0x5c
je 0x10082e32
cmp eax, 0x2f
je 0x10082e32
cmp eax, 0x3a
je 0x10082e32
mov eax, 0x5c
mov word [edx + esi*2], ax
inc esi
mov dword [edx + esi*2], 0x2e002a
mov dword [edx + esi*2 + 4], 0x2a
push 0
call sym.python310.dll_PyList_New
mov edi, eax
add esp, 4
test edi, edi
je 0x10082dcc
call sym.python310.dll_PyEval_SaveThread
mov esi, eax
lea eax, [esp + 0x20]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, eax
mov dword [esp + 0x14], ebx
test esi, esi
je 0x10083148
mov ecx, esi
call fcn.101c8d20
mov eax, dword [esi + 8]
mov ecx, dword [eax + 8]
mov eax, dword [ecx + 0x118]
add ecx, 0x118
xchg dword [ecx], esi
cmp ebx, 0xffffffff
jne 0x10082ed8
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
je 0x10082dcc
add dword [edi], ebx
jne 0x10082eb8
mov eax, dword [edi + 4]
push edi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
mov eax, dword [esp + 0x10]
push 0
push dword [eax + 0x20]
push 0
push dword [sym.python310.dll_PyExc_OSError]
call sym.python310.dll_PyErr_SetExcFromWindowsErrWithFilenameObjects
add esp, 0x10
mov edi, eax
jmp 0x10082dcc
mov eax, dword [sym.imp.KERNEL32.dll_FindNextFileW]
mov dword [esp + 0x1c], eax
mov ecx, 0x1036fe24
lea eax, [esp + 0x4c]
nop word [eax + eax]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x10082f16
test dx, dx
je 0x10082f12
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x10082f16
add eax, 4
add ecx, 4
test dx, dx
jne 0x10082ef0
xor eax, eax
jmp 0x10082f1b
sbb eax, eax
or eax, 1
test eax, eax
je 0x10083018
mov ecx, 0x1036fe30
lea eax, [esp + 0x4c]
nop dword [eax]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x10082f56
test dx, dx
je 0x10082f52
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x10082f56
add eax, 4
add ecx, 4
test dx, dx
jne 0x10082f30
xor eax, eax
jmp 0x10082f5b
sbb eax, eax
or eax, 1
test eax, eax
je 0x10083018
lea eax, [esp + 0x4c]
lea edx, [eax + 2]
nop word [eax + eax]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x10082f70
sub eax, edx
sar eax, 1
push eax
lea eax, [esp + 0x50]
push eax
call sym.python310.dll_PyUnicode_FromWideChar
mov esi, eax
add esp, 8
mov eax, dword [esp + 0x10]
cmp dword [eax + 0x14], 0
je 0x10082fbf
test esi, esi
je 0x100830b8
push esi
mov ebx, esi
call sym.python310.dll_PyUnicode_EncodeFSDefault
add esp, 4
mov esi, eax
add dword [ebx], 0xffffffff
jne 0x10082fbf
mov eax, dword [ebx + 4]
push ebx
mov eax, dword [eax + 0x18]
call eax
add esp, 4
test esi, esi
je 0x100830b8
mov eax, dword [edi + 4]
test dword [eax + 0x54], 0x2000000
je 0x10083080
mov ebx, dword [edi + 8]
mov ecx, edi
lea edx, [ebx + 1]
call fcn.1010cfc0
test eax, eax
jns 0x10082fed
or ecx, 0xffffffff
jmp 0x10082ff7
inc dword [esi]
xor ecx, ecx
mov eax, dword [edi + 0xc]
mov dword [eax + ebx*4], esi
mov eax, dword [esi]
dec eax
mov dword [esi], eax
test ecx, ecx
jne 0x100830a8
test eax, eax
jne 0x10083014
mov eax, dword [esi + 4]
push esi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
mov ebx, dword [esp + 0x14]
mov esi, dword [0x103fb118]
xor eax, eax
mov ecx, 0x103fb118
xchg dword [ecx], eax
test esi, esi
je 0x1008312f
mov edx, dword [esi + 8]
mov ecx, 0x103fb0c0
add edx, 0x2c
push esi
call fcn.101c8c00
add esp, 4
lea eax, [esp + 0x20]
push eax
push ebx
call dword [esp + 0x24]
mov ecx, esi
mov ebx, eax
call fcn.101c8d20
mov ecx, dword [esi + 8]
mov edx, dword [ecx + 8]
mov ecx, dword [edx + 0x118]
add edx, 0x118
xchg dword [edx], esi
test ebx, ebx
je 0x10083104
cmp ebx, 1
jne 0x100830cb
mov ebx, dword [esp + 0x14]
jmp 0x10082ee1
mov eax, dword [0x103fb118]
push 0x150
push str.D:_a1_sObjectslistobject.c
push str._s:_d:_bad_argument_to_internal_function
push dword [sym.python310.dll_PyExc_SystemError]
push eax
call sym.python310.dll__PyErr_Format
mov eax, dword [esi]
add esp, 0x14
dec eax
mov dword [esi], eax
test eax, eax
jne 0x100830b8
mov eax, dword [esi + 4]
push esi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
add dword [edi], 0xffffffff
jne 0x100830c9
mov eax, dword [edi + 4]
push edi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
xor edi, edi
mov ebx, dword [esp + 0x10]
push dword [esp + 0x14]
call dword [sym.imp.KERNEL32.dll_FindClose]
test eax, eax
jne 0x10082dcc
test edi, edi
je 0x10082dcc
add dword [edi], 0xffffffff
jne 0x100830fa
mov eax, dword [edi + 4]
push edi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
push 0
push dword [ebx + 0x20]
jmp 0x10082ec1
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
je 0x100830cb
add dword [edi], 0xffffffff
jne 0x10083120
mov eax, dword [edi + 4]
push edi
mov eax, dword [eax + 0x18]
call eax
add esp, 4
mov ebx, dword [esp + 0x10]
mov ecx, ebx
call fcn.10081d00
mov edi, eax
jmp 0x100830cf
push 0x10389b20
call sym.python310.dll__Py_FatalError_TstateNULL
push str.Out_of_memory_and_PyExc_MemoryError_is_not_initialized_yet
push 0x1038c108
call sym.python310.dll__Py_FatalErrorFunc
push 0x10389b34
call sym.python310.dll__Py_FatalError_TstateNULL
int3