Skip to contentSkip to conversation

Iptables, timestart and timestop arguments and daylight saving time in UK

DISCUSSION Sebastian Arcus 2 participants 4 messages Apr 13, 2011

lore
Share & tools
lore
#0 lore raw

Bump

Anybody?

-------- Original Message --------
Subject: Iptables, timestart and timestop arguments and daylight saving time in UK
Date: Tue, 29 Mar 2011 14:47:07 +0100
From: Sebastian Arcus <[email protected]>
To: [email protected]

Hi all,

The clock changed over the weekend in the UK by one hour (daylight
saving time). I have a setup where I block some MAC addresses access to the Internet based on time, using iptables, "timestart" and "timestop" arguments. The command is the following:

iptables -A FORWARD -p ALL -o eth0 -m mac --mac-source $BLOCKED_MAC1 \
-m time --timestart 13:00 --timestop 12:00 -j DROP

After the weekend, the server kept on blocking as per the old winter time. I checked the server time with the "date" command and the time on the client machine (Windows XP) - and in both places the clock is updated as per new time / summer time. The iptables on server kept on blocking according to winter time for two days. Even restarting the iptables script (which flushes the tables) didn't make a different. Finally, when I restarted the whole server, it started blocking according to new summer time. Here is the setup:

Client: Windows XP Home
Server: Slackware 13.0
Kernel: 2.6.29.6
Iptables: 1.4.3.2

Is this a known bug in the kernel, or am I doing something wrong?

Thanks for any contributions,

Sebastian

#1 lore raw
Quoted 3 lines · Sebastian Arcus

Bump

Anybody?

See http://bugs.debian.org/615121

Quoted 42 lines

-------- Original Message --------
Subject: Iptables, timestart and timestop arguments and daylight saving time in UK
Date: Tue, 29 Mar 2011 14:47:07 +0100
From: Sebastian Arcus <[email protected]>
To: [email protected]

Hi all,

The clock changed over the weekend in the UK by one hour (daylight saving time). I have a setup where I block some MAC addresses access to the Internet based on time, using iptables, "timestart" and "timestop" arguments. The command is the following:

iptables -A FORWARD -p ALL -o eth0 -m mac --mac-source $BLOCKED_MAC1 \
-m time --timestart 13:00 --timestop 12:00 -j DROP

After the weekend, the server kept on blocking as per the old winter time. I checked the server time with the "date" command and the time on the client machine (Windows XP) - and in both places the clock is updated as per new time / summer time. The iptables on server kept on blocking according to winter time for two days. Even restarting the iptables script (which flushes the tables) didn't make a different. Finally, when I restarted the whole server, it started blocking according to new summer time. Here is the setup:

Client: Windows XP Home
Server: Slackware 13.0
Kernel: 2.6.29.6
Iptables: 1.4.3.2

Is this a known bug in the kernel, or am I doing something wrong?

Thanks for any contributions,

Sebastian
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#2 lore raw
Quoted 8 lines · Jan Engelhardt
Quoted 3 lines · Sebastian Arcus

Bump

Anybody?

See http://bugs.debian.org/615121

Thank you for that. From reading the bug report, I take it there is no solution for it but to restart the server/machine in question after each DST change?

Thanks,

Sebastian

#3 lore raw
Quoted 7 lines · Sebastian Arcus
Quoted 4 lines · Jan Engelhardt
Quoted 2 lines · Sebastian Arcus

Bump

Quoted 8 lines
Quoted 4 lines
Quoted 1 line

Anybody?

See http://bugs.debian.org/615121

Thank you for that. From reading the bug report, I take it there is no solution for it but to restart the server/machine in question after each DST change?

Solution is to just always use UTC.