Firewall Rules Issue..

tryllz

Smack-Fu Master, in training
61
Hi all,

I have a laptop and a physical dell server, both are connected to each other via VMware Workstation's Bridge (vmnet1 on 192.168.1.0/24, vmnet0 is connected to the WiFi NIC).

VMware Workstation Bridge Setting
VNE.png


Flow of Server traffic to Internet
Dell-Network.png


The following are running as VMs on VMware Workstation

  • A Firewall VM (firewallwm) with NICs as follows:
  • [**]NIC 1 Bridged to vmnet1 - 192.168.1.21/24
VMNET1.png

  • [**]NIC 2 VMware Workstation NAT - 192.168.47.132/24 | Gateway 192.168.47.2/24

The following are running as VMs on the Dell Server

  • A Firewall VM (firewallsm) with NICs as follows:
  • [**]NIC 1 VM Network Portgroup - 192.168.1.31/24 | Connected to (firewallwm's NIC 1) via VMware Workstation (vmnet1) Bridge
  • [**]NIC 2 VM Network Portgroup (Gateway to serveriscsi VM) - 10.0.28.34/27
  • A Windows Server VM (serveriscsi) - 10.0.64.42/27 | Gateway - 10.0.64.34

The following is the issue:

Server in in 10.0.64.32 (serveriscsi)network is able to get internet access even outside the schedule
serveriscsi-2021-03-23-23-57-59.png


Schedule from 21:30 to 21:45 everyday
5-firewallwm.png


Bridge Rules
1-firewallwm.png

WAN Rules
2-firewallwm.png

Server Rules
6-firewallwm.png


Firewll log shows everything is being let out, even though I have set 10.0.64.32 network traffic to only be allowed on schedule
6-firewallwm.png


I tried to reverse the rule as in block internet from 00:00 to 21:30 and then again from 21:45 to 23:59, that did not work either.

The IP 192.168.28.41 is a secondary DNS Server VM running in VMware Workstation, but since the rule is being applied to the network, it should block that.

What am I doing wrong here ?!

Thank You
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
Seems way more complicated than necessary due to all the screenshots. The basic concept is that you need to make rules that are logically consistent and you have to understand how the firewall (Opnsense) processes them.

If you have an 'allow all' rule to allow all outbound traffic to the internet, you either have to remove it or modify it so it *doesn't* allow the source address of the system you want to have no internet most of the time.

OR

You can create a deny rule for the source address of the system you want to block from getting internet access AND make sure it is processed first or at a higher priority than the Allow All rule.

Generally firewalls process their rules either 'top down' or in a numerical sequence by either the rule order or a priority order with each rule having a number or priority set on it.

I would generally assume the firewall will have an 'Allow All Outbound' rule by default. Most do, some don't show it in the config but many do.
If yours does then you need to make sure you have a deny rule with a schedule to deny traffic from the desired source IP address 192.168.28.41 (I think that is the one you want to block?) with a source port of any (*) and a destination of any (*) and any destination port (*) unless you only want to block it from accessing HTTP and HTTPS?

You haven't really explained what you are trying to do so...
 

tryllz

Smack-Fu Master, in training
61
OPNsense has a default deny rule.

I think the question got lost amidst all the screenshots which I had put so the whole scenarios can be understood, I think it got overwhelming instead.

The issue is that the Server 10.0.64.42 seems to be getting internet even outside the schedule

My network involves 1 Bridge, 1 NAT and a couple of Host-Only network in VMware Workstation while another network runs on Dell Server.

Now everyone is assuming that as I have a Bridge I'd automatically have internet connection over the Bridged NIC, but this is not the case as my Bridging is on the Ethernet NIC connected to Dell and NOT the WiFi that's why I have a NAT to get internet.

But what's going on is only when I block all internet traffic on the Bridge, NAT, and Server interfaces, only then all internet access stops to the Servers.
 

tryllz

Smack-Fu Master, in training
61
Look at the label.

The packets are coming from the firewall itself...so it's likely processing security AFTER the NAT.

Thanks for pointing that out.

I believe its a combination of both DNS Server 192.168.28.41 allow traffic to internet, and security processing after NAT that's why both servers 192.168.28.40 and 192.168.28.41 are receiving traffic.

I'll look into these 2 today, can I know in this case where do I apply the schedule rules, on the WAN ?

Thanks..
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
OPNsense has a default deny rule.
A default deny on Inbound traffic to the Outside/WAN/Internet interface, right?

That will not stop traffic from the Inside/LAN interface going out and it will not stop reply traffic associated with connections that originate from the Inside/LAN.

At least that is how most firewalls work and how PFSense worked last I tried it and Opnsense is a fork of PFSense so they are probably very similar in that regard.


I think the question got lost amidst all the screenshots which I had put so the whole scenarios can be understood, I think it got overwhelming instead.

The issue is that the Server 10.0.64.42 seems to be getting internet even outside the schedule

Yes, that is what I thought the problem was, you're trying to use Opnsense to prevent a device on the LAN inside the Opnsense firewall from reaching the internet other than during a scheduled window right?


My network involves 1 Bridge, 1 NAT and a couple of Host-Only network in VMware Workstation while another network runs on Dell Server.

Now everyone is assuming that as I have a Bridge I'd automatically have internet connection over the Bridged NIC, but this is not the case as my Bridging is on the Ethernet NIC connected to Dell and NOT the WiFi that's why I have a NAT to get internet.

But what's going on is only when I block all internet traffic on the Bridge, NAT, and Server interfaces, only then all internet access stops to the Servers.

That's not what everyone is assuming, or at least not what I was assuming. The networks on the various workstation setups are not really relevant to the Opnsense firewall. The firewall appears to be permitting the traffic that you want to deny during a certain schedule, that means the Opnsense firewall is not configured correctly to do what you want.

Now, of course, the rest of the network design enters into the equation eventually but I would first look at the firewall and figure out why you can't get it to block traffic properly or at least how you are supposed to do so.

Your Bridge, NAT and Host-Only networks don't exist for the Opnsense, they are only on the VMWare workstation config, unless you have also created multiple interfaces in Opnsense that connect to those networks (which you can't for the Host-Only network as that is a Host-Only network ;) unless the Opnsense firewall is running on the same host...?).

Understanding the order of processing is important. I assume Opnsense is probably the same as PFSense for order of processing. If you have better docs for Opnsense then go with those but PFSense shows the following:

https://docs.netgate.com/pfsense/en/lat ... order.html

Floating rules are a special case and you might want to stay away from those for basic setup until you are more familiar with how things work in the basic setup. Do your rules on interfaces so you know how stuff works and then get fancy later.

For blocking internet access for a device on the LAN network interface, I would think you want to apply a rule to block it on the LAN interface. You block the source address from sending data out through the LAN interface. That should do it. Try without a schedule first and if it blocks it from the internet then you know you are good and you can apply the schedule and see if it comes back during the scheduled time. Make the schedule allow it while you are testing and then change the schedule once you know things work properly.
 

tryllz

Smack-Fu Master, in training
61
Thanks @Frennzy for making me understand why the rules implemented weren't working, it certainly seems to be due to NAT being applied.

Thanks @Paladin for detailing it out.

For now I have stopped internet traffic with schedule by applying a block rule on both IN and OUT of WAN interface but for all traffic. Setting source and destination did not have any effect so I blocked out everything.

Not sure if I can explain the below small issue in a simple fashion.

In short Web GUI of ESXi being access across the network is slow load but only on 1 side (server side)

Just something I noticed is that ESXi's running on Server when accessed via Web GUI from VM in Workstation, the pages load too slow. However, ESXi's running on Workstation when accessed via a Web GUI from a VM running on the Dell Server, pages load quickly, even though in both cases the pages are being loaded across the network!.

But the issue is ESXi's running on Dell Server when accessed via Web GUI via Web GUI from a VM also running on the Dell Server, the pages also load too slow even though they are behind the same firewall on the same Server.

I could think of 3 possibilities, just not sure which one causing the pages to load too slow.

1 - Misconfiguration in the Firewall or DNS server causing it to forward query to the internet instead of resolving it locally
2 - Because the DNS server is being access across the network (I doubt this would cause the pages to load slowly, just assuming)
3 - Because the Server has HDD and not SSD

How can I find if the issue is from the firewall or the DNS, or just due to HDD ?

Thank You
 

tryllz

Smack-Fu Master, in training
61
Yeah.... I have no idea what you just said.

What is slow? How slow is slow compared to fast?
I'm accessing an ESXi's login page from across the network. The ESXi is running on Dell, and is being accessed from Workstation, and the login page takes about 30 to 50 secs to load.

But when I access login page of ESXi which is running Workstation, from Dell server it loads within seconds.

I better add screenshots of the page loading so its easier to understand..
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
10.0.64.74 esxi login page from 192.168.28.40 windows browser the pages take up to 50 secs to load.
OK, I would start with that. Ping 10.0.64.74 from 192.168.28.40 for at least 30-60 seconds and see if you get any packet loss. Then do it again with large packets (over 1300 bytes in size) and see if you get any loss. See the ping command help output for the options to set the size.

192.168.64.74 esxi login page from 10.0.64.40 windows browser the pages load within secs
Those is a totally different scenario that sounds completely unrelated to the first scenario.

Set that aside and ignore it for now.

Test loading 10.0.64.74 from multiple different systems. Load it completely on one, log out and then load it completely on a different system and keep trying different systems until you are either sure it is always slow no matter what system you use to load the web page or you can establish which ones are fast and which are slow and what is different between the slow and fast clients.
 

tryllz

Smack-Fu Master, in training
61
So I got ping replies from 60 secs from both ends as follows, no ping drops..

Code:
ping /n 5000 /l 1500 10.0.64.74

Pinging 10.0.64.74 with 1500 bytes of data:
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=3ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62
Reply from 10.0.64.74: bytes=1500 time=4ms TTL=62

Ping statistics for 10.0.64.74:
    Packets: Sent = 50, Received = 50, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 3ms, Maximum = 4ms, Average = 3ms

Code:
ping /n 5000 /l 1500 192.168.28.40

Pinging 192.168.28.40 with 1500 bytes of data:
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=5ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=5ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=3ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=3ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=5ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=5ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=5ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=3ms TTL=126
Reply from 192.168.28.40: bytes=1500 time=4ms TTL=126

Ping statistics for 192.168.28.40:
    Packets: Sent = 63, Received = 63, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 3ms, Maximum = 5ms, Average = 4ms

I'll try 10.0.64.74 from a different system..
 

tryllz

Smack-Fu Master, in training
61
Traceroute from Server to Client
Code:
[root@esxi1s:~] traceroute 192.168.28.40
traceroute to 192.168.28.40 (192.168.28.40), 30 hops max, 40 byte packets
 1  10.0.64.67 (10.0.64.67)  0.796 ms  0.869 ms  0.685 ms
 2  192.168.1.21 (192.168.1.21)  2.187 ms  2.747 ms  2.874 ms
 3  servermdc (192.168.28.40)  3.475 ms  3.752 ms  3.408 ms


Traceroute from Client to Server
Code:
tracert 10.0.64.74
Tracing route to esxi1s.vlab.lab [10.0.64.74]
over a maximum of 30 hops:

  1    <1 ms    <1 ms    <1 ms  192.168.28.35
  2     3 ms     3 ms     3 ms  192.168.1.31
  3     3 ms     3 ms     3 ms  esxi1s.vlab.lab [10.0.64.74]

Not sure but just adding, the laptop does not have an Ethernet NIC, I'm using a USB 2.0 to 10/100 Ethernet LAN, while the Server has a 10/100/1000 Gigabit Ethernet LAN.
 

tryllz

Smack-Fu Master, in training
61
I did a tcpdump on NIC of firewall VMs on both Laptop and Dell Server to see if anything is traversing delaying the packets when I use web browser. I got the below which I didn't understand what it is as there was nothing no network traffic initiated by me.

The below is just some text I took, there is a lot of these packets flowing rapidly.

The IP 192.168.1.25 is the laptop's NIC IP address.

Interface of Firewall VM on Laptop
Code:
root@firewallsm:~ # tcpdump -i em0 host 192.168.1.21 -n
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on em0, link-type EN10MB (Ethernet), capture size 262144 bytes
18:34:53.051214 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 4218103046:4218103234, ack 1055845067, win 513, length 188
18:34:53.051351 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 188, win 4101, length 0
18:34:53.051722 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 188:456, ack 1, win 513, length 268
18:34:53.052019 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 456:604, ack 1, win 513, length 148
18:34:53.052179 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 604, win 4106, length 0
18:34:53.052520 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 604:848, ack 1, win 513, length 244
18:34:53.052785 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 848:996, ack 1, win 513, length 148
18:34:53.052922 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 996, win 4104, length 0
18:34:53.053143 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 996:1240, ack 1, win 513, length 244
18:34:53.053475 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 1240:1388, ack 1, win 513, length 148
18:34:53.053555 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 1388, win 4103, length 0
18:34:53.053717 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 1388:1632, ack 1, win 513, length 244
18:34:53.053844 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 1632:1780, ack 1, win 513, length 148
18:34:53.053940 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 1780, win 4101, length 0
18:34:53.054078 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 1780:2024, ack 1, win 513, length 244
18:34:53.054205 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2024:2172, ack 1, win 513, length 148
18:34:53.054277 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 2172, win 4106, length 0
18:34:53.054494 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2172:2416, ack 1, win 513, length 244
18:34:53.054700 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2416:2564, ack 1, win 513, length 148
18:34:53.054758 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 2564, win 4104, length 0
18:34:53.054867 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2564:2808, ack 1, win 513, length 244
18:34:53.055000 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2808:2956, ack 1, win 513, length 148
18:34:53.055056 IP 192.168.1.25.59346 > 192.168.1.21.22: Flags [.], ack 2956, win 4103, length 0
18:34:53.055161 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 2956:3200, ack 1, win 513, length 244
18:34:53.055294 IP 192.168.1.21.22 > 192.168.1.25.59346: Flags [P.], seq 3200:3348, ack 1, win 513, length 148

Interface of Firewall VM on Dell Server
Code:
root@firewallsm:~ # tcpdump -i vmx0 host 192.168.1.31 -n
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on vmx0, link-type EN10MB (Ethernet), capture size 262144 bytes
18:36:42.419721 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3277660158:3277660346, ack 306397935, win 513, length 188
18:36:42.420237 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 188:360, ack 1, win 513, length 172
18:36:42.420571 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 360:508, ack 1, win 513, length 148
18:36:42.420885 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 508:656, ack 1, win 513, length 148
18:36:42.421206 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 656:804, ack 1, win 513, length 148
18:36:42.421516 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 804:952, ack 1, win 513, length 148
18:36:42.421837 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 952:1100, ack 1, win 513, length 148
18:36:42.422285 IP 192.168.1.25.59352 > 192.168.1.31.22: Flags [.], ack 952, win 513, length 0
18:36:42.422372 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1100:1248, ack 1, win 513, length 148
18:36:42.422708 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1248:1492, ack 1, win 513, length 244
18:36:42.423048 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1492:1640, ack 1, win 513, length 148
18:36:42.423357 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1640:1788, ack 1, win 513, length 148
18:36:42.423666 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1788:1936, ack 1, win 513, length 148
18:36:42.423998 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 1936:2084, ack 1, win 513, length 148
18:36:42.424278 IP 192.168.1.25.59352 > 192.168.1.31.22: Flags [.], ack 1788, win 510, length 0
18:36:42.424449 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2084:2328, ack 1, win 513, length 244
18:36:42.424768 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2328:2476, ack 1, win 513, length 148
18:36:42.425098 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2476:2624, ack 1, win 513, length 148
18:36:42.425407 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2624:2772, ack 1, win 513, length 148
18:36:42.425727 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2772:2920, ack 1, win 513, length 148
18:36:42.426106 IP 192.168.1.25.59352 > 192.168.1.31.22: Flags [.], ack 2772, win 513, length 0
18:36:42.426253 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 2920:3164, ack 1, win 513, length 244
18:36:42.426572 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3164:3312, ack 1, win 513, length 148
18:36:42.426879 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3312:3460, ack 1, win 513, length 148
18:36:42.427197 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3460:3608, ack 1, win 513, length 148
18:36:42.427505 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3608:3756, ack 1, win 513, length 148
18:36:42.427812 IP 192.168.1.31.22 > 192.168.1.25.59352: Flags [P.], seq 3756:3904, ack 1, win 513, length 148
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
Out of order and retransmission on a LAN usually indicates links with serious problems or overusage (not enough bandwidth).

In the case of your setup, I would suspect a problem with the virtualization software interfering with the network, probably the workstation software doesn't play well with your hardware and packets end up buffered, dropped etc.
 

tryllz

Smack-Fu Master, in training
61
Out of order and retransmission on a LAN usually indicates links with serious problems or overusage (not enough bandwidth).

In the case of your setup, I would suspect a problem with the virtualization software interfering with the network, probably the workstation software doesn't play well with your hardware and packets end up buffered, dropped etc.
Any solution to this?

Also could it be due to the Server NIC supporting 10/100/1000Gbps while the laptop NIC supporting only 10/100Mbps causing a bottleneck when it comes to bandwidth ?!

Based on your reply, if I just ran the network completely on the physical server with little to no traffic traversing the laptop, that should solve retransmission issue, specially if the above is true..
 

tryllz

Smack-Fu Master, in training
61
On a similar note,

I have set the following rule on NTP on the WAN interface

WAN/NAT interface - 192.168.47.2 / 24 (NAT is being applied on the interface)
Firewall Interface - 192.168.1.21 / 24

Rules.png


and the rule seems to be working and WAN interface is receiving NTP packets

NTP3.png


However, no NTP information shows up in the dashboard, and the firewall interface does not receive any update of NTP packets.

NTP1.png


NTP2.png


NTP4.png


Any thoughts what is going on ?

Thank You
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
It depends on your design.

Personally, I would allow whatever server you consider to be most 'reliable' to serve as NTP server for your network. Allow that server to connect outbound to any NTP server on the internet (pool.ntp.org servers) and make sure it gets going and synchronized. Make sure that server is running NTP service and configure its software firewall to allow NTP connections from your LAN IPs.

Then have everything else in your network use that chosen server as an NTP server.

That or just allow everything on your LAN IPs out through the firewalls to connect to NTP servers on the internet. No need to restrict clients that just want to lookup the time. Inbound NTP connections from the internet to your stuff on the LAN should be blocked unless you intend to run an NTP server for public use.
 

tryllz

Smack-Fu Master, in training
61
It depends on your design.

Personally, I would allow whatever server you consider to be most 'reliable' to serve as NTP server for your network. Allow that server to connect outbound to any NTP server on the internet (pool.ntp.org servers) and make sure it gets going and synchronized. Make sure that server is running NTP service and configure its software firewall to allow NTP connections from your LAN IPs.

Then have everything else in your network use that chosen server as an NTP server.

That or just allow everything on your LAN IPs out through the firewalls to connect to NTP servers on the internet. No need to restrict clients that just want to lookup the time. Inbound NTP connections from the internet to your stuff on the LAN should be blocked unless you intend to run an NTP server for public use.
The firewall I'm using it the one to be used as NTP server for all devices in the network.
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
In that case I am surprised the rule prevents the firewall itself from making NTP connections outbound to the internet. Generally firewall rules affect connections *through* the firewall, not connections made by the firewall.

I think you would have to do some log digging or see more detail from the firewall itself to see why it is not happy with the NTP servers it is trying to talk to. You might have to go to the command line to see if the NTP service is actually running and see if it has any more debug info about what is wrong with the data it is getting from those servers.

Are you trying to only allow the firewall to connect to NTP servers during a specific window of time?

If so, why?
 

tryllz

Smack-Fu Master, in training
61
In that case I am surprised the rule prevents the firewall itself from making NTP connections outbound to the internet. Generally firewall rules affect connections *through* the firewall, not connections made by the firewall.

I think you would have to do some log digging or see more detail from the firewall itself to see why it is not happy with the NTP servers it is trying to talk to. You might have to go to the command line to see if the NTP service is actually running and see if it has any more debug info about what is wrong with the data it is getting from those servers.
I will definitely dig deeper and see what the issue is.

Are you trying to only allow the firewall to connect to NTP servers during a specific window of time?

If so, why?

No, the NTP rule does not have any schedule set and is suppose to be in touch with the NTP server all the time, the WAN rule is for everything else.

Just thinking, since the firewall also connects to the internet through the same WAN/NAT interface, could this be the reason the schedule is being implemented.

My understanding was any rule above the Block rule would have an effect ?!
 

Paladin

Ars Legatus Legionis
33,855
Subscriptor
You have multiple firewalls in use, I think so you have to be specific on which one you are talking about but generally firewall rules are processed in order somehow. Some firewalls have a preference number, some simply do top down order according to the config display, and some do 'most specific to least specific'. Some do all the block rules first, then the allow rules and simply apply whichever matches the specifics of the connection first.

PFsense uses the following (a bit complex):

https://docs.netgate.com/pfsense/en/lat ... ology.html

One thing that can really help is to look at your firewall rules and see if they can show you how many hits the rule has had. If you've had a rule in place for days and it has 0 hits, you might be better off removing it unless you know you really need it for some reason. I often find people have tons of rules in their firewall that do nothing or don't do what they want/think anyway. Clearing those out can help make it easier to troubleshoot what is left and see what is actually triggering problems. If you see counters increasing on a rule that you think should not be doing something you know there is a problem.