Function at 0x10022d00
Capabilities:
Parse credit card information

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
mov eax, dword [ebp + 0xc]
xor ecx, ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov bh, byte [eax]
mov dword [ebp - 8], ecx
mov byte [ebp - 4], bh
mov esi, dword [edi + 0x20]
movsx eax, byte [esi + 0x3bd]
sub eax, ecx
je 0x10022daf
sub eax, 1
je 0x10022d83
sub eax, 1
jne 0x10022dc7
push dword [ebp - 4]
call fcn.1001ff10
add esp, 4
test al, al
js 0x10023070
movzx eax, byte [esi + 0x3be]
push eax
call fcn.1001ff10
push dword [ebp - 4]
mov bl, al
shl bl, 4
call fcn.1001ff10
mov bh, al
add esp, 8
mov eax, dword [ebp + 0xc]
or bh, bl
mov ecx, 1
mov dword [ebp - 8], ecx
mov byte [eax], bh
mov byte [esi + 0x3bd], 0
jmp 0x10022dca
push dword [ebp - 4]
call fcn.1001ff10
add esp, 4
test al, al
js 0x10023070
pop edi
mov byte [esi + 0x3be], bh
mov eax, 1
mov byte [esi + 0x3bd], 2
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x25
jne 0x10022dc7
pop edi
mov byte [esi + 0x3bd], 1
mov eax, 1
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0xc]
test bh, bh
jne 0x10022de6
cmp byte [esi + 0x364], bh
je 0x1002308b
cmp byte [esi + 0x3bf], bh
je 0x1002308b
movsx edx, byte [esi + 0x3bc]
mov dword [ebp + 0xc], 0xffff
cmp edx, 3
ja case.default.0x10022dfd
jmp dword [edx*4 + 0x10023118]
cmp bh, 0x26
je 0x10022e12
cmp bh, 0x3b
jne 0x10022ea3
test ecx, ecx
jne 0x10022ea3
push ecx
push edi
call fcn.10022030
add esp, 8
test eax, eax
js 0x1002308b
mov ecx, dword [edi + 0x20]
mov edx, 0xffff
movzx eax, byte [ecx + 0x3bb]
add word [ecx + eax*8 + 0x14], dx
mov al, byte [esi + 0x3bb]
lea ecx, [eax + 1]
movzx eax, al
mov byte [esi + eax*8 + 0x16], cl
mov al, byte [esi + 0x3bb]
inc al
mov byte [esi + 0x3bb], al
cmp al, 0x60
jae 0x100230b9
inc dword [esi + 0x39c]
mov ecx, dword [esi + 0x39c]
movzx eax, al
mov byte [esi + 0x3bf], 0
pop edi
mov dword [esi + eax*8 + 0x10], ecx
xor ecx, ecx
movzx eax, byte [esi + 0x3bb]
mov word [esi + eax*8 + 0x14], cx
movzx eax, byte [esi + 0x3bb]
mov byte [esi + eax*8 + 0x16], cl
lea eax, [ecx + 1]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x3d
jne 0x10022eda
test ecx, ecx
je 0x10022eca
cmp byte [esi + 0x364], 0
je 0x10022ec1
cmp byte [esi + 0x3bf], 0
jne 0x10022ec1
mov byte [eax], 0x5f
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov byte [esi + 0x3bf], 1
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x2b
jne 0x10022eef
test ecx, ecx
jne 0x10022ec1
pop edi
pop esi
mov byte [eax], 0x20
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x2f
jne case.default.0x10022dfd
cmp byte [esi + 0x364], 0
jne 0x10022ec1
pop edi
mov byte [esi + 0x3bc], 1
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x2f
je 0x10023109
cmp bh, 0x2e
jne 0x10022f32
pop edi
mov byte [esi + 0x3bc], 2
mov eax, 1
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3bc], 0
jmp case.default.0x10022dfd
cmp bh, 0x2e
jne 0x10022f56
pop edi
mov byte [esi + 0x3bc], 3
mov eax, 1
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp bh, 0x2f
jne 0x10022f6e
pop edi
mov byte [esi + 0x3bc], 1
mov eax, 1
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x2e
push edi
mov byte [esi + 0x3bc], 0
call fcn.10022030
add esp, 8
test eax, eax
js 0x1002308b
jmp case.default.0x10022dfd
cmp bh, 0x2f
je 0x10022fcd
cmp bh, 0x3f
je 0x10022fcd
push 0x2e
push edi
call fcn.10022030
add esp, 8
test eax, eax
js 0x1002308b
push 0x2e
push edi
call fcn.10022030
add esp, 8
test eax, eax
js 0x1002308b
pop edi
mov byte [esi + 0x3bc], 0
xor eax, eax
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov bl, byte [esi + 0x3bb]
movzx eax, bl
cmp word [esi + eax*8 + 0x14], 2
lea ecx, [esi + eax*8]
jbe 0x10023031
dec dword [esi + 0x39c]
lea edx, [esi + 0x14]
mov edi, dword [ebp + 0xc]
add word [ecx + 0x14], di
movzx eax, byte [esi + 0x3bb]
lea edx, [edx + eax*8]
nop dword [eax + eax]
dec dword [esi + 0x39c]
add word [edx], di
lea edx, [esi + 0x14]
mov bl, byte [esi + 0x3bb]
movzx eax, bl
cmp word [edx + eax*8], 1
lea edx, [edx + eax*8]
jbe 0x1002302e
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0x39c]
cmp byte [ecx + eax], 0x2f
jne 0x10023000
mov edi, dword [ebp + 8]
movzx eax, bl
mov byte [esi + 0x3bc], 1
cmp word [esi + eax*8 + 0x14], 1
jbe 0x10023109
cmp bh, 0x3f
jne 0x10022ec1
cmp dword [ebp - 8], 0
jne 0x10022ec1
cmp byte [esi + 0x364], 0
jne 0x10022ec1
cmp byte [esi + 0x3bd], 0
je 0x1002307c
pop edi
pop esi
mov eax, 2
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push edi
call fcn.10022030
add esp, 8
test eax, eax
jns 0x10023095
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [edi + 0x20]
mov edx, dword [ebp + 0xc]
movzx eax, byte [ecx + 0x3bb]
add word [ecx + eax*8 + 0x14], dx
mov al, byte [esi + 0x3bb]
inc al
mov byte [esi + 0x3bb], al
cmp al, 0x60
jb 0x100230c5
pop edi
pop esi
mov eax, 3
pop ebx
mov esp, ebp
pop ebp
ret
inc dword [esi + 0x39c]
mov ecx, dword [esi + 0x39c]
movzx eax, al
mov dword [esi + eax*8 + 0x10], ecx
xor ecx, ecx
movzx eax, byte [esi + 0x3bb]
mov word [esi + eax*8 + 0x14], cx
movzx eax, byte [esi + 0x3bb]
mov byte [esi + eax*8 + 0x16], cl
mov al, byte [esi + 0x3bb]
mov byte [esi + 0x3bf], cl
mov byte [esi + 0x364], al
mov byte [esi + 0x3bc], cl
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret