
Internet upside down
Good afternoon, approaching April 1, and I really would not want this day to be the same as the rest, so I offer a special, IT fun. This is a translation of an article accidentally found on the Internet, in fact, translated it a11aud , but he lacks karma for the post, so I write (a11aud will be very grateful for karma :))
My neighbors are stealing my wireless internet. Yes, I could start encrypting, but you can get a lot of pleasure from the contemplation of perplexity on their faces!
I started by dividing the network into two parts: trusted and untrusted. The trustee had its share of the network, the untrusted had its own. We use a DHCP server to identify poppy addresses for separation into appropriate groups.
/etc/dhcpd.conf
Suddenly, everything became cats! Koshkanet.
/ sbin / iptables -A PREROUTING -s 192.168.0.0/255.255.255.0 -p tcp -j DNAT --to-destination 64.111.96.38
For the uninitiated, this redirects all traffic to kittenwar
PS I suggest http: // www .koshkimira.ru /
For added fun, you can configure iptables to forward everything to a transparent squid proxy running on port 80.
/ sbin / iptables -A PREROUTING -s 192.168.0.0/255.255.255.0 -p tcp -m tcp --dport 80 -j DNAT --to-destination 192.168.0.1 Squid is turned
on this car with a banal redirect that downloads pictures, uses a modifier to flip them upside down and extends beyond the local web server.
Actually, the script itself:


And if you try the "-blur 4" vagueness effect, you will get "vague"!

Original
1) Introduction
My neighbors are stealing my wireless internet. Yes, I could start encrypting, but you can get a lot of pleasure from the contemplation of perplexity on their faces!
2) Share the network!
I started by dividing the network into two parts: trusted and untrusted. The trustee had its share of the network, the untrusted had its own. We use a DHCP server to identify poppy addresses for separation into appropriate groups.
/etc/dhcpd.conf
ddns-updates off;
ddns-update-style interim;
authoritative;
shared-network local {
subnet *.*.*.* netmask 255.255.255.0 {
range *.*.*.* *.*.*.*;
option routers *.*.*.*;
option subnet-mask 255.255.255.0;
option domain-name "XXXXX";
option domain-name-servers *.*.*.*;
deny unknown-clients;
host trusted1 {
hardware ethernet *:*:*:*:*:*;
fixed-address *.*.*.*;
}
}
subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.2 192.168.0.10;
option routers 192.168.0.1;
option subnet-mask 255.255.255.0;
option domain-name-servers 192.168.0.1;
allow unknown-clients;
}
}
* This source code was highlighted with Source Code Highlighter.
3) IPtables - it's funny!
Suddenly, everything became cats! Koshkanet.
/ sbin / iptables -A PREROUTING -s 192.168.0.0/255.255.255.0 -p tcp -j DNAT --to-destination 64.111.96.38
For the uninitiated, this redirects all traffic to kittenwar
PS I suggest http: // www .koshkimira.ru /
For added fun, you can configure iptables to forward everything to a transparent squid proxy running on port 80.
/ sbin / iptables -A PREROUTING -s 192.168.0.0/255.255.255.0 -p tcp -m tcp --dport 80 -j DNAT --to-destination 192.168.0.1 Squid is turned
on this car with a banal redirect that downloads pictures, uses a modifier to flip them upside down and extends beyond the local web server.
Actually, the script itself:
#!/usr/bin/perl
$|=1;
$count = 0;
$pid = $$;
while (<>) {
chomp $_;
if ($_ =~ /(.*\.jpg)/i) {
$url = $1;
system("/usr/bin/wget", "-q", "-O","/space/WebPages/images/$pid-$count.jpg", "$url");
system("/usr/bin/mogrify", "-flip","/space/WebPages/images/$pid-$count.jpg");
print "http://127.0.0.1/images/$pid-$count.jpg\n";
}
elsif ($_ =~ /(.*\.gif)/i) {
$url = $1;
system("/usr/bin/wget", "-q", "-O","/space/WebPages/images/$pid-$count.gif", "$url");
system("/usr/bin/mogrify", "-flip","/space/WebPages/images/$pid-$count.gif");
print "http://127.0.0.1/images/$pid-$count.gif\n";
}
else {
print "$_\n";;
}
$count++;
}
* This source code was highlighted with Source Code Highlighter.
4) And the Internet began to look like this!


And if you try the "-blur 4" vagueness effect, you will get "vague"!

Original