martinpaljak/OpenSC — pull request #20 by hongquan (2012-04-25 08:09:37+00:00)
Title: Implementation of PUT DATA for OpenPGP card

Hi Martin,

Here is my implementation for pgp_pin_cmd(), pgp_put_data() in card-openpgp.c and do_put_data() in opensc-explorer.c, in order to support "verify" and "do_put" in opensc-explorer with respect to OpenPGP card.

My implementation of pgp_put_data just support DOs which is not in Extended header list now.

There is a question left:
The manual at http://linux.die.net/man/1/opensc-explorer says that:
"input is the filename of the source file or the literal data presented as a sequence of hexadecimal values or '"' enclosed string."
but how to distinguish filename and literal data?
For example, the user issues this command:
do_put 5F2D ABAB
How can we know if ABAB is the filename or literal data?