Function at 0x40478c
Capabilities:
Encode data using xor
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ecx, 0x15
mov ebp, esp
push edi
push esi
lea edi, [ebp - 0x52d]
mov esi, 0x413094
push ebx
sub esp, 0x56c
mov eax, dword [0x4120f8]
mov dword [ebp - 0x53a], 0x4b04a5a3
rep movsb byte es:[edi], byte [esi]
mov ecx, 0x412c2c
lea edx, [eax + 0x746c681]
mov dword [0x411da0], edx
mov dl, byte [ecx]
test dl, dl
je 0x4047e7
sub edx, 0x30
cmp dl, 9
jbe 0x4047e4
xor eax, 0x6dd68629
mov dword [0x411da0], eax
jmp 0x4047e7
inc ecx
jmp 0x4047ca
mov eax, dword [0x411f7c]
mov ebx, dword [0x411da0]
mov dword [esp + 4], str.PartA_PrivTags
mov dword [esp], str.sv_SE
mov dword [esp + 0xc], eax
mov dword [esp + 8], eax
call fcn.0040f01c
cmp byte [0x412c2c], 0
je 0x40481c
call fcn.0040d7a0
mov esi, dword [0x41201c]
xor esi, 0x1d919feb
imul eax, esi, 0xcea8e3bd
sub eax, 0x2420f2e3
mov dword [0x41201c], eax
xor eax, eax
cmp byte [eax + 0x4125c4], 0
je 0x404850
inc eax
cmp eax, 0x2166
jne 0x40483a
call fcn.0040cc44
imul eax, esi, 0xcf652cbd
mov esi, ebx
xor ebx, ebx
or esi, 0x3a0c6f95
mov dword [0x411f7c], esi
mov dword [ebp - 0x54c], eax
mov al, byte [str.sv_SE]
mov byte [ebp - 0x550], al
cmp byte [ebp - 0x550], 0
mov edi, dword [0x41201c]
je 0x4048bb
mov eax, dword [ebp - 0x54c]
mov dword [esp + 0xc], str.EventThrottleMaxEvents
mov dword [esp + 8], edi
mov dword [esp + 0x10], eax
mov dword [esp + 4], 0x412c2c
mov dword [esp], str.EventThrottleMaxEvents
call fcn.0040da60
lea eax, [edi + 0x89fac4a]
mov dword [0x411da0], eax
mov byte [ebp + ebx - 0x518], bl
and edi, 0x5866e76a
lea eax, [esi + 0x439189e4]
inc ebx
mov dword [0x4120f8], edi
mov dword [0x41201c], eax
cmp ebx, 0x100
jne 0x404877
mov edx, str.bad_address
mov ecx, 0xec
movsx eax, byte [edx]
inc edx
test al, al
je 0x40490d
add ecx, eax
cmp ecx, 0x17e9
jbe 0x4048ec
mov eax, dword [0x411da0]
sub eax, 0x6507da8d
mov dword [0x411f7c], eax
mov eax, dword [0x411f7c]
xor edi, edi
xor esi, esi
mov dword [ebp - 0x550], eax
mov eax, esi
mov ebx, 0x14
xor edx, edx
mov cl, byte [ebp + esi - 0x518]
div ebx
movzx eax, byte [ebp + edx - 0x52d]
movzx edx, cl
add eax, edx
add eax, edi
movzx edi, al
mov al, byte [ebp + edi - 0x518]
mov byte [ebp + esi - 0x518], al
inc esi
mov byte [ebp + edi - 0x518], cl
cmp esi, 0x100
jne 0x40491c
xor eax, eax
cmp byte [eax + str.bad_address], 0
je 0x404976
inc eax
cmp eax, 0x23d2
jne 0x404960
call fcn.0040c7c8
mov edx, 0x412c2c
mov al, byte [edx]
test al, al
je 0x4049ab
sub eax, 0x30
cmp al, 9
jbe 0x4049a8
mov ebx, dword [ebp - 0x550]
and ebx, 0x40ee935a
add ebx, 0x5ca9f61c
xor ebx, 0xe1ace4dd
mov dword [0x411da0], ebx
jmp 0x4049ab
inc edx
jmp 0x40497b
mov eax, dword [ebp - 0x54c]
xor edx, edx
xor edi, edi
xor esi, esi
xor eax, 0x3f812a92
mov dword [0x4120f8], eax
lea eax, [esi + 1]
mov ecx, dword [0x4120f8]
mov dword [ebp - 0x558], edx
movzx esi, al
mov bl, byte [ebp + esi - 0x518]
or ecx, 0xa79c6ad0
mov dword [0x4120f8], ecx
lea eax, [ebx + edi]
mov dword [ebp - 0x554], ecx
movzx edi, al
call fcn.0040cc44
mov eax, dword [0x411da0]
mov edx, dword [ebp - 0x558]
mov ecx, dword [ebp - 0x554]
mov dword [ebp - 0x550], eax
xor eax, 0x62a8b459
mov dword [ebp - 0x54c], eax
xor ecx, 0x4678033e
mov dword [0x41201c], eax
mov al, byte [ebp + edi - 0x518]
mov dword [0x411f7c], ecx
mov byte [ebp + esi - 0x518], al
mov byte [ebp + edi - 0x518], bl
add bl, byte [ebp + esi - 0x518]
movzx ebx, bl
mov al, byte [ebp + ebx - 0x518]
xor al, byte [ebp + edx - 0x53a]
movzx eax, al
mov word [ebp + edx*2 - 0x536], ax
inc edx
cmp edx, 4
jne 0x4049c1
mov word [ebp - 0x52e], 0
xor eax, eax
mov dword [ebp - 0x544], eax
mov eax, dword [ebp - 0x550]
or eax, 0x3af6364a
mov dword [0x411f7c], eax
xor eax, eax
mov dword [ebp - 0x540], eax
mov eax, dword [ebp - 0x54c]
add eax, 0x298dda16
mov dword [0x41217c], eax
xor eax, eax
cmp byte [eax + str.sv_SE], 0
je 0x404acc
inc eax
cmp eax, 0x178a
jne 0x404aa7
call fcn.0040c7c8
imul eax, dword [ebp - 0x54c], 0xabbd3750
mov dword [0x411da0], eax
mov edx, dword [0x411da0]
xor eax, eax
lea edi, [ebp - 0x418]
mov ecx, 0x100
rep stosd dword es:[edi], eax
and edx, 0xc3bc3046
imul edx, edx, 0x404ec90a
mov eax, edx
mov dword [0x41217c], edx
xor eax, 0x2d57d079
mov ecx, eax
mov dword [0x41201c], eax
or ecx, 0x180514f5
mov dword [0x411f7c], ecx
mov ecx, dword [0x410be0]
cmp dword [ecx + 0x178], 0
jne 0x404b5a
mov ebx, str.rm_CH
mov cl, byte [ebx]
test cl, cl
je 0x404b40
sub ecx, 0x30
cmp cl, 9
jbe 0x404b3d
or edx, 0xfdaa20a6
mov dword [0x41217c], edx
jmp 0x404b40
inc ebx
jmp 0x404b21
imul eax, eax, 0x7a7d0b1f
mov dword [0x4120f8], eax
call fcn.0040cc44
xor eax, eax
mov dword [esp], eax
call fcn.004018f0
mov ebx, dword [0x410be0]
cmp dword [ebx + 4], 0
je 0x404baa
mov eax, dword [0x410be0]
xor edi, edi
mov edx, dword [eax + 0x178]
mov dword [esp + 0xc], edi
movzx ecx, word [edx + 4]
mov dword [esp + 8], ecx
mov edx, dword [edx]
mov dword [esp + 4], edx
mov edx, dword [eax + 4]
mov dword [esp], edx
call dword [eax + 0x104]
mov dword [ebp - 0x54c], eax
sub esp, 0x10
test eax, eax
je 0x404bee
mov edx, 0x412760
mov ecx, 0x7a
jmp 0x404bff
xor dword [0x41201c], 0xa11a2647
xor esi, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0xc], esi
mov dword [esp + 8], esi
mov dword [esp + 4], 1
mov eax, dword [ebx + 0x194]
mov dword [esp], eax
call dword [ebx + 0x100]
mov dword [ebx + 4], eax
mov eax, dword [0x410be0]
sub esp, 0x14
cmp dword [eax + 4], 0
jne 0x404b66
xor ecx, ecx
xor edi, edi
xor ebx, ebx
mov dword [ebp - 0x54c], ecx
jmp 0x405043
movzx eax, byte [edx]
inc edx
test al, al
je 0x404c3f
add ecx, eax
cmp ecx, 0x742
jbe 0x404bff
mov eax, dword [0x41217c]
mov dword [esp + 0xc], str.EventThrottleMaxEvents
mov dword [esp + 0x10], eax
mov eax, dword [0x411da0]
mov dword [esp + 4], str.EventThrottleMaxEvents
mov dword [esp + 8], eax
mov dword [esp], 0x412760
call fcn.0040da60
mov edx, dword [0x41217c]
xor eax, eax
cmp byte [eax + str.bad_address], 0
je 0x404c87
inc eax
cmp eax, 0x26ff
jne 0x404c47
imul edx, edx, 0x6627f89c
mov dword [esp + 0x10], 0x413500
mov eax, dword [0x41201c]
mov dword [esp + 4], 0x4125c4
mov dword [esp + 0xc], eax
mov dword [esp + 8], edx
mov dword [esp], 0x412c2c
call fcn.0040c73c
mov eax, dword [0x41201c]
xor ebx, ebx
and eax, 0xd84eb8c8
mov dword [0x411da0], eax
mov eax, dword [0x4120f8]
or eax, 0xf294ba3b
mov dword [0x411f7c], eax
mov eax, dword [0x410be0]
mov esi, dword [eax + 0x198]
cmp dword [esi + ebx*4], 0
je 0x404cbb
inc ebx
jmp 0x404cb2
call fcn.0040a160
xor edx, edx
mov ecx, 0x412c2c
div ebx
mov eax, dword [0x411f7c]
mov ebx, 0x17d8
mov esi, dword [esi + edx*4]
lea edx, [eax + 0x5df1fb11]
mov dword [0x4120f8], edx
movzx edx, byte [ecx]
inc ecx
test dl, dl
je 0x404cf4
add ebx, edx
cmp ebx, 0x23b3
jbe 0x404ce2
mov edi, dword [0x41201c]
sub eax, 0x2d7f7faa
mov dword [0x41217c], eax
lea edx, [edi + 0xc4f618c]
mov dword [0x411da0], edx
call fcn.0040c7c8
mov eax, dword [0x410be0]
mov dword [ebp - 0x544], 0x100
mov edx, dword [eax + 0x178]
cmp dword [edx + 8], 0
je 0x404d3a
mov dword [ebp - 0x544], 0x800100
mov edx, dword [ebp - 0x544]
mov dword [esp + 8], esi
mov dword [esp + 0x18], edx
xor edx, edx
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], edx
lea edx, [ebp - 0x536]
mov dword [esp + 4], edx
mov edi, dword [ebp - 0x54c]
mov dword [esp], edi
xor edi, edi
call dword [eax + 0x108]
sub esp, 0x1c
mov ebx, eax
test eax, eax
je 0x405043
mov eax, dword [0x410be0]
mov edx, dword [eax + 0x178]
cmp dword [edx + 8], 0
je 0x404dbf
mov dword [ebp - 0x544], 0x3300
lea edx, [ebp - 0x544]
mov dword [esp + 0xc], 4
mov dword [esp + 8], edx
mov dword [esp + 4], 0x1f
mov dword [esp], ebx
call dword [eax + 0x10c]
sub esp, 0x10
xor edi, edi
mov eax, dword [0x410be0]
mov edx, dword [eax + 0x19c]
mov esi, dword [edx + edi]
add edi, 4
test esi, esi
je 0x404df8
mov dword [esp + 0xc], 0x20000000
mov dword [esp + 8], 0xffffffff
mov dword [esp + 4], esi
mov dword [esp], ebx
call dword [eax + 0x110]
sub esp, 0x10
jmp 0x404dc1
mov edi, dword [ebp + 8]
xor ecx, ecx
mov edx, dword [edi + 4]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], edx
mov dword [esp + 0x10], edx
mov edx, dword [edi]
xor edi, edi
mov dword [esp + 8], edi
mov dword [esp + 4], edi
mov dword [esp + 0xc], edx
mov dword [esp], ebx
call dword [eax + 0x114]
sub esp, 0x1c
mov edi, eax
test eax, eax
je 0x405043
xor edi, edi
mov dword [esp], ebx
mov dword [esp + 4], edi
mov eax, dword [0x410be0]
call dword [eax + 0x118]
push edx
push edx
test eax, eax
je 0x404e70
mov eax, dword [0x41201c]
add eax, 0x40215f9
mov dword [0x411da0], eax
mov dword [esp], ebx
call fcn.004046dc
cmp dword [ebp + 0xc], 0
je 0x404e70
cmp eax, 0xc8
je 0x404e77
xor edi, edi
jmp 0x405043
imul eax, dword [0x411da0], 0x31bba1fd
xor edi, edi
mov dword [0x41201c], eax
lea eax, [ebp - 0x540]
mov dword [esp + 8], 0x400
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x418]
mov dword [esp + 4], eax
mov dword [esp], ebx
mov eax, dword [0x410be0]
call dword [eax + 0x11c]
mov dword [ebp - 0x550], eax
sub esp, 0x10
test eax, eax
je 0x404fed
mov eax, dword [ebp - 0x540]
test eax, eax
je 0x404fed
test esi, esi
jne 0x404eec
mov dword [esp + 4], eax
mov dword [esp], 0x40
mov eax, dword [0x410be0]
call dword [eax + 0x50]
push esi
push esi
jmp 0x404f3c
mov edx, str.sv_SE
mov cl, byte [edx]
test cl, cl
je 0x404f0e
sub ecx, 0x30
cmp cl, 9
jbe 0x404f0b
xor dword [0x4120f8], 0x5517d97d
jmp 0x404f0e
inc edx
jmp 0x404ef1
mov ecx, dword [0x411da0]
add eax, edi
sub ecx, 0x1dcaa8e6
mov dword [0x411f7c], ecx
mov dword [esp + 8], 0x42
mov dword [esp + 4], eax
mov dword [esp], esi
mov eax, dword [0x410be0]
call dword [eax + 0x54]
sub esp, 0xc
mov esi, eax
mov eax, dword [ebp - 0x540]
lea edx, [esi + edi]
lea ecx, [eax + edi]
mov dword [ebp - 0x554], ecx
mov dword [esp + 8], eax
lea eax, [ebp - 0x418]
mov dword [esp + 4], eax
mov dword [esp], edx
call fcn.00405bf8
cmp byte [str.sv_SE], 0
je 0x404f83
call fcn.0040cc44
mov eax, dword [0x41201c]
add eax, 0x646e4a30
mov dword [0x411da0], eax
imul edx, dword [0x4120f8], 0xb9a9c643
mov eax, dword [0x411f7c]
and eax, 0x6da371de
mov dword [0x41201c], edx
mov dword [0x41217c], eax
mov dword [esp + 8], edx
mov dword [esp + 0xc], eax
mov dword [esp + 4], 0x413500
mov dword [esp], str.sv_SE
call fcn.0040f01c
xor ecx, ecx
lea eax, [ebp - 0x418]
mov dword [esp + 8], 0x400
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.00405c64
cmp dword [ebp - 0x550], 1
mov edi, dword [ebp - 0x554]
je 0x404e88
mov eax, dword [0x41217c]
mov ecx, dword [ebp + 0xc]
mov edx, str.rm_CH
or eax, 0x6edd42c1
mov dword [ecx + 4], edi
xor eax, 0x1a01729a
mov dword [ecx], esi
mov dword [0x411f7c], eax
mov al, byte [edx]
test al, al
je 0x40502f
sub eax, 0x30
cmp al, 9
jbe 0x40502c
mov eax, dword [0x41201c]
xor eax, 0xf28c42d7
mov dword [0x4120f8], eax
jmp 0x40502f
inc edx
jmp 0x40500e
imul eax, dword [0x41201c], 0x5e848994
mov edi, 1
mov dword [0x411da0], eax
mov eax, dword [0x410be0]
mov edx, dword [eax + 4]
test edx, edx
je 0x405063
mov dword [esp], edx
call dword [eax + 0x120]
xor edx, edx
push esi
mov eax, dword [0x410be0]
mov dword [eax + 4], edx
cmp dword [ebp - 0x54c], 0
je 0x40508b
mov eax, dword [ebp - 0x54c]
and dword [0x41217c], 0x81858827
mov dword [esp], eax
mov eax, dword [0x410be0]
call dword [eax + 0x120]
push ecx
test ebx, ebx
je 0x40509e
mov dword [esp], ebx
mov eax, dword [0x410be0]
call dword [eax + 0x120]
push edx
mov ebx, dword [0x411f7c]
mov esi, dword [0x410be0]
test edi, edi
jne 0x4050f3
mov eax, dword [esi + 0x178]
sub ebx, 0x2ec74bdc
mov dword [esp], eax
call fcn.0040461c
mov dword [0x411f7c], ebx
mov dword [esi + 0x178], eax
mov eax, dword [0x41201c]
mov dword [esi + 0x184], 1
mov dword [esi + 0x188], 2
and eax, 0x857c1e4f
mov dword [0x4120f8], eax
jmp 0x40516b
mov edx, dword [0x41217c]
mov eax, edx
and eax, 0xce6c8beb
mov dword [0x4120f8], eax
xor eax, eax
cmp byte [eax + str.originatingContextMessage], 0
je 0x405124
inc eax
cmp eax, 0x22c2
jne 0x405107
and edx, 0x8e440223
mov dword [0x41217c], edx
mov eax, dword [0x411da0]
and ebx, 0x34a3183f
mov dword [0x41201c], ebx
xor eax, 0xb364cc1d
mov dword [0x411da0], eax
mov dword [esp + 8], eax
mov dword [esp + 0x10], str.PartA_PrivTags
mov dword [esp + 0xc], ebx
mov dword [esp + 4], str.rm_CH
mov dword [esp], str.EventThrottleMaxEvents
call fcn.0040c73c
xor eax, eax
mov dword [esi + 0x184], eax
lea esp, [ebp - 0xc]
mov eax, edi
pop ebx
pop esi
pop edi
pop ebp
ret