In recent years, the Internet of Things (IoT) has become one of the most familiar names creating a benchmark and scaling new heights. IoT an indeed future of the communication that has transformed the objects (things) of the real world into smarter devices. With the advent of IoT technology, this decade is witnessing a transformation from traditional agriculture approaches to the most advanced ones. In perspective to the current standing of IoT in agriculture, identification of the most prominent application of IoT-based smart farming i.e. greenhouse has been highlighted and presented a comprehensive systematic literature review (SLR) in the Greenhouse field. The SLR has been conducted by reviewing the articles published between 2015-2022. This SLR analyses 32 relevant studies, which were selected manually from well-reputed digital databases. The primary objective of this SLR is to conduct state-of-the-art research to analyze and identify the current research trends, opportunities, challenges, and gaps in IoT-based greenhouse farming. A rigorous discussion on IoT-based greenhouse applications, sensors/devices, and communication protocols have been presented. Furthermore, this research also presents an inclusive review of IoT-based greenhouse sensors/devices and communication protocols. Moreover, we have also presented a rigorous discussion on smart greenhouse farming challenges and security issues as well as identified future research directions to overcome these challenges. This research has explained many aspects of the technologies involved in IoT-based greenhouse and proposed network architecture, topology, and platforms. In the end, review results have been summarized by presenting an IoT-based greenhouse farm management taxonomy and attacks taxonomy.INDEX TERMS Internet of things (IoT), greenhouse, applications, sensors, communication protocols, cloud computing, big data analytics, security attacks