Design and Implementation of a Machine Learning-Based Adaptive IDS on Raspberry Pi for Smart Home Network Security

Ronald Adrian, R. Deasy Mandasari, Sahirul Alam

Abstract


The rapid growth of the Internet of Things (IoT) has accelerated the adoption of smart home technologies, offering convenience and automation in daily life. However, this interconnected environment increases the risk of cyber threats, making information security a pressing concern. To address this, the study presents the design and implementation of an adaptive Intrusion Detection System (IDS) based on machine learning, deployed on a Raspberry Pi platform as a low-cost, flexible, and energy-efficient solution for smart home security. Unlike traditional IDS approaches that rely on static, rule-based detection, the proposed system leverages adaptive learning algorithms to identify evolving attack patterns in real time. It integrates network traffic monitoring with carefully selected sensors and detection algorithms to improve responsiveness across various threat types from application-level exploits to network infrastructure attacks. System performance was evaluated through simulated attacks, including DDoS, brute force, and malware injection scenarios. Results show that the adaptive IDS significantly improves detection accuracy to 85%, surpassing the 65% accuracy achieved by conventional methods. The response time was also reduced from 5 seconds to just 2 seconds, demonstrating the system’s suitability for real-time threat mitigation in resource-constrained environments. The Raspberry Pi acts as the IDS host and a firewall enhancement tool, supporting custom iptables rules, whitelist-based access control, and integration with the Elastic Stack for real-time logging and visualization. The system also supports continuous learning by updating its detection models based on new traffic patterns, making it scalable and resilient to future threats. This research contributes to IoT cybersecurity by demonstrating that an adaptive, machine learning-based IDS can be effectively implemented on lightweight hardware without sacrificing performance. It offers a cost-effective and scalable solution to secure smart home networks against increasingly sophisticated cyberattacks.

Keywords: Firewall, IDS, IoT, Raspberry, Smart Home


Full Text:

PDF

References


K. Patel and H. Soni, "Internet of Things (IoT) Security: Challenges, Issues, and Solutions," IEEE Internet of Things Journal, vol. 7, no. 4, pp. 3471–3482, Apr. 2020.

A. Hodo, X. Bellekens, A. Hamilton, P. Dubouilh, and Z. Tachtatzis, "Threat Analysis of IoT Networks Using Artificial Neural Network Intrusion Detection System," in Proc. IEEE Int. Symp. Networks, Comput. and Commun., 2016, pp. 1–6.

F. A. Breve and A. P. Breve, "A Lightweight Intrusion Detection System for IoT Networks Based on Deep Learning Algorithms," IEEE Access, vol. 8, pp. 82792–82801, May 2020.

J. Paul and C. R. Chen, "An Analysis of Machine Learning Techniques for Intrusion Detection in Smart Homes," IEEE Trans. Ind. Informatics, vol. 16, no. 11, pp. 7145–7154, Nov. 2020.

M. A. Ferrag, L. Maglaras, and H. Janicke, "Deep Learning for Cybersecurity Intrusion Detection in Internet of Things: Taxonomy, Challenges, and Future Directions," IEEE Commun. Surveys Tuts., vol. 23, no. 3, pp. 1652–1680, 3rd Quart. 2021.

M. Ahmed, A. Naser, and M. Ghose, "The Effectiveness of Raspberry Pi in Cybersecurity Research," in Proc. 9th Int. Conf. Cyber Security and Privacy, 2020, pp. 124–129.

J. Zhang, Y. Yu, and C. Xu, "Real-Time Intrusion Detection for Edge Computing in IoT-Based Smart Homes Using Adaptive Machine Learning," IEEE Access, vol. 9, pp. 12356–12366, Jan. 2021.

X. Li, L. Wang, and Z. Liu, "Design and Implementation of Intrusion Detection System Using Raspberry Pi for IoT Environment," in *Proc. IEEE Int. Conf. Cloud Comput. Technol. Sci.*, 2021,

pp. 127–132.

P. Patel and A. Bansal, "Machine Learning-Based IDS on IoT Platform for Enhanced Security," IEEE Int. Things J., vol. 8, no. 7, pp. 5531–5538, Apr. 2021.

S. Kumar and R. Gupta, "An Adaptive Security Framework for IoT Devices in Smart Home Networks," IEEE Trans. Emerg. Top. Comput., vol. 9, no. 4, pp. 1920–1932, Oct.–Dec. 2021.

A. A. Cardenas, J. P. Munoz, and N. E. Wright, "A Framework for Evaluating the Performance of IoT Intrusion Detection Systems," in Proc. IEEE Conf. Commun. Netw. Secur., 2022, pp. 1–7.

Y. Huang, Y. Ye, and H. Huang, "Intrusion Detection in Internet of Things via Machine Learning: A Survey," IEEE Access, vol. 9, pp. 2961–2973, Jan. 2021.

W. Wang, C. Wang, and Y. Cui, "Security Analysis and Enhancement for IoT Networks Using Raspberry Pi-Based IDS," in Proc. Int. Conf. Inf. Syst. Security Privacy, 2021, pp. 117–124.

B. Prakash and V. Alagarsamy, "Comparative Analysis of IDS for IoT Applications on Edge Computing Devices," IEEE Syst. J., vol. 15, no. 2, pp. 2348–2356, Jun. 2021.

D. Wu and S. Zhu, "An Overview of Machine Learning Approaches for Intrusion Detection in IoT Networks," IEEE Trans. Ind. Informatics, vol. 18, no. 1, pp. 452–465, Jan. 2022.

H. Zhang and T. Chen, "IoT Security Solutions: A Survey of Current Research and Future Directions," IEEE Internet Things J., vol. 8, no. 8, pp. 6406–6417, Aug. 2021.

R. Sekar and M. Singh, "Smart Home Security Systems and Protocols: An Overview," in Proc. IEEE Global Commun. Conf., 2020, pp. 1–6.

T. Zhang, "Efficient Intrusion Detection Systems for IoT: A Review," IEEE Commun. Surveys Tuts., vol. 20, no. 3, pp. 1839–1864, 2020.

N. H. Tran and D. Le, "Raspberry Pi-Based Security System for Smart Homes," IEEE Access, vol. 7, pp. 122640–122652, 2020.

R. Arora, "Application of Machine Learning Algorithms in IoT Security: A Survey," in Proc. IEEE Int. Conf. Comput. Intell. Data Sci., 2021, pp. 222–227.

L. Cao and J. Li, "Lightweight Intrusion Detection Systems for IoT Security in Smart Homes," IEEE Internet Things J., vol. 9, no. 3, pp. 1920–1935, Mar. 2022.

F. Yao and K. Xu, "Implementation of Real-Time IoT Intrusion Detection System Using Raspberry Pi," in Proc. IEEE Int. Conf. Comput. Commun. Netw., 2020, pp. 102–108.

C. W. Lim, "An Adaptive Machine Learning-Based Security Solution for IoT Networks," IEEE Access, vol. 9, pp. 78530–78545, May 2021.

A. Roy and M. Alam, "Comparative Study of Machine Learning Algorithms for Intrusion Detection in IoT," in Proc. IEEE Comput. Soc. Conf. Big Data, 2021, pp. 2024–2029.

K. S. Park and H. Kim, "Analysis of Security Threats in IoT-Based Smart Home Environments," IEEE Internet Things J., vol. 8, no. 7, pp. 5955–5965, July 2021.

Z. Wang and S. Li, "Design and Implementation of Security Solutions for IoT Networks Using Raspberry Pi," in Proc. IEEE Global Commun. Conf., 2021, pp. 1–8.

M. E. Davies and L. Zhang, "Evaluating the Impact of Adaptive IDS in Smart Home Applications," IEEE Trans. Ind. Informatics, vol. 18, no. 4, pp. 2780–2788, Apr. 2022.

A. Kumar and R. Sharma, "A Survey on Machine Learning Approaches for IDS in IoT," IEEE Access, vol. 10, pp. 15087–15106, 2022.

F. Hernandez and N. Gomez, "Implementation of Cost-Effective IDS for Smart Homes Using Raspberry Pi," IEEE Trans. Consum. Electron., vol. 68, no. 2, pp. 118–126, Apr. 2022.

L. Cao and J. Li, "Enhanced Detection of Intrusions in IoT Networks Using Lightweight Machine Learning Models," IEEE Access, vol. 9, pp. 64320–64335, 2021.




DOI: http://dx.doi.org/10.24014/sitekin.v22i2.33485

Refbacks

  • There are currently no refbacks.


Copyright (c) 2025 SITEKIN: Jurnal Sains, Teknologi dan Industri




Editorial Address:
FAKULTAS SAINS DAN TEKNOLOGI
UIN SULTAN SYARIF KASIM RIAU

Kampus Raja Ali Haji
Gedung Fakultas Sains & Teknologi UIN Suska Riau
Jl.H.R.Soebrantas No.155 KM 18 Simpang Baru Panam, Pekanbaru 28293
Email: sitekin@uin-suska.ac.id
© 2023 SITEKIN, ISSN 2407-0939

SITEKIN Journal Indexing:

Google Scholar | Garuda | Moraref | IndexCopernicus | SINTA


Creative Commons License
SITEKIN by http://ejournal.uin-suska.ac.id/index.php