Do not expose json_object in luks2.h.

Later we can use different implementation of JSON parser.
Also define structs in one place.
This commit is contained in:
Milan Broz
2020-07-04 11:31:12 +02:00
parent 281dd51f5a
commit 08cb76bbfd

View File

@@ -59,9 +59,10 @@
#define LUKS2_REENCRYPT_MAX_HOTZONE_LENGTH 0x40000000 #define LUKS2_REENCRYPT_MAX_HOTZONE_LENGTH 0x40000000
struct device; struct device;
struct json_object;
struct luks2_reenc_context; struct luks2_reenc_context;
struct crypt_lock_handle; struct crypt_lock_handle;
struct crypt_dm_active_device;
struct luks_phdr; /* LUKS1 for conversion */
/* /*
* LUKS2 header on-disk. * LUKS2 header on-disk.
@@ -107,7 +108,7 @@ struct luks2_hdr {
uint8_t salt1[LUKS2_SALT_L]; uint8_t salt1[LUKS2_SALT_L];
uint8_t salt2[LUKS2_SALT_L]; uint8_t salt2[LUKS2_SALT_L];
char uuid[LUKS2_UUID_L]; char uuid[LUKS2_UUID_L];
struct json_object *jobj; void *jobj;
}; };
struct luks2_keyslot_params { struct luks2_keyslot_params {
@@ -330,8 +331,6 @@ int LUKS2_activate_multi(struct crypt_device *cd,
uint64_t device_size, uint64_t device_size,
uint32_t flags); uint32_t flags);
struct crypt_dm_active_device;
int LUKS2_deactivate(struct crypt_device *cd, int LUKS2_deactivate(struct crypt_device *cd,
const char *name, const char *name,
struct luks2_hdr *hdr, struct luks2_hdr *hdr,
@@ -399,7 +398,6 @@ int LUKS2_volume_key_load_in_keyring_by_keyslot(struct crypt_device *cd,
int LUKS2_volume_key_load_in_keyring_by_digest(struct crypt_device *cd, int LUKS2_volume_key_load_in_keyring_by_digest(struct crypt_device *cd,
struct luks2_hdr *hdr, struct volume_key *vk, int digest); struct luks2_hdr *hdr, struct volume_key *vk, int digest);
struct luks_phdr;
int LUKS2_luks1_to_luks2(struct crypt_device *cd, int LUKS2_luks1_to_luks2(struct crypt_device *cd,
struct luks_phdr *hdr1, struct luks_phdr *hdr1,
struct luks2_hdr *hdr2); struct luks2_hdr *hdr2);