Authors - Satish Kamble, Surendra Mahajan, Lalit Patil Abstract - In today’s world, IoT devices interact with each other for a specific purpose. IoT de-vices are used in every aspect of our lives. In IoT networks, devices can act as malicious nodes and can perform attacks affecting the IoT network's performance. A trust management system can play a major role in these IoT networks. This paper suggests a trust management system that is based on quality of services (QoS) and implemented on a real Raspberry Pi and ESP32 IoT testbed. The model uses direct trust and indirect trust parameters. The model uses memory efficiently by using sliding-window mechanism. This system implements a threshold-based mechanism for detecting untrustworthy devices and further blocking them for future communication. A recency-weight is used for stabilizing the system. This system is capable of detecting attacks such as the grayhole attack and RTT inflation attack.