Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: binary MIME-Version: 1.0 X-Mailer: MIME-tools 5.420 (Entity 5.420) RT-Send-CC: X-RT-Original-Encoding: iso-8859-1 Content-Length: 304 I am confused about the handling of KRB5_KDB_SALTTYPE_ONLYREALM. You appear to be leaving the type alone and filling in the contents with the realm from the source principal name. But get_salt_from_key will ignore the contents when it sees that salt type, so setting the contents won't have any effect.