In the case of an IC card having a decoding key for decoding data and an
encoding key for encoding the data which are generated inside or set by
an external unit, when a key takeout instruction for taking out the
decoding key and encoding key in the IC card to an external unit is
input, the decoding key and encoding key are encoded by a plurality of
other keys set in the IC card and then transmitted to an external unit.