ndn-lite
sign-on-basic-ecc-256-consts.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) Edward Lu
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v3.0. See the file LICENSE in the top level
6  * directory for more details.
7  *
8  * See AUTHORS.md for complete list of NDN IOT PKG authors and contributors.
9  */
10 
11 #ifndef SIGN_ON_BASIC_ECC_256_CONSTS_H
12 #define SIGN_ON_BASIC_ECC_256_CONSTS_H
13 
14 // I will just put a description of the ECC_256 variant of the sign-on protocol below:
15 //
16 //The main variance in the sign-on protocol comes from the different possible security implementations.
17 //This is reflected in how there is a generic security interface in the sign-on-basic-client.h file,
18 //which can be changed out for different backend implementations depending on the variant that is
19 //selected and the security libraries that are available on whatever system the sign-on protocol is being
20 //run on.
21 //
22 //The ways in which the sign-on protocol can vary in terms of the security implementation is summarized
23 //within the sign_on_basic_sec_intf object in sign-on-basic-client.h.
24 //
25 //The ECC_256 variant of the sign-on protocol uses elliptic curve cryptography for its backend (as opposed to
26 //RSA). As such, in the diffie hellman exchange of the protocol, ECDH rather than standard diffie hellman is used.
27 //
28 //The curves used for both generating the tokens for diffie hellman (called N1pub and N1pri for the client) and
29 //the KD pub that the client generates both use the secp256_r1 curve as defined by NIST.
30 //
31 //The other main way that the sign-on protocol variants can change is in the size of the sign on code, which
32 //again you can look at sign-on-basic-client.h for more information on.
33 
34 #define SIGN_ON_BASIC_ECC_256_SECURE_SIGN_ON_CODE_LENGTH 16
35 
36 #define SIGN_ON_BASIC_ECC_256_KD_PRI_RAW_LENGTH 32
37 
38 #endif // SIGN_ON_BASIC_ECC_256_CONSTS_H