/* These must match the values in hdb.h */
-#define SDB_F_DECRYPT 1 /* decrypt keys */
-#define SDB_F_GET_CLIENT 4 /* fetch client */
-#define SDB_F_GET_SERVER 8 /* fetch server */
-#define SDB_F_GET_KRBTGT 16 /* fetch krbtgt */
-#define SDB_F_GET_ANY 28 /* fetch any of client,server,krbtgt */
-#define SDB_F_CANON 32 /* want canonicalization */
-#define SDB_F_ADMIN_DATA 64 /* want data that kdc don't use */
-#define SDB_F_KVNO_SPECIFIED 128 /* we want a particular KVNO */
-#define SDB_F_FOR_AS_REQ 4096 /* fetch is for a AS REQ */
-#define SDB_F_FOR_TGS_REQ 8192 /* fetch is for a TGS REQ */
-#define SDB_F_ARMOR_PRINCIPAL 262144 /* fetch is for the client of an armor ticket */
-#define SDB_F_USER2USER_PRINCIPAL 524288/* fetch is for the server of a user2user tgs-req */
+#define SDB_F_DECRYPT 0x00001 /* decrypt keys */
+#define SDB_F_REPLACE 0x00002 /* replace entry */
+#define SDB_F_GET_CLIENT 0x00004 /* fetch client */
+#define SDB_F_GET_SERVER 0x00008 /* fetch server */
+#define SDB_F_GET_KRBTGT 0x00010 /* fetch krbtgt */
+#define SDB_F_GET_ANY ( SDB_F_GET_CLIENT | \
+ SDB_F_GET_SERVER | \
+ SDB_F_GET_KRBTGT ) /* fetch any of client,server,krbtgt */
+#define SDB_F_CANON 0x00020 /* want canonicalition */
+#define SDB_F_ADMIN_DATA 0x00040 /* want data that kdc don't use */
+#define SDB_F_KVNO_SPECIFIED 0x00080 /* we want a particular KVNO */
+#define SDB_F_FOR_AS_REQ 0x01000 /* fetch is for a AS REQ */
+#define SDB_F_FOR_TGS_REQ 0x02000 /* fetch is for a TGS REQ */
+#define SDB_F_ARMOR_PRINCIPAL 0x40000 /* fetch is for the client of an armor ticket */
+#define SDB_F_USER2USER_PRINCIPAL 0x80000 /* fetch is for the server of a user2user tgs-req */
#define SDB_F_HDB_MASK (SDB_F_DECRYPT | \
SDB_F_GET_CLIENT| \
SDB_F_USER2USER_PRINCIPAL)
/* These are not supported by HDB */
-#define SDB_F_FORCE_CANON 16384 /* force canonicalization */
-#define SDB_F_RODC_NUMBER_SPECIFIED 32768 /* we want a particular RODC number */
+#define SDB_F_FORCE_CANON 0x4000 /* force canonicalization */
+#define SDB_F_RODC_NUMBER_SPECIFIED 0x8000 /* we want a particular RODC number */
void sdb_key_free(struct sdb_key *key);
void sdb_keys_free(struct sdb_keys *keys);