]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blame - include/crypto/dh.h
crypto: doc - fix separation of cipher / req API
[mirror_ubuntu-bionic-kernel.git] / include / crypto / dh.h
CommitLineData
802c7f1c
SB
1/*
2 * Diffie-Hellman secret to be used with kpp API along with helper functions
3 *
4 * Copyright (c) 2016, Intel Corporation
5 * Authors: Salvatore Benedetto <salvatore.benedetto@intel.com>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the Free
9 * Software Foundation; either version 2 of the License, or (at your option)
10 * any later version.
11 *
12 */
13#ifndef _CRYPTO_DH_
14#define _CRYPTO_DH_
15
16struct dh {
17 void *key;
18 void *p;
19 void *g;
20 unsigned int key_size;
21 unsigned int p_size;
22 unsigned int g_size;
23};
24
25int crypto_dh_key_len(const struct dh *params);
26int crypto_dh_encode_key(char *buf, unsigned int len, const struct dh *params);
27int crypto_dh_decode_key(const char *buf, unsigned int len, struct dh *params);
28
29#endif