gnupg: Scdaemon WRITEKEY
6.6.9 Write a key to a card
---------------------------
WRITEKEY [--force] KEYID
This command is used to store a secret key on a smartcard. The
allowed keyids depend on the currently selected smartcard application.
The actual keydata is requested using the inquiry 'KEYDATA' and need to
be provided without any protection. With '--force' set an existing key
under this KEYID will get overwritten. The key data is expected to be
the usual canonical encoded S-expression.
A PIN will be requested in most cases. This however depends on the
actual card application.