1Rex::Commands::Network(U3s)er Contributed Perl DocumentatRieoxn::Commands::Network(3)
2
3
4
6 Rex::Commands::Network - Network Module
7
9 With this module you can get information of the routing table, current
10 network connections, open ports, ...
11
13 use Rex::Commands::Network;
14
15 my @routes = route;
16 print Dumper(\@routes);
17
18 my $default_gw = default_gateway;
19 default_gateway "192.168.2.1";
20
21 my @netstat = netstat;
22 my @tcp_connections = grep { $_->{"proto"} eq "tcp" } netstat;
23
25 route
26 Get routing information
27
28 default_gateway([$default_gw])
29 Get or set the default gateway.
30
31 netstat
32 Get network connection information
33
34
35
36perl v5.34.0 2022-01-19 Rex::Commands::Network(3)