Changeset 32d035a in OpenSC


Ignore:
Timestamp:
06/05/11 15:13:06 (12 months ago)
Author:
vtarasov <vtarasov@…>
Branches:
master, staging
Children:
d888b3f
Parents:
f45f22c
git-author:
vtarasov <vtarasov@…> (06/05/11 15:13:06)
git-committer:
vtarasov <vtarasov@…> (06/05/11 15:13:06)
Message:

AuthentIC: when returning PIN info set the 'tries-left' data to the 'non-initialized' value

git-svn-id:  https://www.opensc-project.org/svnp/opensc/trunk@5549 c6295689-39f2-0310-b995-f0e70906c6a9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/libopensc/card-authentic.c

    rda0a77b r32d035a  
    15551555 
    15561556        LOG_FUNC_CALLED(ctx); 
    1557         sc_log(ctx, "get PIN(type:%X,ref:%X)", data->pin_type, data->pin_reference); 
     1557        sc_log(ctx, "get PIN(type:%X,ref:%X,tries-left:%i)", data->pin_type, data->pin_reference, data->pin1.tries_left); 
    15581558   
    15591559        sc_format_apdu(card, &apdu, SC_APDU_CASE_2_SHORT, 0xCA, 0x5F, data->pin_reference); 
     
    15741574        LOG_TEST_RET(ctx, rv, "'GET DATA' error"); 
    15751575 
     1576        data->pin1.tries_left = -1; 
     1577 
    15761578        rv = authentic_parse_credential_data(ctx, data, apdu.resp, apdu.resplen); 
    15771579        LOG_TEST_RET(ctx, rv, "Cannot parse credential data"); 
     
    16111613        pin_cmd.pin_reference = data->pin_reference; 
    16121614        pin_cmd.pin_type = data->pin_type; 
     1615        pin_cmd.pin1.tries_left = -1; 
    16131616 
    16141617        rv = authentic_pin_get_policy(card, &pin_cmd); 
     
    16891692 
    16901693        LOG_FUNC_CALLED(ctx); 
    1691         sc_log(ctx, "PIN-CMD:%X,PIN(type:%X,ret:%i),PIN1(%p,len:%i),PIN2(%p,len:%i)", data->cmd, data->pin_type,  
    1692                         data->pin_reference, data->pin1.data, data->pin1.len, data->pin2.data, data->pin2.len); 
     1694        sc_log(ctx, "PIN-CMD:%X,PIN(type:%X,ret:%i)", data->cmd, data->pin_type, data->pin_reference); 
     1695        sc_log(ctx, "PIN1(%p,len:%i,tries-left:%i)", data->pin1.data, data->pin1.len, data->pin1.tries_left); 
     1696        sc_log(ctx, "PIN2(%p,len:%i)", data->pin2.data, data->pin2.len); 
    16931697   
    16941698        switch (data->cmd)   { 
Note: See TracChangeset for help on using the changeset viewer.