A method for implementing island network vulnerability scanning based on Metasploit technology

By setting up intermediate machines within isolated networks and using the Metasploit environment for penetration testing and scanning, the problem of isolated networks being unable to be directly scanned is solved, enabling comprehensive vulnerability detection and real-time security management of isolated networks.

CN117040815BActive Publication Date: 2026-07-24YUNNAN POWER GRID CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
YUNNAN POWER GRID CO LTD
Filing Date
2023-07-31
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

Existing technologies are insufficient for effectively scanning isolated networks for security vulnerabilities. Traditional vulnerability scanning techniques cannot be deployed in isolated networks, and the isolation of isolated networks from external networks makes direct scanning impossible.

Method used

Set up an intermediate machine with traffic relay function within the isolated network, conduct penetration testing through the Metasploit environment, use Metasploit modular components to scan the isolated network for vulnerabilities, and send the results back to the intermediate machine.

Benefits of technology

It enables comprehensive and in-depth scanning of isolated networks, discovers and fixes potential security vulnerabilities, provides real-time security assessments and policy formulation, and improves the security of isolated networks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117040815B_ABST
    Figure CN117040815B_ABST
Patent Text Reader

Abstract

The application discloses a method for realizing island network vulnerability scanning based on Metasploit technology, which comprises the following steps: setting an intermediate machine with traffic relay function in the island network; connecting to the intermediate machine from an external network and building a Metasploit environment on the intermediate machine; penetrating the intermediate machine by using modular components and related attack technology in the Metasploit and obtaining the access right to the internal island network; scanning the host and running service in the island network by using the vulnerability scanning module in the Metasploit and transmitting the scanning result back to the intermediate machine. The method can discover and repair the possible security vulnerability in the island network, can comprehensively and deeply scan the island network, can flexibly scan the vulnerability and manage the security of the island network from the external network, and can transmit the scanning result back to the intermediate machine in real time to deal with the possible security threat in time.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of network security technology, specifically to a method for scanning isolated networks based on Metasploit technology. Background Technology

[0002] In the field of computer network security, an islanded network is a special network environment that is not directly connected to external networks, thereby protecting internal data and services from external threats. Islanded networks are typically designed to handle highly sensitive information, such as military communications, financial transactions, and critical infrastructure control systems.

[0003] The security of isolated networks is primarily achieved through physical isolation or logical isolation. Physical isolation uses physical means, such as disconnecting network lines, to prevent devices on the isolated network from physically connecting to the external network. Logical isolation, on the other hand, uses network configuration and security policies to ensure that while devices on the isolated network can physically connect to the external network, they are logically unable to communicate with it.

[0004] However, despite the high level of security offered by isolated networks, vulnerabilities can still exist due to human error, equipment malfunction, software flaws, and other factors. These vulnerabilities can be exploited by malicious attackers, threatening the data and services of the isolated network. Therefore, regular security scans and timely patching of these vulnerabilities are crucial measures to ensure the security of isolated networks.

[0005] Due to the unique characteristics of isolated networks, traditional vulnerability scanning techniques are often difficult to apply. For example, many vulnerability scanning techniques require the deployment of specific scanning devices or software in the target network, which is often not feasible in isolated networks. Furthermore, because the connection between isolated networks and external networks is strictly limited, it is impossible to directly scan isolated networks for vulnerabilities from external networks.

[0006] Therefore, how to effectively scan isolated networks for security vulnerabilities is a significant issue currently facing the cybersecurity field. Summary of the Invention

[0007] The purpose of this section is to outline some aspects of embodiments of the present invention and to briefly describe some preferred embodiments. Simplifications or omissions may be made in this section, as well as in the abstract and title of this application, to avoid obscuring the purpose of these documents; however, such simplifications or omissions should not be construed as limiting the scope of the invention.

[0008] In view of the above-mentioned problems, the present invention is proposed.

[0009] Therefore, the technical problem solved by this invention is: how to effectively scan isolated networks for security vulnerabilities.

[0010] To address the aforementioned technical problems, this invention provides the following technical solution: A method for scanning isolated networks based on Metasploit technology includes,

[0011] Set up an intermediate machine with traffic relay function within the isolated network;

[0012] Connect to the intermediate machine from the external network and set up the Metasploit environment on the intermediate machine;

[0013] By utilizing the modular components and related attack techniques in Metasploit, we can penetrate intermediate machines and gain access to the interior of isolated networks.

[0014] Use the vulnerability scanning module in Metasploit to scan hosts and services running in an isolated network, and send the scan results back to an intermediate machine.

[0015] As a preferred embodiment of the method for scanning vulnerabilities in isolated networks based on Metasploit technology described in this invention, the intermediate machine includes: configuring the network interface of the intermediate machine to connect to the external network and the isolated network; configuring the IP address of the intermediate machine to uniquely identify the intermediate machine in the network; enabling the IP forwarding function of the intermediate machine to allow network traffic to pass through the intermediate machine; and configuring the NAT rules of the intermediate machine to forward connection requests from the external network to the isolated network.

[0016] As a preferred embodiment of the method for scanning isolated networks based on Metasploit technology described in this invention, the step of setting up the Metasploit environment includes:

[0017] Install the Metasploit environment on the intermediate machine via SSH; configure the Metasploit environment, including the necessary modular components and related attack techniques; start the Metasploit environment, ready for subsequent penetration testing.

[0018] As a preferred embodiment of the method for scanning isolated networks based on Metasploit technology described in this invention, the penetration of the intermediate machine includes: selecting a vulnerability exploitation module suitable for the intermediate machine; configuring the vulnerability exploitation module, specifying the target IP address and other parameters; executing the vulnerability exploitation module to penetrate the intermediate machine; and verifying the penetration results to confirm whether access to the interior of the isolated network has been obtained.

[0019] The verification penetration results specifically include,

[0020] If the penetration is successful, the attacker will gain command execution privileges on the target system and can try to execute commands on the target system. If the commands can be executed successfully and return the expected results, then the penetration can be confirmed as successful.

[0021] If the penetration test fails, corresponding measures should be taken based on the reason for the failure:

[0022] If the vulnerability module was chosen inappropriately, try using other vulnerability exploitation modules to further collect information about the target system.

[0023] If the vulnerability exploit module is misconfigured, check and correctly configure the vulnerability exploit module.

[0024] As a preferred embodiment of the method for scanning isolated networks based on Metasploit technology described in this invention, the scanning of hosts and running services within the isolated network includes:

[0025] Select a vulnerability scanning module suitable for the isolated network; configure the vulnerability scanning module, specifying the scan scope and other parameters; execute the vulnerability scanning module to scan the isolated network; collect the scan results, including vulnerability information of hosts and services within the isolated network; transmit the scan results back to the intermediate machine over the network.

[0026] Based on historical scan results, the probability of vulnerabilities appearing in different parts is calculated, and then the scanning strategy is optimized based on the probabilities, including:

[0027] Define a function P(x) to represent the probability of a vulnerability appearing at position x. This probability can be calculated based on historical scan results. If position x has had M vulnerabilities in the past N scans, then P(x) = M / N. Then, based on P(x), define a function S(x) to represent the number of times position x should be scanned in the next scan.

[0028] S(x) = ceil(P(x) * K)

[0029] Here, K is a constant representing the average number of scans at each position, and ceil is a mathematical function that rounds the input value up.

[0030] As a preferred embodiment of the method for scanning isolated networks based on Metasploit technology described in this invention, the scanning results include vulnerability information of hosts and services within the isolated network, the severity of the vulnerability information is used to assess the security status of the isolated network, and corresponding security strategies are formulated.

[0031] If a vulnerability can be exploited remotely without any user interaction, it is considered to have high exploitability. Conversely, if exploiting a vulnerability requires user interaction and specific operations to be performed on the local system, it is considered to have low exploitability.

[0032] When a vulnerability is highly exploitable, it is considered to pose a high risk, and the formulation of security policies should prioritize the remediation of such high-risk vulnerabilities.

[0033] When the exploitability of a vulnerability is low, it is considered to have a low risk of existence and a low priority for remediation, which is arranged according to resource availability and remediation cost.

[0034] If a vulnerability, once exploited, can lead to a complete system crash and the leakage of sensitive data, then the vulnerability is considered to have a high degree of impact and should be patched immediately, with the highest priority for patching.

[0035] If the exploitation of a vulnerability only results in the failure of non-essential system functions and the leakage of non-sensitive data, the impact of the vulnerability is considered low, and a security patch is applied to fix it.

[0036] If fixing a vulnerability requires a large-scale upgrade and reconstruction of the entire system, then the vulnerability is considered difficult to fix. Conversely, if fixing a vulnerability only requires applying a security patch and changing the configuration settings, then the vulnerability is considered easy to fix.

[0037] When vulnerabilities are difficult to fix, the system should be upgraded and replaced in stages according to a plan.

[0038] As a preferred embodiment of the method for scanning isolated networks based on Metasploit technology described in this invention, the scanning results are transmitted back to the intermediate machine via the network in real time, and the isolated network is monitored in real time, so that the real-time scanning results can be seen during the scanning process.

[0039] When vulnerability information is detected in real time, it is immediately transmitted back to the intermediate machine for vulnerability analysis and subsequent remediation measures.

[0040] A Metasploit vulnerability scanning system for isolated networks using any of the methods described in this invention, characterized in that it includes:

[0041] Intermediate machine: Configured within the isolated network, it has traffic relay function, capable of receiving connection requests from external networks and forwarding network traffic to the isolated network;

[0042] Metasploit environment builders: Installed on intermediate machines, these include modular components and related attack techniques used to penetrate intermediate machines and gain access to the interior of isolated networks.

[0043] Vulnerability scanning module: The vulnerability scanning module in the Metasploit environment is used to scan hosts and services in an isolated network and send the scan results back to an intermediate machine;

[0044] Results analysis and reporting module: used to receive scan results, analyze the security status of isolated networks, and generate corresponding reports;

[0045] Security policy formulation module: Based on the scan results and security status report, formulate corresponding security policies, including vulnerability remediation policies and defense policies.

[0046] A computer device includes a memory and a processor, the memory storing a computer program, the processor executing the computer program to implement the steps of the method described above.

[0047] A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described above.

[0048] The beneficial effects of this invention are as follows: The method for vulnerability scanning of isolated networks based on Metasploit technology provided by this invention utilizes the Metasploit environment for deep vulnerability scanning, enabling the discovery and remediation of potential security vulnerabilities in isolated networks. The Metasploit environment offers a rich set of vulnerability scanning modules and attack techniques, allowing for comprehensive and in-depth scanning of isolated networks. By setting up an intermediate machine with traffic relay capabilities within the isolated network, vulnerability scanning and security management of the isolated network can be flexibly performed from external networks. Scan results can be transmitted back to the intermediate machine in real time, providing real-time security assessment and policy formulation, which helps to respond promptly to potential security threats. Attached Figure Description

[0049] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. Wherein:

[0050] Figure 1 The first embodiment of the present invention provides an overall flowchart of a method for scanning isolated networks based on Metasploit technology. Detailed Implementation

[0051] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the protection scope of the present invention.

[0052] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.

[0053] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.

[0054] This invention is described in detail with reference to the schematic diagrams. When detailing the embodiments of this invention, for ease of explanation, the cross-sectional views illustrating the device structure may be partially enlarged, not adhering to the usual scale. Furthermore, the schematic diagrams are merely examples and should not be construed as limiting the scope of protection of this invention. In actual fabrication, the three-dimensional spatial dimensions of length, width, and depth should be included.

[0055] Furthermore, in the description of this invention, it should be noted that the terms "upper," "lower," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. These terms are used solely for the convenience of describing the invention and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on the invention. In addition, the terms "first," "second," or "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.

[0056] Unless otherwise explicitly specified and limited, the terms "installation," "connection," and "joining" in this invention should be interpreted broadly. For example, they can refer to fixed connections, detachable connections, or integral connections; similarly, they can refer to mechanical connections, electrical connections, or direct connections, or indirect connections through an intermediate medium, or internal connections between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0057] Example 1

[0058] Reference Figure 1As an embodiment of the present invention, a method for scanning isolated networks based on Metasploit technology is provided, comprising:

[0059] S1: Set up an intermediate machine with traffic relay function within the isolated network.

[0060] Configure the network interface of the intermediate machine to connect to the external network and the isolated network; configure the IP address of the intermediate machine to uniquely identify the intermediate machine in the network; enable the IP forwarding function of the intermediate machine to allow network traffic to pass through the intermediate machine; configure the NAT rules of the intermediate machine to forward connection requests from the external network to the isolated network.

[0061] Setting up network interfaces: First, you need to configure at least two network interfaces for the intermediate machine. One interface connects to the external network, and the other connects to the isolated network. This can be achieved through physical interfaces (e.g., Ethernet ports) or virtual interfaces (e.g., Virtual Private Networks, VPNs).

[0062] Configure IP addresses: Each network interface needs a unique IP address. This IP address should be within the IP address range of the corresponding network. For example, if the IP address range of the external network is 192.168.1.0 / 24, then the IP address of the external network interface could be 192.168.1.100. Similarly, if the IP address range of the isolated network is 10.0.0.0 / 24, then the IP address of the isolated network interface could be 10.0.0.100.

[0063] Enable IP forwarding: In most operating systems, IP forwarding is disabled by default. To enable intermediate machines to forward network traffic, IP forwarding needs to be enabled.

[0064] Configuring NAT (Network Address Translation) rules: To enable intermediate machines to forward connection requests from the external network to the isolated network, NAT rules need to be configured. In Linux systems, the iptables tool can be used to configure NAT rules.

[0065] S2: Connect to the intermediate machine from the external network and set up the Metasploit environment on the intermediate machine.

[0066] Install the Metasploit environment on the intermediate machine via SSH; configure the Metasploit environment, including the necessary modular components and related attack techniques; start the Metasploit environment, ready for subsequent penetration testing.

[0067] Connecting to an intermediate machine from an external network: The goal is to establish a secure connection that allows devices on the external network to access the intermediate machine within the isolated network. This is typically achieved through a VPN, SSH tunnel, or other secure remote access technologies. Once the connection is established, devices on the external network can access the intermediate machine within the isolated network just as they would access devices on the local network.

[0068] Setting up a Metasploit environment on an intermediate machine: The goal is to install and configure a Metasploit environment on an intermediate machine. Metasploit is a powerful penetration testing framework that provides rich modular components and attack techniques for in-depth security assessments of networks. Setting up a Metasploit environment on an intermediate machine enables penetration testing within isolated networks.

[0069] Installing a Metasploit environment via SSH: SSH is a secure network protocol that provides an encrypted tunnel for secure remote login and other secure network services over insecure networks. Using SSH, devices on external networks can securely access intermediate machines within an isolated network and install the Metasploit environment on them.

[0070] Configuring the Metasploit environment: The goal of configuring the Metasploit environment is to select and configure suitable modular components and attack techniques based on the penetration testing requirements. This may include selecting and configuring vulnerability scanning modules, attack modules, payload modules, etc.

[0071] Starting the Metasploit environment: After configuring the Metasploit environment, you need to start it to prepare it for subsequent penetration testing. Once the Metasploit environment is running, you can begin using its various features to conduct in-depth security assessments of isolated networks.

[0072] S3: Utilizes modular components and related attack techniques in Metasploit to penetrate intermediate machines and gain access to the interior of isolated networks.

[0073] Select a suitable exploit module for the intermediate machine; configure the exploit module, specifying the target IP address and other parameters; execute the exploit module to penetrate the intermediate machine; verify the penetration results to confirm whether access to the isolated network has been obtained.

[0074] Choosing the right exploit module for the intermediate machine: The Metasploit environment provides a large number of exploit modules, each targeting a specific vulnerability or weakness. This step requires selecting a suitable exploit module based on the system and services of the intermediate machine. This typically necessitates some information gathering and analysis of the intermediate machine to identify any potential vulnerabilities.

[0075] Configuring the Exploitation Module: After selecting a suitable exploit module, it needs to be configured in preparation for penetration testing. Configuration typically includes specifying the target IP address, setting the payload, and other possible parameters. The specific settings for these parameters will be adjusted based on the characteristics of the selected exploit module and payload, as well as the penetration test objectives.

[0076] Execute the exploit module: After the exploit module is configured, it can be executed to penetrate the intermediate machine. During the penetration process, the exploit module will attempt to exploit vulnerabilities or weaknesses in the target system to execute attack payloads, thereby gaining access to the target system.

[0077] Verifying the penetration test results: After the penetration test is complete, it is necessary to verify the results to confirm whether access to the isolated network has been successfully gained. Verification typically involves checking the output of the Metasploit environment and attempting to execute some commands in the obtained session. If the verification results show that access has been successfully gained, then subsequent vulnerability scanning and security assessment can begin.

[0078] S4: Use the vulnerability scanning module in Metasploit to scan the hosts and services running in the isolated network, and send the scan results back to the intermediate machine;

[0079] Select a vulnerability scanning module suitable for the isolated network; configure the vulnerability scanning module, specifying the scan scope and other parameters; execute the vulnerability scanning module to scan the isolated network; collect the scan results, including vulnerability information of hosts and services within the isolated network; transmit the scan results back to the intermediate machine over the network.

[0080] Based on historical scan results, the probability of vulnerabilities appearing in different parts is calculated. Then, based on these probabilities, the scanning strategy is optimized, including...

[0081] Define a function P(x) to represent the probability of a vulnerability appearing at position x. This function can be calculated based on historical scan results. If position x has had M vulnerabilities in the past N scans, then P(x) = M / N. Then, based on P(x), define a function S(x) to represent the number of times position x should be scanned in the next scan.

[0082] S(x) = ceil(P(x) * K).

[0083] Where K is a constant representing the average number of scans for each location. Vulnerability information for hosts and services within the isolated network, along with the severity of these vulnerabilities, is used to assess the security status of the isolated network and formulate corresponding security strategies.

[0084] Furthermore, by calculating the probability of vulnerabilities appearing in different areas, we can optimize our scanning strategy, making scans more targeted and improving efficiency. For example, if a vulnerability in a certain location has a high probability of occurrence, we can increase the number of scans targeting that location in the next scan to increase the probability of finding the vulnerability. Since our scanning strategy is determined based on historical scan results, we can continuously update our strategy as scanning progresses to better adapt it to the current network environment. For example, if the probability of a vulnerability appearing in a certain location decreases over a period of time, we can correspondingly reduce the number of scans targeting that location.

[0085] If a vulnerability can be exploited remotely without any user interaction, it is considered highly exploitable. Conversely, if exploitation requires user interaction or specific operations on the local system, it is considered low exploitability. High exploitability indicates a high-risk vulnerability, and security policies should prioritize fixing these high-risk vulnerabilities. Low exploitability indicates a low-risk vulnerability, and its remediation priority is relatively low, determined based on resource availability and remediation costs. If exploitation leads to complete system crashes and sensitive data leakage, the vulnerability is considered high-impact and requires immediate patching, with the highest priority. If exploitation only results in the failure of non-essential system functions and the leakage of non-sensitive data, the vulnerability is considered low-impact and requires patching. If patching requires a large-scale system upgrade and reconstruction, the vulnerability is considered difficult to fix. Conversely, if patching only requires applying a single security patch and changing some configuration settings, the vulnerability is considered easy to fix. When vulnerability patching is difficult, planned phased system upgrades and replacements should be implemented.

[0086] Furthermore, selecting a suitable vulnerability scanning module for the isolated network is crucial. The Metasploit environment offers a large number of vulnerability scanning modules, each targeting a specific vulnerability or weakness. This step requires selecting an appropriate module based on the system and service characteristics of the isolated network. This typically necessitates some information gathering and analysis of the isolated network to identify potential vulnerabilities.

[0087] Configuring the vulnerability scanning module: After selecting a suitable vulnerability scanning module, it needs to be configured in preparation for vulnerability scanning. Configuration typically includes specifying the scan scope, setting scan parameters, and other possible parameters. The specific settings for these parameters will be adjusted according to the characteristics of the selected vulnerability scanning module and the scanning targets.

[0088] Execute the vulnerability scanning module: After configuring the vulnerability scanning module, you can execute it to scan the isolated network. During the scan, the vulnerability scanning module will attempt to detect vulnerabilities or weaknesses in the target system to collect relevant vulnerability information.

[0089] Collect scan results: After the scan is complete, the results need to be collected. These results include vulnerability information for hosts and services within the isolated network. This vulnerability information helps to understand the security status of the isolated network and the potential security risks.

[0090] The scan results are then transmitted back to the intermediate machine: After collecting the scan results, these results need to be transmitted back to the intermediate machine via the network. This allows the results to be easily viewed and analyzed on devices on an external network.

[0091] Assessing the security status of isolated networks: Based on the collected vulnerability information, the security status of isolated networks can be assessed. The assessment typically includes the number, type, and severity of vulnerabilities, as well as the potential impact of these vulnerabilities on the isolated network.

[0092] Develop appropriate security strategies: Based on the security assessment results, corresponding security strategies can be developed. These strategies may include patching vulnerabilities, enhancing defenses, and improving monitoring. The specific content of these strategies will be adjusted according to security requirements and the actual situation of the isolated network.

[0093] This embodiment also includes a system for scanning isolated networks based on Metasploit technology. The system comprises: an intermediate machine: configured within the isolated network, with traffic relay capabilities, capable of receiving connection requests from external networks and forwarding network traffic to the isolated network; a Metasploit environment building module: installed on the intermediate machine, including modular components and related attack techniques, used to penetrate the intermediate machine and gain access to the isolated network; a vulnerability scanning module: a vulnerability scanning module within the Metasploit environment, used to scan hosts and services within the isolated network and transmit the scan results back to the intermediate machine; a result analysis and reporting module: used to receive scan results, analyze the security status of the isolated network, and generate corresponding reports; and a security policy formulation module: based on the scan results and security status reports, formulates corresponding security policies, including vulnerability remediation policies and defense policies.

[0094] The computer device can be a server. This computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operating system and computer programs stored in the non-volatile storage media. The database stores cluster data from a power monitoring system. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When the computer program is executed by the processor, it implements a method for scanning isolated networks using Metasploit technology.

[0095] Example 2

[0096] As an embodiment of the present invention, a method for scanning isolated networks based on Metasploit technology is provided. To verify the beneficial effects of the present invention, scientific demonstration is carried out through economic benefit calculations and simulation experiments.

[0097] We can set up a simulated isolated network environment, including an intermediate machine and several target hosts. The target hosts run various different services and are intentionally configured with known vulnerabilities.

[0098] First, we penetrated the intermediate machine to gain access to the isolated network. Then, we used the vulnerability scanning module in Metasploit to scan the hosts and services running within the isolated network and sent the scan results back to the intermediate machine.

[0099] Here is a portion of the scan results:

[0100] Host Number Service Name Vulnerability Name Vulnerability Exploitability Impact of the vulnerability Repair difficulty 1 FTP CVE-2010-4221 high high middle 2 HTTP CVE-2013-6786 middle middle Low 3 SSH CVE-2016-6210 Low high high 4 SMTP CVE-2011-1720 high middle middle 5 DNS CVE-2015-5477 middle high Low

[0101] Then, based on the scan results, we assess the security status of the isolated network and formulate corresponding security strategies. For example, for host 1, we can choose to apply security patches to fix the vulnerabilities; for host 2, we can change configuration settings to reduce the impact of the vulnerabilities; for host 3, we may need to upgrade to a software version without vulnerabilities.

[0102] Through this simulation experiment, we can see that our method can effectively identify vulnerabilities in isolated networks and formulate reasonable security strategies based on the characteristics of the vulnerabilities, thereby improving the security of isolated networks.

[0103] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A method for scanning isolated networks using Metasploit technology, characterized in that, include, Set up an intermediate machine with traffic relay function within the isolated network; Connect to the intermediate machine from the external network and set up the Metasploit environment on the intermediate machine; By utilizing the modular components and related attack techniques in Metasploit, we can penetrate intermediate machines and gain access to the interior of isolated networks. Use the vulnerability scanning module in Metasploit to scan hosts and services running in an isolated network, and send the scan results back to an intermediate machine; The intermediate machine includes: configuring the network interface of the intermediate machine to connect to the external network and the isolated network; configuring the IP address of the intermediate machine to uniquely identify the intermediate machine in the network; enabling the IP forwarding function of the intermediate machine to allow network traffic to pass through the intermediate machine; and configuring the NAT rules of the intermediate machine to forward connection requests from the external network to the isolated network. Setting up the Metasploit environment includes... Install the Metasploit environment on the intermediate machine via SSH; configure the Metasploit environment, including the necessary modular components and related attack techniques; start the Metasploit environment, ready for subsequent penetration testing; The penetration of the intermediate machine includes: selecting a suitable exploit module for the intermediate machine; configuring the exploit module, specifying the target IP address and other parameters; executing the exploit module to penetrate the intermediate machine; and verifying the penetration results to confirm whether access to the isolated network has been obtained. The verification penetration results specifically include, If the penetration is successful, the attacker will gain command execution privileges on the target system and execute commands on the target system. If the commands can be executed successfully and return the expected results, the penetration is confirmed to be successful. If the penetration test fails, corresponding measures should be taken based on the reason for the failure: If the vulnerability module was chosen inappropriately, try using other vulnerability exploitation modules to further collect information about the target system. If the vulnerability exploit module is misconfigured, check and correctly configure the vulnerability exploit module.

2. The method for scanning isolated networks based on Metasploit technology as described in claim 1, characterized in that: The scanning of hosts and services running within the isolated network includes... Select a vulnerability scanning module suitable for the isolated network; configure the vulnerability scanning module, specifying the scan scope and other parameters; execute the vulnerability scanning module to scan the isolated network; collect the scan results, including vulnerability information of hosts and services within the isolated network; transmit the scan results back to the intermediate machine over the network. Based on historical scan results, the probability of vulnerabilities appearing in different parts is calculated, and then the scanning strategy is optimized based on the probabilities, including: Define a function P(x) to represent the probability of a vulnerability at position x. It can be calculated based on historical scan results. If there are M vulnerabilities at position x in the past N scans, then P(x) = M / N. Then, based on P(x), we define a function S(x) that represents the number of times position x should be scanned in the next scan. The definition is as follows: S(x) = ceil(P(x) * K) Here, K is a constant representing the average number of scans at each position, and ceil is a mathematical function that rounds the input value up.

3. The method for scanning isolated networks based on Metasploit technology as described in claim 2, characterized in that: The scan results include vulnerability information of hosts and services within the isolated network. The severity of the vulnerabilities is used to assess the security status of the isolated network and formulate corresponding security strategies. If a vulnerability can be exploited remotely without any user interaction, it is considered to have high exploitability. Conversely, if exploiting a vulnerability requires user interaction and specific operations to be performed on the local system, it is considered to have low exploitability. When a vulnerability is highly exploitable, it is considered to pose a high risk, and the formulation of security policies should prioritize the remediation of high-risk vulnerabilities. When the exploitability of a vulnerability is low, it is considered to have a low risk of existence and a low priority for remediation, which is arranged according to resource availability and remediation cost. If a vulnerability, once exploited, can lead to a complete system crash and the leakage of sensitive data, then the vulnerability is considered to have a high degree of impact and should be patched immediately, with the highest priority for patching. If the exploitation of a vulnerability only results in the failure of non-essential system functions and the leakage of non-sensitive data, the impact of the vulnerability is considered low, and a security patch is applied to fix it. If fixing a vulnerability requires a large-scale upgrade and reconstruction of the entire system, then the vulnerability is considered difficult to fix. Conversely, if fixing a vulnerability only requires applying a security patch and changing configuration settings, then the vulnerability is considered easy to fix. When vulnerabilities are difficult to fix, the system should be upgraded and replaced in stages according to a plan.

4. The method for scanning isolated networks based on Metasploit technology as described in claim 3, characterized in that: The scan results are transmitted back to the intermediate machine via the network in real time, enabling real-time monitoring of the isolated network. The real-time scan results can be seen during the scanning process. When vulnerability information is detected in real time, it is immediately transmitted back to the intermediate machine for vulnerability analysis and subsequent remediation measures.

5. A system for scanning isolated networks using Metasploit technology based on any one of the methods described in claims 1-4, characterized in that, include, Intermediate machine: Configured within the isolated network, it has traffic relay function, capable of receiving connection requests from external networks and forwarding network traffic to the isolated network; Metasploit environment builders: Installed on intermediate machines, these include modular components and related attack techniques used to penetrate intermediate machines and gain access to the interior of isolated networks. Vulnerability scanning module: The vulnerability scanning module in the Metasploit environment is used to scan hosts and services in an isolated network and send the scan results back to an intermediate machine; Results analysis and reporting module: used to receive scan results, analyze the security status of isolated networks, and generate corresponding reports; Security policy formulation module: Based on the scan results and security status report, formulate corresponding security policies, including vulnerability remediation policies and defense policies.

6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 4.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Systems and methods for self-tuning network intrusion detection and prevention

    US20150033340A1