||Home||Switchboard||Unix Administration||Red Hat||TCP/IP Networks||Neoliberalism||Toxic Managers|
|(slightly skeptical) Educational society promoting "Back to basics" movement against IT overcomplexity and bastardization of classic Unix|
|Suse||Recommended Links||Linux Networking|
|Routing||Suse /etc/sysconfig/network/route file||netstat||Suse RC Scripts||Humor||Etc|
In Linux, by default, packets are considered individually for routing purposes. Thus, all the routing algorithm determines where to send a packet based on that packet itself, without taking into consideration that the packet may be a response packet of sorts.
In a typical setup, this means that all outgoing traffic is going out over one interface, say, eth0 even if the incoming packet was sent to interface eth1.
One typical side effect of this algorithm is creation of so called "martian packets". A martian packet is an IP packet which specifies a source or destination address that is either reserved for special-use by Internet Assigned Numbers Authority (IANA) or does not belong to the subnet on which this interface exists, and that makes no sense. [RFC 1812]. For example, if two interfaces are connected to two subnets of 10 network, and default router is configured for eth0, then without expisit routing statement you can't respond to the packet send to eth1, which is not on the local segment for this network.In other words, a martian packet header source IP address is usually a IP address that iether:
For example, a 127.0.0.0/8 IP address coming through a router, would be labeled as being martian, as such packets should be local only and should not travel via the network.
RFC 1812 defines the term a martian source the following way:
"An IP source address is invalid if it is a special IP address, as defined in 188.8.131.52 or 5.3.7, or is not a unicast address."An IP destination address is invalid if it is among those defined as illegal destinations in 184.108.40.206, or is a Class E address (except 255.255.255.255).
"A router SHOULD NOT forward any packet that has an invalid IP source address or a source address on network 0. A router SHOULD NOT forward, except over a loop-back interface, any packet that has a source address on network 127. A router MAY have a switch that allows the network manager to disable these checks. If such a switch is provided, it MUST default to performing the checks.
"A router SHOULD NOT forward any packet that has an invalid IP destination address or a destination address on network 0. A router SHOULD NOT forward, except over a loop-back interface, any packet that has a destination address on network 127. A router MAY have a switch that allows the network manager to disable these checks. If such a switch is provided, it MUST default to performing the checks.
"If a router discards a packet because of these rules, it SHOULD log at least the IP source address, the IP destination address, and, if the problem was with the source address, the physical interface on which the packet was received and the link Layer address of the hostor router from which the packet was received."
Martian source is network traffic from the wrong subnet appearing on an interface. For example if:
eth0 has IP 192.168.0.1 on subnet 255.255.255.0 eth1 has IP 192.168.1.1 on subnet 255.255.255.0
This means that eth0 should only see IP traffic from IP addresses from its subnet (192.168.0.x) and eth1 should only see traffic from its subnet (192.168.1.x)
If an IP on the network (say a forgotten printer or something) is still configured with a previous network address (220.127.116.11) and is seen on eth1 it will be seen as martian source.
If one of the machines on the network 192.168.0.x is plugged into the wrong switch and is effectively on the same network segment (physical) as eth1, then you will see martian source from that IP address (or you have multiple networks that the Linux box is not aware of)
Martian source is not a major thing, but such messages help making you aware of the fact that something in your network setup is either setup incorrectly, or not configured optimally.
We observed strange change of behavior between kernel 18.104.22.168-0.54.5-smp and 22.214.171.124-0.68.1-smp (64-bit):
Previously on old kernel (SLES 10 SP3 126.96.36.199-0.54.5-smp) our eth1 interface (backup segment) was reachable from our workstations. With newer kernel (for example 188.8.131.52-0.68.1-smp on SLES 10 SP3) it is not and "martian source" warnings can be found in the log. For example:
Mar 30 16:19:23 nti247 kernel: printk: 2 messages suppressed. Mar 30 16:19:23 nti247 kernel: martian source 10.201.29.247 from 10.194.154.73, on dev eth1
Mar 30 16:19:23 nti247 kernel: ll header: 00:18:8b:30:cd:2f:00:0c:f8:9b:82:0a:08:00
Only SLES server are behaving this way starting from approximately with the kernel version 184.108.40.206-0.68.1 on SLES 10 SP3. Red Hat and Solaris servers on the same segment behave "permissively".
This behavior is controlled by pretty obscure setting in /etc/sysctl.conf
# Controls source route verification net.ipv4.conf.default.rp_filter = 1
You can disable it changing the value to zero (please don't forget to run sysctl -p command to make those settings current).
# Controls source route verification net.ipv4.conf.default.rp_filter = 0
As of April 2012 this fix works for (patched) SLES 10 SP3, SLES 10 SP4 and SLES 11 SP1. Does not work for SLES 11 SP2.
The reasoning behind the strict ingress filtering that is enabled by net.ipv4.conf.default.rp_filter = 1 setting is protection from spoofing of source address (typical for UDP Distributed Denial of Service Attacks).
I keep getting these messages in /var/log/messages :Mar 8 23:17:25 saas1 kernel: martian source 169.254.1.1 from 169.254.95.118, on dev usb0 Mar 8 23:17:25 saas1 kernel: ll header: ff:ff:ff:ff:ff:ff:00:21:5e:de:1b:be:08:06
Over and over every 5 seconds there's another report exactly the same way.
I did a whois on 169.254.95.118 and get a strange message back also:
This is the "link local" block. It was set aside for this special use in the Standards Track document, RFC 3927 and was further documented in the Best Current Practice RFC 5735, which can be found at: http://www.rfc-editor.org/rfc/rfc3927.txt http://www.rfc-editor.org/rfc/rfc5735.txt It is allocated for communication between hosts on a single link. Hosts obtain these addresses by auto-configuration, such as when a DHCP server cannot be found. A router MUST NOT forward a packet with an IPv4 Link-Local source or destination address, irrespective of the router's default route configuration or routes obtained from dynamic routing protocols. A router which receives a packet with an IPv4 Link-Local source or destination address MUST NOT forward the packet. This prevents forwarding of packets back onto the network segment from which they originated, or to any other segment.
On Monday 02 August 2004 08:45, Paolo Santancini wrote:
> Hi all,
> anybody can give me information about the kernel message called "martian
> source" written in "/var/log/messages"??? What does it mean?
Martian source is network traffic from the wrong subnet appearing on an
eg. eth0 has IP 192.168.0.1 on subnet 255.255.255.0
eth1 has IP 192.168.1.1 on subnet 255.255.255.0
This means that eth0 should only see IP traffic from IP addresses from its
subnet (192.168.0.x) and eth1 should only see traffic from its subnet
If an IP on the network (say a forgotten printer or something) is still
configured with a previous network address (220.127.116.11) and is seen on eth1
it will be seen as martian source.
If one of the machines on the network 192.168.0.x is plugged into the wrong
switch and is effectively on the same network segment (physical) as eth1,
then you will see martian source from that IP address (or you have multiple
networks that the Linux box is not aware of)
Martian source is not a major thing, but it is making you aware of the fact
that something in your network setup is either setup incorrectly, or not
Hi, (minor update) See /usr/src/linux/Documentation/networking/ip-sysctl.txt for an explanation of parameters that can be set for networking, specifically "log_martians". The current settings can be found by typing (as root): sysctl -a | grep martian (if there multiple interfaces their will be an entry for each one net.ipv4.conf.XXXXX.log_martians plus the "default" and "all"). Two way to implement this: 1. From the command line (needs to be re-done each time you reboot): echo 0 >/proc/sys/net/ipv4/conf/all/log_martians echo 0 >/proc/sys/net/ipv4/conf/default/log_martians echo 0 >/proc/sys/net/ipv4/conf/eth1/log_martians 2. Automatically at startup, by editing /etc/sysctl.conf and adding: net.ipv4.conf.default.log_martians = 0 net.ipv4.conf.all.log_martians = 0 To activate the changes without rebooting type: /etc/rc.d/boot.sysctl start echo 0 >/proc/sys/net/ipv4/conf/eth1/log_martians The latter echo is necessary without a reboot as the default setting will only apply when an inteface is brought up. Rgds, Simon -----Original Message----- From: Tarjei Huse [mailto:tarjei+a_lists.suse@xxxxx] Sent: Tuesday, August 02, 2005 12:57 To: suse-security@xxxxxxxx Subject: [suse-security] Martian problems Hi, I'm having problems with a SuSE 9.2 box. The box is set up with two interfaces on the same subnet. The interfaces has been set up as normal with static ip's 10.9.1.3, 10.9.1.2 , netmask 255.255.255.0 and broadcast 10.9.1.255. I'm getting errormessages saying Aug 2 12:33:41 mail2 kernel: martian source 10.9.1.255 from 10.9.1.3, on dev eth1 Aug 2 12:33:41 mail2 kernel: ll header: ff:ff:ff:ff:ff:ff:00:c0:9f:2c:2d:f7:08:00 Is this related to the usage of two nics on the same subnet? If so, is there a way to solve this? It seems the martians are stopping cups from doing broadcasts. Kind regards, Tarjei -- Check the headers for your unsubscription address For additional commands, e-mail: suse-security-help@xxxxxxxx Security-related bug reports go to security@xxxxxxx, not here
Google matched content
allow 'martian source'
Groupthink : Two Party System as Polyarchy : Corruption of Regulators : Bureaucracies : Understanding Micromanagers and Control Freaks : Toxic Managers : Harvard Mafia : Diplomatic Communication : Surviving a Bad Performance Review : Insufficient Retirement Funds as Immanent Problem of Neoliberal Regime : PseudoScience : Who Rules America : Neoliberalism : The Iron Law of Oligarchy : Libertarian Philosophy
War and Peace : Skeptical Finance : John Kenneth Galbraith :Talleyrand : Oscar Wilde : Otto Von Bismarck : Keynes : George Carlin : Skeptics : Propaganda : SE quotes : Language Design and Programming Quotes : Random IT-related quotes : Somerset Maugham : Marcus Aurelius : Kurt Vonnegut : Eric Hoffer : Winston Churchill : Napoleon Bonaparte : Ambrose Bierce : Bernard Shaw : Mark Twain Quotes
Vol 25, No.12 (December, 2013) Rational Fools vs. Efficient Crooks The efficient markets hypothesis : Political Skeptic Bulletin, 2013 : Unemployment Bulletin, 2010 : Vol 23, No.10 (October, 2011) An observation about corporate security departments : Slightly Skeptical Euromaydan Chronicles, June 2014 : Greenspan legacy bulletin, 2008 : Vol 25, No.10 (October, 2013) Cryptolocker Trojan (Win32/Crilock.A) : Vol 25, No.08 (August, 2013) Cloud providers as intelligence collection hubs : Financial Humor Bulletin, 2010 : Inequality Bulletin, 2009 : Financial Humor Bulletin, 2008 : Copyleft Problems Bulletin, 2004 : Financial Humor Bulletin, 2011 : Energy Bulletin, 2010 : Malware Protection Bulletin, 2010 : Vol 26, No.1 (January, 2013) Object-Oriented Cult : Political Skeptic Bulletin, 2011 : Vol 23, No.11 (November, 2011) Softpanorama classification of sysadmin horror stories : Vol 25, No.05 (May, 2013) Corporate bullshit as a communication method : Vol 25, No.06 (June, 2013) A Note on the Relationship of Brooks Law and Conway Law
Fifty glorious years (1950-2000): the triumph of the US computer engineering : Donald Knuth : TAoCP and its Influence of Computer Science : Richard Stallman : Linus Torvalds : Larry Wall : John K. Ousterhout : CTSS : Multix OS Unix History : Unix shell history : VI editor : History of pipes concept : Solaris : MS DOS : Programming Languages History : PL/1 : Simula 67 : C : History of GCC development : Scripting Languages : Perl history : OS History : Mail : DNS : SSH : CPU Instruction Sets : SPARC systems 1987-2006 : Norton Commander : Norton Utilities : Norton Ghost : Frontpage history : Malware Defense History : GNU Screen : OSS early history
The Peter Principle : Parkinson Law : 1984 : The Mythical Man-Month : How to Solve It by George Polya : The Art of Computer Programming : The Elements of Programming Style : The Unix Haterís Handbook : The Jargon file : The True Believer : Programming Pearls : The Good Soldier Svejk : The Power Elite
Most popular humor pages:
Manifest of the Softpanorama IT Slacker Society : Ten Commandments of the IT Slackers Society : Computer Humor Collection : BSD Logo Story : The Cuckoo's Egg : IT Slang : C++ Humor : ARE YOU A BBS ADDICT? : The Perl Purity Test : Object oriented programmers of all nations : Financial Humor : Financial Humor Bulletin, 2008 : Financial Humor Bulletin, 2010 : The Most Comprehensive Collection of Editor-related Humor : Programming Language Humor : Goldman Sachs related humor : Greenspan humor : C Humor : Scripting Humor : Real Programmers Humor : Web Humor : GPL-related Humor : OFM Humor : Politically Incorrect Humor : IDS Humor : "Linux Sucks" Humor : Russian Musical Humor : Best Russian Programmer Humor : Microsoft plans to buy Catholic Church : Richard Stallman Related Humor : Admin Humor : Perl-related Humor : Linus Torvalds Related humor : PseudoScience Related Humor : Networking Humor : Shell Humor : Financial Humor Bulletin, 2011 : Financial Humor Bulletin, 2012 : Financial Humor Bulletin, 2013 : Java Humor : Software Engineering Humor : Sun Solaris Related Humor : Education Humor : IBM Humor : Assembler-related Humor : VIM Humor : Computer Viruses Humor : Bright tomorrow is rescheduled to a day after tomorrow : Classic Computer Humor
The Last but not Least Technology is dominated by two types of people: those who understand what they do not manage and those who manage what they do not understand ~Archibald Putt. Ph.D
Copyright © 1996-2021 by Softpanorama Society. www.softpanorama.org was initially created as a service to the (now defunct) UN Sustainable Development Networking Programme (SDNP) without any remuneration. This document is an industrial compilation designed and created exclusively for educational use and is distributed under the Softpanorama Content License. Original materials copyright belong to respective owners. Quotes are made for educational purposes only in compliance with the fair use doctrine.
FAIR USE NOTICE This site contains copyrighted material the use of which has not always been specifically authorized by the copyright owner. We are making such material available to advance understanding of computer science, IT technology, economic, scientific, and social issues. We believe this constitutes a 'fair use' of any such copyrighted material as provided by section 107 of the US Copyright Law according to which such material can be distributed without profit exclusively for research and educational purposes.
This is a Spartan WHYFF (We Help You For Free) site written by people for whom English is not a native language. Grammar and spelling errors should be expected. The site contain some broken links as it develops like a living tree...
|You can use PayPal to to buy a cup of coffee for authors of this site|
Last modified: March 12, 2019