sxt: added skel for sxtkeys;
parent
9e541bc4aa
commit
8d1e8591cf
@ -0,0 +1,50 @@
|
||||
/*
|
||||
* Secure eXtended Message Passing framework
|
||||
* Secure eXtended Transport layer implementation: (libsxt)
|
||||
* - very similar to SSH2/TLS
|
||||
* - using already proven and tested crypto algos
|
||||
* - better than TLS for message passing
|
||||
*
|
||||
* PublicPrivateKeyPairs operation API
|
||||
*
|
||||
* Copyright (c) 2014 by Aris Adamantiadis
|
||||
* (c) Alexander Vdolainen 2016 <avdolainen@zoho.com>
|
||||
*
|
||||
* libsxmp is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU Lesser General Public License as published
|
||||
* by the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* libsxmp is distributed in the hope that it will be useful, but
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||
* See the GNU Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.";
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __SXT_SXTKEY_H__
|
||||
#define __SXT_SXTKEY_H__
|
||||
|
||||
/* some taken code , copyright left in the header */
|
||||
#define ED25519_PK_LEN 32
|
||||
#define ED25519_SK_LEN 64
|
||||
#define ED25519_SIG_LEN 64
|
||||
|
||||
typedef uint8_t ed25519_pubkey[ED25519_PK_LEN];
|
||||
typedef uint8_t ed25519_privkey[ED25519_SK_LEN];
|
||||
typedef uint8_t ed25519_signature[ED25519_SIG_LEN];
|
||||
|
||||
/* here the supported types in SXT */
|
||||
#define PPKP_ED25519 0xa
|
||||
|
||||
typedef struct sxtkey_type {
|
||||
uint8_t type;
|
||||
uint8_t flags;
|
||||
ed25519_pubkey pubkey;
|
||||
ed25519_privkey privkey;
|
||||
} sxtkey_t;
|
||||
|
||||
#endif /* __SXT_SXTKEY_H__ */
|
Loading…
Reference in New Issue