Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hf 14a apdu -- #468

Closed
iceman1001 opened this issue Nov 10, 2017 · 6 comments
Closed

hf 14a apdu -- #468

iceman1001 opened this issue Nov 10, 2017 · 6 comments
Labels

Comments

@iceman1001
Copy link
Member

iceman1001 commented Nov 10, 2017

@merlokk

hf 14a apdu -s 0200A4040007A0000000031010

--> GetAPDUCode (sw1=104 'h', sw2=129 '\201') at emv/apduinfo.c:287 <--



(gdb) bt
#0  0xb7fdac31 in __kernel_vsyscall ()
#1  0xb6dc5ea9 in __GI_raise (sig=6) at ../sysdeps/unix/sysv/linux/raise.c:54
#2  0xb6dc7407 in __GI_abort () at abort.c:89
#3  0xb6e0137c in __libc_message (do_abort=2, fmt=0xb6ef8267 "*** %s ***: %s terminated\n") at ../sysdeps/posix/libc_fatal.c:175
#4  0xb6e916b8 in __GI___fortify_fail (msg=<optimized out>) at fortify_fail.c:37
#5  0xb6e8f8a8 in __GI___chk_fail () at chk_fail.c:28
#6  0xb6e8f088 in _IO_str_chk_overflow (fp=0xb05fe630, c=49) at vsprintf_chk.c:31
#7  0xb6e052d4 in __GI__IO_default_xsputn (f=0xb05fe630, data=0xb05fe5fe, n=2) at genops.c:455
#8  0xb6ddcc59 in _IO_vfprintf_internal (s=0xb05fe630, format=<optimized out>, ap=0xb05fe734 "") at vfprintf.c:1631
#9  0xb6e8f11d in ___vsprintf_chk (s=0xb05fe75a "8", flags=1, slen=2, format=0x81472d2 "%02X ", args=0xb05fe730 "\201") at vsprintf_chk.c:82
#10 0xb6e8f070 in ___sprintf_chk (s=0xb05fe75a "8", flags=1, slen=2, format=0x81472d2 "%02X ") at sprintf_chk.c:31
#11 0x08073687 in sprintf (__fmt=0x81472d2 "%02X ", __s=0xb05fe75a "8") at /usr/include/i386-linux-gnu/bits/stdio2.h:33
#12 GetAPDUCode (sw1=104 'h', sw2=129 '\201') at emv/apduinfo.c:287
#13 0x08073824 in GetAPDUCodeDescription (sw1=104 'h', sw2=129 '\201') at emv/apduinfo.c:313
#14 0x0807cdf1 in CmdHF14AAPDU (cmd=0xafc22934 "-s 0200A4040007A0000000031010") at cmdhf14a.c:733
#15 0x080d133a in CmdsParse (Commands=0x81a6160 <CommandTable>, Cmd=<optimized out>) at cmdparser.c:66
#16 0x0807cf19 in CmdHF14A (Cmd=0xafc2292f "apdu -s 0200A4040007A0000000031010") at cmdhf14a.c:942
#17 0x080d133a in CmdsParse (Commands=0x81a6040 <CommandTable>, Cmd=<optimized out>) at cmdparser.c:66
#18 0x0807a889 in CmdHF (Cmd=0xafc2292b "14a apdu -s 0200A4040007A0000000031010") at cmdhf.c:1092
#19 0x080d133a in CmdsParse (Commands=0x81a7a80 <CommandTable>, Cmd=<optimized out>) at cmdparser.c:66
#20 0x080d1b41 in CommandReceived (Cmd=0xafc22928 "hf 14a apdu -s 0200A4040007A0000000031010") at cmdmain.c:188

@iceman1001 iceman1001 added the bug label Nov 10, 2017
@iceman1001
Copy link
Member Author

@pwpiwi
Copy link
Contributor

pwpiwi commented Nov 10, 2017

Indeed. Did coverty find this?

@iceman1001
Copy link
Member Author

nop. That would be me. Wanting to test APDU and managed to trigger it when on a linux box which has gdb :)
I will need to send these into coverty after the other PR gets merged and I mangle it into my fork. What a time to be alive in the proxmark world. Emv, Apdu, felica, ...

@merlokk
Copy link
Contributor

merlokk commented Nov 10, 2017

strange. there are two uint8: (uint8_t sw1, uint8_t sw2)
i can raise size of buffer, but 2 uint8 in hex = 4 symbols.

@iceman1001
Copy link
Member Author

and you have spaces inside? and a \0 string terminator`?

@merlokk
Copy link
Contributor

merlokk commented Nov 10, 2017

maybe space for string terminator. yes, thanks

iceman1001 added a commit that referenced this issue Nov 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants