src/pgp_netpgp.h
author Volker Birk <vb@pep-project.org>
Wed, 29 Apr 2015 14:51:33 +0200
changeset 229 313d152239bf
parent 226 a2079f2f7a8c
child 539 c8a4c7b86064
permissions -rw-r--r--
fixing preprocessor
Edouard@174
     1
#pragma once
Edouard@174
     2
Edouard@174
     3
#include "pEpEngine.h"
Edouard@174
     4
Edouard@174
     5
PEP_STATUS pgp_init(PEP_SESSION session, bool in_first);
Edouard@174
     6
void pgp_release(PEP_SESSION session, bool out_last);
Edouard@174
     7
Edouard@174
     8
PEP_STATUS pgp_decrypt_and_verify(
Edouard@174
     9
        PEP_SESSION session, const char *ctext, size_t csize,
Edouard@174
    10
        char **ptext, size_t *psize, stringlist_t **keylist
Edouard@174
    11
    );
Edouard@174
    12
Edouard@174
    13
PEP_STATUS pgp_encrypt_and_sign(
Edouard@174
    14
        PEP_SESSION session, const stringlist_t *keylist, const char *ptext,
Edouard@174
    15
        size_t psize, char **ctext, size_t *csize
Edouard@174
    16
    );
Edouard@174
    17
Edouard@174
    18
PEP_STATUS pgp_verify_text(
Edouard@174
    19
        PEP_SESSION session, const char *text, size_t size,
Edouard@174
    20
        const char *signature, size_t sig_size, stringlist_t **keylist
Edouard@174
    21
    );
Edouard@174
    22
Edouard@174
    23
PEP_STATUS pgp_delete_keypair(PEP_SESSION session, const char *fpr);
Edouard@174
    24
Edouard@179
    25
PEP_STATUS pgp_export_keydata(
Edouard@174
    26
        PEP_SESSION session, const char *fpr, char **key_data, size_t *size
Edouard@174
    27
    );
Edouard@174
    28
Edouard@174
    29
PEP_STATUS pgp_find_keys(
Edouard@174
    30
        PEP_SESSION session, const char *pattern, stringlist_t **keylist
Edouard@174
    31
    );
Edouard@174
    32
Edouard@174
    33
PEP_STATUS pgp_generate_keypair(
Edouard@174
    34
        PEP_SESSION session, pEp_identity *identity
Edouard@174
    35
    );
Edouard@174
    36
Edouard@174
    37
PEP_STATUS pgp_get_key_rating(
Edouard@174
    38
        PEP_SESSION session,
Edouard@174
    39
        const char *fpr,
Edouard@174
    40
        PEP_comm_type *comm_type
Edouard@174
    41
    );
Edouard@174
    42
Edouard@179
    43
PEP_STATUS pgp_import_keydata(PEP_SESSION session, const char *key_data,
Edouard@174
    44
        size_t size);
Edouard@174
    45
Edouard@174
    46
PEP_STATUS pgp_recv_key(PEP_SESSION session, const char *pattern);
Edouard@174
    47
PEP_STATUS pgp_send_key(PEP_SESSION session, const char *pattern);
Edouard@174
    48
Edouard@210
    49
PEP_STATUS pgp_renew_key(
Edouard@210
    50
        PEP_SESSION session,
Edouard@210
    51
        const char *fpr,
Edouard@210
    52
        const timestamp *ts
Edouard@210
    53
    );
Edouard@210
    54
Edouard@226
    55
PEP_STATUS pgp_revoke_key(
Edouard@226
    56
        PEP_SESSION session,
Edouard@226
    57
        const char *fpr,
Edouard@226
    58
        const char *reason
Edouard@226
    59
    );
Edouard@226
    60
Edouard@226
    61
PEP_STATUS pgp_key_expired(
Edouard@226
    62
        PEP_SESSION session,
Edouard@226
    63
        const char *fpr,
Edouard@226
    64
        bool *expired
Edouard@226
    65
    );
Edouard@226
    66