xref: /openbmc/bmcweb/features/redfish/include/generated/enums/key.hpp (revision 2ae81db99a155febe45d27e3834cfa5471b3ecdf)
1853c0dc5SEd Tanous #pragma once
2853c0dc5SEd Tanous #include <nlohmann/json.hpp>
3853c0dc5SEd Tanous 
4853c0dc5SEd Tanous namespace key
5853c0dc5SEd Tanous {
6853c0dc5SEd Tanous // clang-format off
7853c0dc5SEd Tanous 
8*2ae81db9SGunnar Mills enum class SSHKeyType{
9*2ae81db9SGunnar Mills     Invalid,
10*2ae81db9SGunnar Mills     RSA,
11*2ae81db9SGunnar Mills     DSA,
12*2ae81db9SGunnar Mills     ECDSA,
13*2ae81db9SGunnar Mills     Ed25519,
14*2ae81db9SGunnar Mills };
15*2ae81db9SGunnar Mills 
16*2ae81db9SGunnar Mills enum class ECDSACurveType{
17*2ae81db9SGunnar Mills     Invalid,
18*2ae81db9SGunnar Mills     NISTP256,
19*2ae81db9SGunnar Mills     NISTP384,
20*2ae81db9SGunnar Mills     NISTP521,
21*2ae81db9SGunnar Mills     NISTK163,
22*2ae81db9SGunnar Mills     NISTP192,
23*2ae81db9SGunnar Mills     NISTP224,
24*2ae81db9SGunnar Mills     NISTK233,
25*2ae81db9SGunnar Mills     NISTB233,
26*2ae81db9SGunnar Mills     NISTK283,
27*2ae81db9SGunnar Mills     NISTK409,
28*2ae81db9SGunnar Mills     NISTB409,
29*2ae81db9SGunnar Mills     NISTT571,
30*2ae81db9SGunnar Mills };
31*2ae81db9SGunnar Mills 
32853c0dc5SEd Tanous enum class KeyType{
33853c0dc5SEd Tanous     Invalid,
34853c0dc5SEd Tanous     NVMeoF,
35853c0dc5SEd Tanous     SSH,
36853c0dc5SEd Tanous };
37853c0dc5SEd Tanous 
38853c0dc5SEd Tanous enum class NVMeoFSecurityProtocolType{
39853c0dc5SEd Tanous     Invalid,
40853c0dc5SEd Tanous     DHHC,
41853c0dc5SEd Tanous     TLS_PSK,
42853c0dc5SEd Tanous     OEM,
43853c0dc5SEd Tanous };
44853c0dc5SEd Tanous 
45853c0dc5SEd Tanous enum class NVMeoFSecureHashType{
46853c0dc5SEd Tanous     Invalid,
47853c0dc5SEd Tanous     SHA256,
48853c0dc5SEd Tanous     SHA384,
49853c0dc5SEd Tanous     SHA512,
50853c0dc5SEd Tanous };
51853c0dc5SEd Tanous 
52*2ae81db9SGunnar Mills NLOHMANN_JSON_SERIALIZE_ENUM(SSHKeyType, {
53*2ae81db9SGunnar Mills     {SSHKeyType::Invalid, "Invalid"},
54*2ae81db9SGunnar Mills     {SSHKeyType::RSA, "RSA"},
55*2ae81db9SGunnar Mills     {SSHKeyType::DSA, "DSA"},
56*2ae81db9SGunnar Mills     {SSHKeyType::ECDSA, "ECDSA"},
57*2ae81db9SGunnar Mills     {SSHKeyType::Ed25519, "Ed25519"},
58*2ae81db9SGunnar Mills });
59*2ae81db9SGunnar Mills 
60*2ae81db9SGunnar Mills NLOHMANN_JSON_SERIALIZE_ENUM(ECDSACurveType, {
61*2ae81db9SGunnar Mills     {ECDSACurveType::Invalid, "Invalid"},
62*2ae81db9SGunnar Mills     {ECDSACurveType::NISTP256, "NISTP256"},
63*2ae81db9SGunnar Mills     {ECDSACurveType::NISTP384, "NISTP384"},
64*2ae81db9SGunnar Mills     {ECDSACurveType::NISTP521, "NISTP521"},
65*2ae81db9SGunnar Mills     {ECDSACurveType::NISTK163, "NISTK163"},
66*2ae81db9SGunnar Mills     {ECDSACurveType::NISTP192, "NISTP192"},
67*2ae81db9SGunnar Mills     {ECDSACurveType::NISTP224, "NISTP224"},
68*2ae81db9SGunnar Mills     {ECDSACurveType::NISTK233, "NISTK233"},
69*2ae81db9SGunnar Mills     {ECDSACurveType::NISTB233, "NISTB233"},
70*2ae81db9SGunnar Mills     {ECDSACurveType::NISTK283, "NISTK283"},
71*2ae81db9SGunnar Mills     {ECDSACurveType::NISTK409, "NISTK409"},
72*2ae81db9SGunnar Mills     {ECDSACurveType::NISTB409, "NISTB409"},
73*2ae81db9SGunnar Mills     {ECDSACurveType::NISTT571, "NISTT571"},
74*2ae81db9SGunnar Mills });
75*2ae81db9SGunnar Mills 
76853c0dc5SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(KeyType, {
77853c0dc5SEd Tanous     {KeyType::Invalid, "Invalid"},
78853c0dc5SEd Tanous     {KeyType::NVMeoF, "NVMeoF"},
79853c0dc5SEd Tanous     {KeyType::SSH, "SSH"},
80853c0dc5SEd Tanous });
81853c0dc5SEd Tanous 
82853c0dc5SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(NVMeoFSecurityProtocolType, {
83853c0dc5SEd Tanous     {NVMeoFSecurityProtocolType::Invalid, "Invalid"},
84853c0dc5SEd Tanous     {NVMeoFSecurityProtocolType::DHHC, "DHHC"},
85853c0dc5SEd Tanous     {NVMeoFSecurityProtocolType::TLS_PSK, "TLS_PSK"},
86853c0dc5SEd Tanous     {NVMeoFSecurityProtocolType::OEM, "OEM"},
87853c0dc5SEd Tanous });
88853c0dc5SEd Tanous 
89853c0dc5SEd Tanous NLOHMANN_JSON_SERIALIZE_ENUM(NVMeoFSecureHashType, {
90853c0dc5SEd Tanous     {NVMeoFSecureHashType::Invalid, "Invalid"},
91853c0dc5SEd Tanous     {NVMeoFSecureHashType::SHA256, "SHA256"},
92853c0dc5SEd Tanous     {NVMeoFSecureHashType::SHA384, "SHA384"},
93853c0dc5SEd Tanous     {NVMeoFSecureHashType::SHA512, "SHA512"},
94853c0dc5SEd Tanous });
95853c0dc5SEd Tanous 
96853c0dc5SEd Tanous }
97853c0dc5SEd Tanous // clang-format on
98