Top |
JcatContext * | jcat_context_new () |
void | jcat_context_add_public_key () |
void | jcat_context_add_public_keys () |
JcatEngine * | jcat_context_get_engine () |
void | jcat_context_set_keyring_path () |
const gchar * | jcat_context_get_keyring_path () |
JcatResult * | jcat_context_verify_blob () |
GPtrArray * | jcat_context_verify_item () |
GPtrArray * | jcat_context_verify_target () |
void | jcat_context_blob_kind_allow () |
void | jcat_context_blob_kind_disallow () |
void jcat_context_add_public_key (JcatContext *self
,const gchar *filename
);
Adds a single public key.
Since: 0.1.0
void jcat_context_add_public_keys (JcatContext *self
,const gchar *path
);
Adds a public key directory.
Since: 0.1.0
JcatEngine * jcat_context_get_engine (JcatContext *self
,JcatBlobKind kind
,GError **error
);
Gets the engine for a specific engine kind, setting up the context automatically if required.
Since: 0.1.0
void jcat_context_set_keyring_path (JcatContext *self
,const gchar *path
);
Sets the local state directory for the engines to use.
Since: 0.1.0
const gchar *
jcat_context_get_keyring_path (JcatContext *self
);
Gets the local state directory the engines are using.
Since: 0.1.0
JcatResult * jcat_context_verify_blob (JcatContext *self
,GBytes *data
,JcatBlob *blob
,JcatVerifyFlags flags
,GError **error
);
Verifies a JcatBlob using the public keys added to the context.
Since: 0.1.0
GPtrArray * jcat_context_verify_item (JcatContext *self
,GBytes *data
,JcatItem *item
,JcatVerifyFlags flags
,GError **error
);
Verifies a JcatItem using the public keys added to the context. All
verify=CHECKSUM
engines (e.g. SHA256) must verify correctly,
but only one non-checksum signature has to verify.
Since: 0.1.0
GPtrArray * jcat_context_verify_target (JcatContext *self
,JcatItem *item_target
,JcatItem *item
,JcatVerifyFlags flags
,GError **error
);
Verifies a JcatItem using the target to an item. At least one verify=CHECKSUM
(e.g. SHA256)
must exist and all checksum types that do exist must verify correctly.
self |
||
item_target |
JcatItem containing checksums of the data |
|
item |
||
flags |
||
error |
GError, or |
Since: 0.2.0
void jcat_context_blob_kind_allow (JcatContext *self
,JcatBlobKind kind
);
Adds a blob kind to the allowlist. By default, JCat will use all signature and checksum schemes
compiled in at build time. Once this function has been called only specific blob kinds will be
used in functions like jcat_context_verify_blob()
.
Since: 0.1.12
void jcat_context_blob_kind_disallow (JcatContext *self
,JcatBlobKind kind
);
Removes a blob kind from the allowlist. By default, JCat will use all signature and checksum
schemes compiled in at build time. Once this function has been called this kind
will not be
used in functions like jcat_context_verify_blob()
.
Since: 0.1.12