Hi Harald, Holger,

I've tried couple of things, here are the results:

- I've connected a osmocom-like ftdi cable and gathered a trace from there (not sure if i can somehow enable more debug msgs, haven't done any special setup, if you want me to take it with some more verbosity being set somehow - please let me know. trace is attached).

- I've put one printf() into the apdu_split_in method, it seems the buffer is somehow getting scrambled from the beginning, it shows something like:

Lukass-MacBook-Air:host lukash$ ./simtrace 
simtrace - GSM SIM and smartcard tracing
(C) 2010 by Harald Welte <laforge@gnumonks.org>

Entering main loop
unknown simtrace msg type 0xa4
apdu_split_in() reached.
APDU: a4 6f 05 9f 0f a0 c0 
apdu_split_in() reached.
apdu_split_in() reached.
.... and so on (tons of times).

so the APDUs are somehow going back and forth (as apdu_split_in is being called over and over) but simtrace is having some troubles displaying/parsing them.

I've found some more simcards behaving like this, Harald - if you want me to send you one for testing please send me your address, I'll be happy to do that - or I can bring it to 28c3 too - I'll leave that up to u.

Cheers,
Lukas

On Wed, Dec 14, 2011 at 4:45 PM, Holger Hans Peter Freyther <holger@freyther.de> wrote:
On 12/14/2011 04:07 PM, Harald Welte wrote:

>
>> Any idea what might be causing this?
>
> not really at this point.  If you have an extra simcard of that type,
> you could mail it to me and I could look into it.

Hi,

no idea if you already tried this. It appears that the communication between
phone and SIM is working (e.g. entering PIN and such), so maybe it is the
apdu_split.c in the host utility that fails to behave? You could verify that
'apdu_split_in' is called?