opsick
keys.h
Go to the documentation of this file.
1/*
2 Copyright 2020 Raphael Beck
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15*/
16
17#ifndef OPSICK_KEYS_H
18#define OPSICK_KEYS_H
19
20#ifdef __cplusplus
21extern "C" {
22#endif
23
24#include <ed25519.h>
25#include <cecies/keygen.h>
26
37
42
48{
49 char public_key_hexstr[64 + 1];
50 char private_key_hexstr[128 + 1];
51 uint8_t public_key[32];
52 uint8_t private_key[64];
53};
54
60
65void opsick_keys_get_curve448_keypair(struct cecies_curve448_keypair* out);
66
72void opsick_keys_get_public_keys_json(char* out, size_t* outlen);
73
74#ifdef __cplusplus
75} // extern "C"
76#endif
77
78#endif // OPSICK_KEYS_H
void opsick_keys_init()
void opsick_keys_get_public_keys_json(char *out, size_t *outlen)
void opsick_keys_free()
void opsick_keys_get_curve448_keypair(struct cecies_curve448_keypair *out)
void opsick_keys_get_ed25519_keypair(struct opsick_ed25519_keypair *out)
Definition: keys.h:48