## 6 Future Trends and Issues
### Data Privacy and Security  
For communication between appliances and the end-user in a smart house, various wireless communication technologies have been introduced. Smart building appliances are connected to a wireless control network such as ZigBee, Bluetooth, or Wi-Fi to receive and send commands remotely or automatically. The IEEE 802.11 (Wi-Fi), IEEE 802.16 (WiMAX), IEEE 802.15.1 (Bluetooth), and IEEE 802.15.4 (Zigbee) standards are the most widely used wireless technologies in smart homes [228]. Two types of communication protocols are usually used in IoT-enabled smart infrastructure: Zigbee for device-to-device communication and Wi-Fi for device-to-AMI connectivity [105]. A brief comparison of wireless communication protocols used in HEMS is presented in Table 5.  
The emergence of intelligent cities in the world is encountered chiefly to preserve the privacy and security of data involving big data analytics. Without the authorization of the owner's privacy, accessing data generated in smart cities will not be legal. In this case, personal data acquisition can be encouraged to motivate data owners by promoting incentives via an intelligent contract that provides privacy. Estonia introduced the world's first \"data embassy\" which can be operated from data centers outside of Estonia for reliable operation and to restrict potential cyber-attacks [229].  
On top of this, the unveiling of the new innovative technology called blockchain is now the key to the data-driven world. The usage of blockchains is booming rapidly, with a market size of USD 3 billion to 39.7 billion by 2025 [1]. The integration of the constrained application protocol (CoAP) for the sending and receiving of data in IoT systems minimizes the power consumption of IoT devices with datagram transport layer protection (DTLS) security and the usage of CoAP in the intelligent building. However, that is less than the message queuing telemetry transport case (MQTT). The aim is to integrate the DTLS protocol with the secure hash algorithm (SHA-256) using optimization to improve security [230].  
The essential features of blockchain are seamless authentication, privacy, security, effortless deployment, and maintenance. Smart cities are required to modernize  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Domain** & **Goal** & **BEMS in the Pursuit of the SDGs** & **Ref.** \\ \hline Environment &
\begin{tabular}{c} **F** \\ **F** \\ **MUC** \\ **A**  
their buildings by implementing home automation with decarbonization and improved consumer security and privacy. The demonstration focuses on future energy management research by highlighting the key emerging areas, namely context-aware energy management, energy management for smart homes and grids, and the role of privacy preservation in IEMS. One paper addressed the technical challenges and possible solutions for their implementation in IEMS and also summarized the future perspectives to make the system more reliable, robust, and customized [231]. The problems in the centralized architecture of intelligent building energy management systems (IBEMS) are, namely, the difficulty of networking between end devices, the lack of flexibility, and the limited sharing of underlying information. The analysis of the formulation of a wireless sensor network (WSN) for the power supply, distribution management system, and design of a network model of the IBEMS can overcome these problems. For the security purposes of the IBEMS, a blockchain-based dynamic key management strategy was proposed, and experimental results show the reduction of data storage time and the space of sensors, which optimizes the control of the IBEMS. Moreover, research results assist in promoting blockchain technology in the scenario of Ubiquitous Power Internet of Things (UPIoT) [232]. To make a smart city where the whole area has to be digitalized by placing sensors everywhere, namely transport, e-health, agriculture, and so on, care must be taken with data privacy and security [112].