The National information security vulnerability sharing platform of China reported a 1% annual growth of the vulnerabilities related to security [4]. Of 14,201 total security vulnerabilities, 34.5% include high-risk vulnerabilities. In 2018, the Chinese Internet emergency center claimed that distributed denial of service (DDoS) is more than four thousand on average per year. During denial of service (DoS) attacks, the bulk redundancy of requests overloads the system. Attackers choose common and well-known servers like banks and collapse the system leading to huge financial losses. The reports also reveal that more than two thousand resources are utilized for DDoS attacks initiation, ninety thousand IP addresses of destination, and one million broilers. This indicates that approximately one million devices, mobile or computers, have been controlled by network attackers for illegal activities. A lot of efforts, from academia and industry, have been carried out to secure large networks from intrusion attacks. An intrusion detection system performs real-time surveillance of data transmission over a network and takes appropriate measures when any suspicious activities are found in network transmission. Conventional intrusion detection systems have many limitations for providing network security with higher false-positive rates. A network security system is also leveraged by the development of artificial intelligence (AI) and machine learning tools. However, machine learning models are facing several challenges such as poor generalization ability when dealing with a new and huge amount of data. Deep learning models need large-sized and good quality data for appropriate training and their use is less explored in the field of cybersecurity [5]. Continuously expanding networks with massive devices and the addition of the satellite network, data security, and data privacy are major problems in the satellite-terrestrial network. Limited resources and computational power of the satellite network as compared to the terrestrial network is an additional challenge. When a satellite node is attacked by an attacker, it is exhausted quickly and difficult to fix. Therefore, efficient intrusion detection methods need to be devised to provide high-level protection for modern networks [6]. Machine learning and deep learning models have been proposed by researchers for designing intrusion detection systems [7; 8; 9]. The effectiveness of the machine learning techniques depends upon the dataset containing normal and abnormal trends. KDD-CUP 99 dataset has been extensively used for intrusion detection testing. NSL-KDD is an extended form of the KDD-CUP 99. This study utilizes both datasets to improve and optimize the results of existing studies for intrusion detection systems. These datasets are for terrestrial networks and are not suitable for a satellite network because of the limited resources, different tolerance levels, and high privacy requirements. Therefore, this study also considers the distributed network based on satellite and terrestrial networks for intrusion detection. To prove the adaptive ability and generalization of the proposed framework, it is applied to the STIN dataset. The contributions of this work can be summarized as  
* An efficient framework is proposed for intrusion detection that utilizes the ensemble architecture comprising Random Forest (RF) and Multilayer Perceptron (MLP). For final prediction, the soft voting criterion is used. * Several well-known machine learning models are used for performance comparison including RF, support vector machine (SVM), and logistic regression (LR). Experiments are performed using two datasets for terrestrial network traffic including KDD-CUP 99 and NSL-KDD while the STIN dataset is used for satellite network traffic analysis. * Performance evaluation of the proposed RFMLP is carried out with state-of-the-art approaches in terms of accuracy, precision, recall, and F1 score. The rest part of the paper is structured as follows.