Add support for writing to KDB and dumping HDB to MIT KDB dump format
commit57f1545a46fdad9207a71903a56f3c1d1fff3a10
authorNicolas Williams <nico@cryptonector.com>
Mon, 30 Apr 2012 08:28:00 +0000 (30 03:28 -0500)
committerNicolas Williams <nico@cryptonector.com>
Thu, 3 May 2012 19:24:18 +0000 (3 14:24 -0500)
treed0bfa3700c8907277f30617c7bffda4872cdcf93
parent6c4764fbc7169b23a5d60004eb82edc0fe12197a
Add support for writing to KDB and dumping HDB to MIT KDB dump format

    Before this change Heimdal could read KDBs.  Now it can write to
    them too.

    Heimdal can now also dump HDBs (including KDBs) in MIT format, which
    can then be imported with kdb5_util load.

    This is intended to help in migrations from MIT to Heimdal by
    allowing migrations from Heimdal to MIT so that it is possible
    to rollback from Heimdal to MIT should there be any issues.  The
    idea is to allow a) running Heimdal kdc/kadmind with a KDB, or
    b) running Heimdal with an HDB converted from a KDB and then
    rollback by dumping the HDB and loading a KDB.

    Note that not all TL data types are supported, only two: last
    password change and modify-by.  This is the minimum necessary.
    PKINIT users may need to add support for KRB5_TL_USER_CERTIFICATE,
    and for databases with K/M history we may need to add KRB5_TL_MKVNO
    support.

    Support for additional TL data types can be added in
    lib/hdb/hdb-mitdb.c:_hdb_mdb_value2entry() and
    lib/hdb/print.c:entry2mit_string_int().
kadmin/dump.c
kadmin/kadmin-commands.in
kdc/hpropd.c
kdc/mit_dump.c
lib/hdb/ext.c
lib/hdb/hdb-mitdb.c
lib/hdb/hdb.h
lib/hdb/mkey.c
lib/hdb/print.c
lib/hdb/version-script.map