Simulated product dispenser

Dependencies:   HTS221

Fork of mbed-cloud-workshop-connect-HTS221 by Jim Carver

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers fcc_bundle_fields.h Source File

fcc_bundle_fields.h

00001 // ----------------------------------------------------------------------------
00002 // Copyright 2016-2017 ARM Ltd.
00003 //  
00004 // Licensed under the Apache License, Version 2.0 (the "License");
00005 // you may not use this file except in compliance with the License.
00006 // You may obtain a copy of the License at
00007 //  
00008 //     http://www.apache.org/licenses/LICENSE-2.0
00009 //  
00010 // Unless required by applicable law or agreed to in writing, software
00011 // distributed under the License is distributed on an "AS IS" BASIS,
00012 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 // See the License for the specific language governing permissions and
00014 // limitations under the License.
00015 // ----------------------------------------------------------------------------
00016 
00017 #ifndef __FCC_BUNDLE_FIELDS_H__
00018 #define __FCC_BUNDLE_FIELDS_H__
00019 
00020 
00021 #ifdef __cplusplus
00022 extern "C" {
00023 #endif
00024 
00025 /**
00026 * @file fcc_bundle_handler.h
00027 *  \brief Defines for the bundles sent between the FCU and FCC 
00028 * This layer handles a device configuration bundle created by factory configurator utility (FCU).
00029 */
00030 
00031 
00032 /**
00033 * Names of key parameters
00034 */
00035 #define FCC_BUNDLE_DATA_PARAMETER_NAME                  "Name"
00036 #define FCC_BUNDLE_DATA_PARAMETER_SCHEME                "Type"
00037 #define FCC_BUNDLE_DATA_PARAMETER_FORMAT                "Format"
00038 #define FCC_BUNDLE_DATA_PARAMETER_DATA                  "Data"
00039 #define FCC_BUNDLE_DATA_PARAMETER_ACL                   "ACL"
00040 #define FCC_BUNDLE_DATA_PARAMETER_ARRAY                 "DataArray"
00041 #define FCC_BUNDLE_DATA_PARAMETER_PRIVATE_KEY_NAME      "PrKN"
00042 /**
00043 * Names of data formats
00044 */
00045 #define FCC_BUNDLE_DER_DATA_FORMAT_NAME  "der"
00046 #define FCC_BUNDLE_PEM_DATA_FORMAT_NAME   "pem"
00047 
00048 
00049 /****************************************/
00050 /* Inbound Message Main CBOR Map Groups */
00051 /****************************************/
00052 
00053 /**
00054 * Name of keys group.
00055 */
00056 #define FCC_KEY_GROUP_NAME                   "Keys"
00057 /**
00058 * Name of certificates group
00059 */
00060 #define FCC_CERTIFICATE_GROUP_NAME           "Certificates"
00061 /**
00062 * Name of configuration parameters group.
00063 */
00064 #define FCC_CONFIG_PARAM_GROUP_NAME           "ConfigParams"
00065 /**
00066 * Name of certificate chain group.
00067 */
00068 #define FCC_CERTIFICATE_CHAIN_GROUP_NAME       "CertificateChains"
00069 /**
00070 * Name of scheme version group.
00071 */
00072 #define FCC_BUNDLE_SCHEME_GROUP_NAME          "SchemeVersion"
00073 /**
00074 * Name of keep alive session group.
00075 */
00076 #define FCC_KEEP_ALIVE_SESSION_GROUP_NAME          "KpAlvSess"
00077 /**
00078 * Name of Entropy group.
00079 */
00080 #define FCC_ENTROPY_NAME       "Entropy"
00081 /**
00082 * Name of RoT group.
00083 */
00084 #define FCC_ROT_NAME          "ROT"
00085 /**
00086 * Name of device verify readiness group.
00087 */
00088 #define FCC_VERIFY_DEVICE_IS_READY_GROUP_NAME          "Verify"
00089 /**
00090 * Name of device verify readiness group.
00091 */
00092 #define FCC_FACTORY_DISABLE_GROUP_NAME          "Disable"
00093 
00094 /**
00095 * Name of FCU session ID group (optional).
00096 */
00097 #define FCC_FCU_SESSION_ID_GROUP_TYPE_NAME          "SID"
00098 
00099 /** Name of CSR requests group.
00100 */
00101 #define FCC_CSR_REQUESTS_GROUP_NAME            "CsrReqs"
00102 
00103 /************************************************/
00104 /* Inbound Message: fields within CsrReqs Group */
00105 /************************************************/
00106 
00107 /**
00108 * Name of private key name field, within CSR Requests group
00109 */
00110 #define FCC_CSRREQ_INBOUND_PRIVATE_KEY_NAME "PrKN"
00111 
00112 /**
00113 * Name of public key name field, within CSR Requests group
00114 */
00115 #define FCC_CSRREQ_INBOUND_PUBLIC_KEY_NAME "PbKN"
00116 
00117 /**
00118 * Name of Extensions field, within CSR Requests group
00119 */
00120 #define FCC_CSRREQ_INBOUND_EXTENSIONS_NAME "Ext"
00121 
00122 /**
00123 * Name of Subject field, within CSR Requests group
00124 */
00125 #define FCC_CSRREQ_INBOUND_SUBJECT_NAME "Subj"
00126 
00127 /**
00128 * Name of Message digest field, within CSR Requests group
00129 */
00130 #define FCC_CSRREQ_INBOUND_MESSAGEDIGEST_NAME "MD"
00131 
00132 
00133 /**********************************************************************/
00134 /* Inbound Message: fields within Extensions map within CsrReqs Group */
00135 /**********************************************************************/
00136 
00137 /**
00138 * Name of Trust field within Extensions
00139 */
00140 #define FCC_CSRREQ_INBOUND_EXTENSION_TRUSTLEVEL_NAME "Trust"
00141 
00142 /**
00143 * Name of Key Usage field within Extensions
00144 */
00145 #define FCC_CSRREQ_INBOUND_EXTENSION_KEYUSAGE_NAME "KU"
00146 
00147 /**
00148 * Name of Extended Key Usage field within Extensions
00149 */
00150 #define FCC_CSRREQ_INBOUND_EXTENSION_EXTENDEDKEYUSAGE_NAME "EKU"
00151 
00152 /****************************************/
00153 /* Outbound Message Main CBOR Map Groups */
00154 /****************************************/
00155 
00156 /**
00157 * Name of error info group.
00158 */
00159 //Fixme : rename "infoMessage" to ErrorInfo" when Factory tool will be ready for the change
00160 #define FCC_ERROR_INFO_GROUP_NAME              "InfoMessage"
00161 
00162 /**
00163 * Name of return status group.
00164 */
00165 #define FCC_RETURN_STATUS_GROUP_NAME          "ReturnStatus"
00166 
00167 /**
00168 * Name of warning info group.
00169 */
00170 #define FCC_WARNING_INFO_GROUP_NAME            "WarningInfo"
00171 
00172 /**
00173 * Name of CSRs group.
00174 */
00175 #define FCC_CSR_OUTBOUND_GROUP_NAME                "Csrs"
00176 
00177 
00178 /***********************************************************/
00179 /* Outbound Message: fields the CSR maps within Csrs array */
00180 /***********************************************************/
00181 
00182 /**
00183 * Name of the private key corresponding to the CSR within the CSR map.
00184 */
00185 #define FCC_CSR_OUTBOUND_MAP_PRIVATE_KEY_NAME FCC_CSRREQ_INBOUND_PRIVATE_KEY_NAME
00186 
00187 /**
00188 * Name of the data of the CSR within the CSR map.
00189 */
00190 #define FCC_CSR_OUTBOUND_MAP_DATA FCC_BUNDLE_DATA_PARAMETER_DATA
00191 
00192 
00193 #ifdef __cplusplus
00194 }
00195 #endif
00196 
00197 #endif //__FCC_BUNDLE_FIELDS_H__