To set up a PassWall2 network test,follow these organized steps:
-
Create Configuration File:
- Ensure the XML file
passwall2_config_test.xmlis created in the tests directory undertests/passwall2. - This file contains the network configuration for the test.
- Ensure the XML file
-
Write the XML Content:
<xml version="2."> <root> <config> <test> <username user="user_name"> <password password="pass password"> <network> <nodes> <node node-id="node1"> <ip address="192.168.1.1" netmask="255.255.255."> <port_forwarding port_forwarding="1234"> <network_interface> <mac address="::1" ip="192.168.1.1" port="88" description="Interface 1"> <node>Test Node 1</node> <node-id>1</node> </network_interface> </port_forwarding> </node> </ip> </node> <node node-id="node2"> <ip address="192.168.1.2" netmask="255.255.255."> <port_forwarding port_forwarding="672"> <network_interface> <mac address="::2" ip="192.168.1.2" port="8443" description="Interface 2"> <node>Test Node 2</node> <node-id>2</node> </network_interface> </port_forwarding> </ip> </node> <node node-id="node3"> <ip address="192.168.1.3" netmask="255.255.255."> <port_forwarding port_forwarding="5555"> <network_interface> <mac address="::3" ip="192.168.1.3" port="8888" description="Interface 3"> <node>Test Node 3</node> <node-id>3</node> </network_interface> </port_forwarding> </ip> </node> <node node-id="node4"> <ip address="192.168.1.4" netmask="255.255.255."> <port_forwarding port_forwarding="1"> <network_interface> <mac address="::4" ip="192.168.1.4" port="22" description="Interface 4"> <node>Test Node 4</node> <node-id>4</node> </network_interface> </port_forwarding> </ip> </node> </nodes> </test> </config> </root> </xml> -
Validate the XML:
Use an XML validator tool to ensure all tags are correctly formatted and closed.
-
Set Up the Test:
- Navigate to the
tests/passwall2/with_configdirectory. - Create a new XML file
passwall2_test.xmland set it as the default configuration for the test usingxtestor the appropriate command.
- Navigate to the
-
Run the Test:
- Execute the test command to start the test environment.
- Check the output files for any errors or warnings related to network configuration.
By following these steps, you ensure a properly configured network test with the correct network interface forwarding settings.

@版权声明
转载原创文章请注明转载自蜂窝加速器-2026年中国国内可用的翻墙VPN梯子加速器-蜂窝VPN,网站地址:https://wuqukeji.cn/