# A Framework for Constructing a Secure Domain of Sensor Nodes
## 3 The Concept of a Security Domain of Sensor Nodes
### The Concept of Protection for Sensor Nodes
#### 3.2.2 Data Stored in the Resources of the Sensor Node  
Each sensor node should be able to perform all tasks provided for nodes in the domain, and in particular, it should perform the role of Master, Gateway or both. Therefore, the resources and  
Figure 3: Block diagram of the sensor node. Arduino: single-board microcontroller; I\({}^{2}\)C: Inter-Integrated Circuit; LoRa: interface for long range wireless transmissions with low power consumption; SPI-Serial Peripheral Interface; TPM: Trusted Platform Module; XBee: interface for low range wireless transmissions;  
capabilities of each sensor node should be similar. The NVRAM of the TPM and the EEPROM of the Arduino microcontroller are intended for storing sensitive sensor node data. The NVRAM of the TPM is designed to store the sensor node's own data, including the local trust structure of the sensor node, the necessary data for domain node authentication, and cryptographic keys which are utilized to protect the data stored in the EEPROM of the node and to secure the data transmitted from that node. The microcontroller EEPROM is intended to store the description of the sensor node domain and the descriptions of registered nodes in the domain. The RAM stores the status data of registered nodes in the domain. An example of data stored on the M node and R node is shown in Figure 4.  
**The individual data of the sensor node include**  
* Asymmetric keys (EK, SRK, and DK), which creates local trust structure;
* NTAG--a unique tag generated for the node during the node preparation procedure, which is intended for one-time authentication of the node in the registration procedure of this node in the domain;
* N_ID--a sensor node identifier in the domain;
* Symmetric keys: NK--for encrypting the data stored in the EEPROM of the node (the key is used only internally by this node), NSK--for encrypting data in authenticating procedures of the node in the domain (the key is known only to this node and the M node), NTK--for encrypting transferred measurement data from the sensor node to the G node (the key is common to all nodes of the domain), NDK--for encrypting data in diagnostic procedures in the domain (the key is common to all nodes of the domain);
* Addresses in the used wireless network: NAD--own address,  
Figure 4: An example of data stored on the M node and R node. CH: Operating channel in a wireless network; DK: Domain Key; EK: Endorsement Key; GAD: Gateway Node address; MAD: Master Node address; NAD: Node address; NDK: Node Diagnostic Key; NK: Node Key; NSK: Node Secure Key; NTAG: Node tag; NTK: Node Transmission Key; PAN_ID: Identifier of personal area network; PIK: PAN Interface Key; SQ: Node sequential number; SRK: Storage Root Key; TPM: Trusted Platform Module. MAD--address of the M node, GAD--address of the G node;
* Parameters of the wireless network used in the domain: PAN_ID (ID of the Personal Area Network)--the identity of the wireless network (XBee) used in the sensors' domain, CH--operating channel in a wireless network (XBee) used in the sensors' domain, PIK (PAN Interface Key)--symmetric key used by the XBee module, common to all nodes in the PAN;
* Key_Desc--description of keys stored in the TPM non-volatile memory. **Security domain description:**  
* DN--sensors' Domain Name;
* RN (Role of Node)--defines the role of the node in the resources of which the description is stored {M, R, M+G, R+G};
* VER--the version number of the domain description;
* Periods (i.e., Period of Replication (PR), Period of Non-success Replication (PNR), and Time of data validity (TDV)) associated with the operation of R nodes. **Description of domain nodes. ** The description of each node consists of two parts.