Уважаемые коллеги !
Поздравляем вас с наступлением нового 2009 года !
Желаем вам в новом году успешных реализаций всех ваших проектов, поменьше багов, успешно «бегающих» пакетов и новых знаний !
С уважением, коллектив subnets.ru

Сети, настройка оборудования, сетевые сервисы.
![]() |
|
||||||||
Subnets.ru Регистрация IP и Автономных систем mega-net.ru |
Поздравляем вас с наступлением нового 2009 года !
Желаем вам в новом году успешных реализаций всех ваших проектов, поменьше багов, успешно «бегающих» пакетов и новых знаний !
С уважением, коллектив subnets.ru
Все вы, у кого есть своя ASка, получили письмо от RIPE:
From: Andrew de la Haye <noreply@ripe.net>
Subject: 32-bit AS Numbers: A Change Is Coming!
Dear Colleagues,
As of 1 January 2009, the RIPE NCC will begin assigning 32-bit (or four-byte) ASN Numbers (ASNs) by default. This is in accordance with a global
policy agreed on in all Regional Internet Registry (RIR) communities.
When requesting an ASN after 1 January, LIR staff should ensure that 32-bit ASNs will be compatible with their existing networks. Some network
operators may experience difficulties configuring BGP sessions if their or their upstream providers' equipment is not compliant with the new
32-bit standard.
If you believe your network will encounter problems with 32-bit ASNs, it will be possible to specifically request a 16-bit ASN.
For more information, please see, "32-bit Autonomous System Numbers: A Guide for LIRs":
http://www.ripe.net/news/asn-32-guide.html
If you have any questions regarding 32-bit ASNs, please send an email to <contact@ripe.net>.
Regards,
Andrew de la Haye
Chief Operations Officer, RIPE NCC
Один знакомый бросил ссылочку на интересную статейку и мы решили запостить и у нас:
For all the harping I do on this blog about IPv4 address depletion and the need to prepare yourselves for IPv6, there is another number resource that is also being quickly depleted, and that I haven’t written about before: the 2-byte autonomous system numbers (ASNs).
A 16-bit number space gives you 65,536 possible numbers (AS numbers 0 – 65535). Out of these, the IANA reserves 1,026 of them: 64512 – 65534 for private, reusable ASNs (similar to private RFC1918 IPv4 addresses) and a few others such as 0 and 65535 and one that is important to this article, 23456. Presently 49,150 ASNs have been allocated out of the public pool, so there are 15,360 available ASNs remaining: About 23.8 percent of the public pool.
An analysis of the allocation rate of 2-byte ASNs shows that the available pool will run out in mid-2011. Eerily close to the date that we will run out of IPv4 addresses.
Fortunately there is much less cause for concern about ASN depletion than about IPv4 depletion, for two reasons:
This post describes the format of the 4-byte ASN, how it interoperates with 2-byte ASNs, and what you need to do (if anything) to prepare your network for them.
The 4-Byte ASN Format
4-byte ASNs provide 232 or 4,294,967,296 autonomous system numbers ranging from 0 to 4294967295. The first thing to notice about these numbers is that they include all of the older 2-byte ASNs, 0 through 65535. That greatly helps with interoperability between autonomous systems using 2-byte ASNs and those using 4-byte ASNs. (An oft-heard complaint about IPv6 is that interoperability with IPv4 could have been more easily supported if 4.3 billion IPv6 addresses had been reserved as representative of the existing IPv4 addresses, but that’s another story.)
A 4-byte ASN between 0 and 65535 is called a mappable ASN, because it can be represented in just 2 bytes; the first 16 bits are in every case all zeroes.
Stemming from a concern that 32-bit ASNs might be difficult to write and manage, there are three ways of representing 4-byte ASNs:
· asplain is a simple decimal representation of the ASN, from 0 to 4294967295.
· asdot+ breaks the number up into low-order and high-order 16-bit values, separated by a dot. All of the older 2-byte ASNs can be represented in the low-order value, with the high-order value set to 0. So for example, 65535 is 0.65535. One more than that, 65536, is outside the value that can be represented in the low-order range alone, and is therefore represented as 1.0. 65537 would be 1.1, 65680 is 1.144, and so on. You can figure the low- and high-order values by subtracting multiples of 65,536 from the asplain representation of the ASN, with the high-order value representing the multiples of 65536. The ASN 327700, then, is 5.20: Five times 65536 plus 20 more. The largest ASN, 4294967295, is 65535.65535: 65,535 times 65535, plus 65535 more.
· asdot is a mixture of asplain and asdot+. Any ASN in the 2-byte range of 0 – 65535 is written in asplain (so 65535 is written “65535”) and any ASN above that range is written in asdot+ (so 65536 is written “1.0”).
Asplain is obviously the most straightforward method of understanding the new ASNs, although the larger numbers might become unwieldy to write and therefore prone to typographical mistakes in written documentation or router configurations.
Asdot+ is much simpler to write, but harder to calculate from its simple decimal equivalent. If you work in this format regularly, it’s probably worth your time to write a simple script that does the conversions for you to prevent calculation errors.
Asdot might appear to have limited usefulness. After all, it’s not any harder to write “0.3657” than to write “3657”, and the need to do some calculations come in when you go above 65535; asdot does nothing to help you there. There is, however, a subtlety to this. The regional number assignment authorities – the Regional Internet Registries, or RIRs – differentiate a 16-bit number that is an older 2-byte ASN and a mappable 4-byte ASN (again, the set of 32-bit ASNs in which the first 16 bits are all 0). So “3657” is a 2-byte ASN, and “0.3657” is a 4-byte ASN.
This, of course, leads us to look briefly at just what the RIRs’ policies are for assigning 4-byte ASNs.
ASN Allocation Policies
All five of the RIRs (AfriNIC, APNIC, ARIN, LACNIC, and RIPE NCC) have the same assignment policies for 4-byte ASNs:
· 4-byte ASNs have been available since 1 January 2007. The default assignment, if you request an ASN, is to give you a 2-byte ASN and only assign a 4-byte ASN if you specifically request it.
· Beginning on 1 January 2009 (yes, about a month from now!) that policy reverses: A 4-byte ASN will be the default. You can still get a 2-byte ASN, but only if you specifically request it.
· A year later, on 1 January 2010, all ASN assignments will be 4-byte. The ASN you receive might be of the form 0.XX (where the high-order 16 bits are all 0 and the low-order 16 bits are not), but the RIRs will make no distinction between those numbers and any other 4-byte ASN. And although it won’t effect your network in any way, the 16-bit ASN you’ve had maybe for years will, in the eyes of the RIRs, be a mapable 32-bit ASN. For instance, Level3 Communications’ AS3356 becomes in the eyes of the RIRs, at the beginning of 2010, 0.3356.
These policies raise several questions:
· If you plan to request a new ASN assignment starting in 2009, what do you need to do to prepare for it?
· How do the new 4-byte ASNs interoperate with older autonomous systems using 2-byte ASNs?
· If you have an existing 2-byte ASN, does anything change?
The ASN’s Role in BGP
A brief review of how BGP uses autonomous system numbers will help in understanding how the new format might impact BGP networks. Most of you already know the basics of BGP; if you do, feel free to skip ahead.
The purpose of BGP, unlike any IGP (OSPF, IS-IS, EIGRP and RIP), is to route between domains under separate administrative control – that is, systems that are autonomous from each other. If you’re going to route between (and among) these autonomous routing domains, you need some way of identifying individual ASs. That identifier is the autonomous system number.
The ASN has two essential functions in BGP:
First, it helps BGP determine the shortest path to a destination. When BGP advertises a route to a neighbor in an Update message, it attaches several path attributes to the route. When a router learns more than one BGP route to the same destination, the BGP decision process evaluates the routes’ path attributes in a prioritized order to decide which of the routes is most preferable. (BGP path attributes can be added, removed, or changed in all sorts of ways to influence the BGP decision process. This is the basis for BGP routing policies.) One of these attributes, attached to every BGP route, is called AS_PATH. When a router advertises a destination within its own AS to a neighbor in another AS, it puts its local ASN in the AS_PATH. As the route is advertised to subsequent autonomous systems, each AS border router adds its own ASN to the attribute. The AS_PATH, then, becomes a list of ASNs that describes the path back to the destination. A router can choose a shortest path by choosing the route with the fewest ASNs listed in its AS_PATH.
The second ASN function is a very simple loop avoidance mechanism. Because a router adds its ASN to the AS_PATH before advertising a route to a neighbor in another AS, a route that loops – that is, exits an AS and is subsequently advertised back to the same AS – is easily detected by examining the AS_PATH. If a router sees its own ASN listed in the AS_PATH of a route advertised to it by a neighbor, it drops the route.
The ASN also appears in a path attribute called the AGGREGATOR. When a number of routes are summarized (aggregated), route details can be lost. The AGGREGATOR attribute can be added to an aggregate route to indicate the Router ID and ASN of the router performing the aggregation. This attribute does not influence the BGP decision process, but it can be useful for tracing back problems with aggregate routes.
A third attribute that uses the ASN is COMMUNITIES. This optional attribute helps you manage routing polices when they apply to a large number of routes; using a number of methods you can assign one or more COMMUNITIES attributes to prefixes, and then apply a routing policy to a community rather than individual routes. For example, you might define a COMMUNITES attribute named Cust_Routes and then add that attribute to all routes advertised into your AS by all your customers. Then anywhere in your network that you need to apply a policy to all of your customer routes, you can apply the policy to routes having the Customer_Routes attribute rather than having to identify each prefix (and possibly change all your prefix lists any time a customer route is added or removed).
The COMMUNITES attribute is a 32-bit value in which the first 16 bits are an ASN and the last 16 bits are arbitrarily assigned by you to have whatever meaning you want.
The important point here is not so much the functions of AGGREGATOR or COMMUNITES, however, but that they, like AS_PATH, are formatted to carry 2-byte ASNs; the formats of these attributes must therefore be adapted to carry the larger 32-bit ASNs.
In addition to these three path attributes the BGP Open message also references the ASN, in a 16-bit field called My Autonomous System. BGP runs on top of a TCP session between neighbors; after the TCP session is established, the neighbors use Open messages to negotiate the BGP session. Each neighbor indicates its Router ID, ASN, the BGP version it is running (always version 4 in modern networks), its hold time (the time it expects to wait for a Keepalive from the neighbor before closing the session) and possibly some optional parameters.
There is alot more to BGP than what has been described here. What is important for this discussion is that there are four BGP data entities that carry ASNs:
· The AS_PATH attribute;
· The AGGREGATOR attribute;
· The COMUNITES attribute; and
· The Open message
Consideration must be given to each of these entities not only in terms of adapting them to 4-byte ASNs but also making the adaptations interoperable with older BGP implementations that only understand 2-byte ASNs.
Neighbor Interoperability
For simplicity, we’ll call BGP implementations supporting 4-byte ASNs New_BGP, and legacy BGP implementations that only support 2-byte ASNs Old_BGP.
The first requirement for a New_BGP implementation is to discover whether a neighbor is New_BGP or Old_BGP. It does this by using the BGP Capability Advertisement when opening a BGP session. In addition to advertising itself as New_BGP, it includes its 4-byte ASN in the Capability advertisement.
If a neighbor responds that it also is a NEW_BGP speaker, the neighbor includes its 4-byte ASN in its own Capability advertisement. Thus two New_BGP neighbors can inform each other of their 4-byte ASNs without using the 2-byte My Autonomous System field in the Open message. (If the neighbors are NEW_BGP but have 2-byte ASNs or mappable 4-byte ASNs, they can still put the ASN in the My Autonomous System field in addition to the Capability advertisement.)
If a neighbor is Old-BGP, it either responds that it does not support the 4-byte ASN capability or does not respond to the Capability advertisement at all. In this case, the New_BGP neighbor can still bring up a session with the Old-BGP neighbor, but cannot advertise its 4-byte ASN. The neighbor wouldn’t understand it. Instead, New_BGP uses a reserved 2-byte ASN, 23456, called AS_TRANS (AS_TRANS is easily remembered because of its 2-3-4-5-6 sequence). This AS number is added to the My Autonomous System field of the Open message. Because AS_TRANS is reserved, no Old_BGP speaker can use it as its own ASN; only New_BGP speakers can use it.
Interoperable peering, then, is achieved because the New_BGP speaker “knows” its neighbor is an Old_BGP speaker and adapts to it; the Old-BGP speaker simply continues using legacy BGP rules.
Path Attribute Interoperability
Because the New_BGP speaker knows whether its neighbor is New_BGP or Old_BGP, it knows what rules to follow when advertising routes to the neighbor.
When advertising routes to a New_BGP neighbor, the AS_PATH attribute is simply modified to carry 4-byte ASNs. But when advertising routes to an Old-BGP neighbor, the AS_PATH must be kept in its legacy format, as a list of 2-byte ASNs; an Old_BGP neighbor would not otherwise know how to interpret the list. Rather than adding its own 4-byte ASN to the AS_PATH, the New_BGP speaker adds the AS_TRANS (again, AS23456) to the AS_PATH as a placeholder for its own and any other 4-byte ASNs appearing on the path. The router also adds a new attribute, AS4_PATH, to the route. This attribute carries the list of real ASNs, both 4-byte and 2-byte. Unlike AS_PATH, which is a mandatory attribute for all routes, AS4_PATH is optional transitive: “Optional” meaning it is only used when needed (and in fact a New_BGP speaker will not use this attribute if the AS_PATH is all 2-byte ASNs), and “transitive” meaning any BGP speaker passes the attribute along to other neighbors even if it doesn’t understand the attribute. Thus, the real autonomous system path can be passed transparently through one or more Old_BGP speakers.
When an Old_BGP speaker advertises a route with both AS_PATH and AS4_PATH attributes to a New_BGP speaker, the New_BGP speaker uses both attributes to reconstruct the path: AS4_PATH to find 4-byte ASNs on the path, and AS_PATH to find any 2-byte ASNs Old_BGP speakers will have added since the path last passed through a New_BGP speaker.
By adding AS_TRANS to the AS_PATH as a placeholder for any 4-byte ASNs along the route, the AS_PATH continues to accurately indicate the number of AS hops along the path, and therefore preserves its role in the BGP decision process. And although the AS_TRANS might wind up appearing multiple times in the AS_PATH, that ASN only has meaning to a New_BGP speaker – which will also use the AS4_PATH to reconstruct the path – so the loop avoidance function is also preserved: If a loop occurs, the New_BGP speaker using a 4-byte ASN will find its ASN in the AS4_PATH and drop the route.
The AGGREGATOR attribute, when it is needed, is modified similarly. A New_BGP speaker advertising a route to a New_BGP neighbor simply uses a modified version of the attribute that can carry a 4-byte ASN. If a New_BGP speaker advertises a route with the attribute to an Old_BGP speaker, and if the attribute contains a 4-byte ASN, the New_BGP speaker replaces the ASN with AS_TRANS and puts the real ASN in a new optional transitive attribute called AS4_AGREGATOR.
A New_BGP speaker receiving a route with AGGREGATOR and AS4_AGGREGATOR attributes from an Old_BGP neighbor replaces the AS_TRANS in the AGGREGATOR with the real 4-byte ASN in the AS4_AGGREGATOR.
BGP communities are supported in 4-byte ASN environments by using a new Extended Community attribute called the 4-Octet AS Specific BGP Extended Community (EXT_COMM). This Extended Community consists of a 4-byte ASN and a 2-byte arbitrary number; that is, the format is the same as the legacy COMMUNITIES attribute except the ASN part is 4 bytes instead of 2 bytes.
Preparing Your Network (Or Not)
All this interoperability that I’ve spent so many paragraphs describing to you means that New_BGP is backwards compatible with Old_BGP. This is good news if you currently run a network with a 2-byte ASN: You don’t need to do very much, at least in the near term, to get ready for 4-byte ASNs. Your AS will continue running just fine, even when New_BGP neighbors start peering with it.
If you will be acquiring a new ASN any time after the end of 2008 – and especially after the end of 2009 – there are a few things you will need to do to get your network ready for 4-byte ASNs.
First, of course, you need to insure that your router operating system supports New_BGP. Right now (the end of November 2008) the best information I can find is that the following OSs have New_BGP:
· Cisco Systems IOS-XR 3.4 and later (CRS only)
· Cisco Systems IOS-NX (“Nexus”)
· Cisco Systems IOS 12.2SRD for 7200 and 7600
· Cisco Systems IOS 12.5T for 1800/2800/3800, 7200, 7300
· Cisco Systems 12.2SB-Rel6 for 7200, 7300, 10000
· Cisco Systems 12.2SX for 6500
· Force 10 Networks FTOS 7.7.1.0 and later
· Juniper Networks’ JUNOS 9.1 and later
· Juniper Networks’ JUNOSe 4.1.0 and later
· OpenBGPD 3.9 and later
· Quagga 0.99.6 and later
· Redback SEOS (all versions)
Finding specifics of feature support on most any vendor’s website is like a hunt for buried treasure but seldom with a reward at the end, so if you know of other operating systems supporting New_BGP – or have corrections to my list here – please do post a comment. If unsure about your own network, check with your vendor representative.
The biggest challenge with upgrading to New_BGP is that by far the largest installed base of router operating systems is Cisco IOS, and as you can see from the list above the current IOS support is all in early technology (T) or service provider (S) releases, and restricted to certain platforms. Hopefully New_BGP finds its way into mainstream IOS code in early 2009.
Other aspects of your network operations that should be assessed for support of the new ASNs are:
· Any address management applications that reference the ASN
· Any BGP analysis or traffic engineering applications
· Potential effects on MPLS-based VPNs that use Route Distinguishers
· Applications that use Internet Route Registries (IRRs) to set or publish policies
· Routing policies that reference ASNs such as AS path filters and community lists
Do Autonomous Systems with 2-Byte ASNs Need to Do Anything?
As I said, if you currently run a network with a 2-byte ASN your network will continue running with no problems. But there is one thing you should do in the short term to prepare: You will see more and more instances of AS_TRANS making their appearance in AS_PATHs, and if you are a service provider multiple customers might begin peering with you using AS_TRANS. You need to be sure that your operators and troubleshooters know what this special ASN is, and that multiple instances of it in a single AS_PATH or multiple customers peering to you using it are not indicative of a problem.
For the longer term, it is a good idea to put New_BGP capability on your list of requirements as you plan for router operating system upgrades. You can upgrade to New_BGP router by router without effecting your network. Once all of your routers support 4-byte ASNs, you should convert your 2-byte ASN to the 4-byte 0.XX format.
Taking these steps will save you some future headaches by eliminating potential confusions caused by AS_TRANS, giving you clearer visibility to newer peers and across AS paths, improving your routing policy capabilities, and preventing roadblocks when you need to exchange EXT_COMM attributes with New_BGP peers.
Like IPv6, 4-byte ASNs are the future of the Internet. Although all 2-byte ASNs allocated before 2010 will continue to exist, they will eventually be just a part of the new 32-bit format rather than a separate type of autonomous system number.
Everyone should give some thought now to what you need to do to be prepared for this.
Участились вопросы по сабжу.
Случается, что сетевая карта в серваке на FreeBSD ну никак не хочет подниматься и вязаться со свичем. Или случаются ситуации когда на порту свича full-duplex, а на сетевой карте FreeBSD его нет и соответственно работает half-duplex, что приводит к ошибкам и потерям. Для исправления ситуации можно попробовать жестко задать скорость и дуплекс.
Рассмотрим метод ручного задания режимов, что приведет к отключению autoselect режима.
Все выполняется командой ifconfig с использованием опций:
Посмотрим состояние сетевой карты em0 ДО изменений:
/sbin/ifconfig em0
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
ether 00:02:a5:4e:92:48
inet 172.16.10.14 netmask 0xffffff00 broadcast 172.16.10.255
media: Ethernet autoselect (100baseTX <full-duplex>)
status: active
Видим что на карте, по умолчанию, работает autoselect.
Принудительно поставим 100baseTX и full-duplex на сетевой карте с именем em0:
/sbin/ifconfig em0 media 100baseTX mediaopt full-duplex
Посмотрим что получилось:
/sbin/ifconfig em0
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
ether 00:02:a5:4e:92:48
inet 172.16.10.14 netmask 0xffffff00 broadcast 172.16.10.255
media: Ethernet 100baseTX <full-duplex>
status: active
Видим, что теперь жестко выставлено 100baseTX и full-duplex.
В случае с гигабитными линками команда ессно та же, но скорость другая:
/sbin/ifconfig em0 media 1000baseTX mediaopt full-duplex
Для того, чтобы после ребута выставленная руками скорость и дуплекс оставались, необходимо внести это в /etc/rc.conf:
ifconfig_em0=»inet 172.16.10.14 netmask 255.255.255.0 media 100baseTX mediaopt full-duplex»
З.Ы. При копировании статьи ссылка на источник ОБЯЗАТЕЛЬНА !
Уважаемые участники MSK-IX, MSK-IX планирует провести модернизацию оборудования и программного обеспечения действующей в сети MSK-IX службы Route Server (RS), предназначенной для организации пирингового взаимодействия между участниками MSK-IX http://www.msk-ix.ru/network/routeserver.html. В результате модернизации RS станет "прозрачным", т.е. участники MSK-IX, использующие RS, будут получать BGP-анонсы от RS с теми же значениями BGP атрибутов AS_PATH, Next-Hop и MED, как и при прямом пиринге между собой. В частности, это означает, что RS не будет удлинять список AS в атрибуте AS_PATH за счет добавления собственной AS8631. Если Вы используете службу RS, просим до 10 сентября 2008 года проверить, что конфигурация Вашего оборудования готова к модернизации. Проверка состоит из трех этапов: 1. Удостоверьтесь, что в настройки Вашей пиринговой сессии с RS (AS8631), внесена команда (для оборудования Cisco, Juniper, Quagga, Zebra и др.) no bgp enforce-first-as Данная команда совместима с текущей версией RS. Если данная команда не поддерживается программным обеспечением Вашего оборудования, то как правило, никаких изменений не требуется. Обратитесь к документации для Вашего оборудования, см. например http://www.cisco.com/en/US/docs/ios/12_0s/feature/guide/s_befasp.html. 2. Удостоверьтесь, что пиринговая сессия с AS8631 с Вашей стороны установлена с обоими роут-серверами сети MSK-IX http://www.msk-ix.ru/network/routeserver.html. 3. Рекомендуем также проверить загрузку порта в MSK-IX и в случае необходимости оформить заявку на увеличение пропускной способности. Сокращение числа AS в атрибуте AS_PATH может привести к росту трафика на сети, анонсируемые через RS. Изменения в конфигурации Вашего оборудования рекомендуем произвести *КА� МОЖНО РАНЬШЕ*. О точной дате и времени модернизации роут-серверов MSK-IX мы сообщим отдельным письмом. Контактная информация MSK-IX для вопросов и пожеланий.
Русская версия новости
Двое специалистов по IT-безопасности, Антон Капела (Anton Kapela) из 5Nines Data и Алекс Пилосов (Alex Pilosov) из Pilosoft, продемонстрировали методику, позволяющую тайно перехватывать интернет-трафик и даже модифицировать его на пути к адресату, пишет Wired. Это позволяет сделать протокол интернет-маршрутизации BGP (Border Gateway Protocol, протокол граничного шлюза)
Эксперты уже назвали обнаруженную «дырку» одной из самых крупных в Интернете и сравнивают ее с недавно обнаруженной DNS-уязвимостью, теоретически позволявшей злоумышленнику перенаправлять пользователя вместо нужного на любой сайт.
BGP является одним из основных интернет-протоколов и обеспечивает обмен информацией о маршрутах между целыми автономными системами, а не отдельными маршрутизаторами. Капела и Пилосов показали на конференции DefCon, как можно перехватить трафик, направляющийся в сеть конференции, переправить его в контролируемую ими систему в Нью-Йорке, а затем доставить обратно. Их схема не использует ошибок протокола — лишь его нормальные возможности.
Как пишет Wired, ранее перехватывать интернет-трафик, используя уязвимость BGP, были способны только разведывательные агентства. Они знали о недостатках протокола с 1998 года, с тех пор как эксперт по безопасности Пейтер Затко (Peiter Zatko) рассказал о ней Конгрессу и предположил, что может за полчаса нарушить работу всего Интернета, используя обнаруженную уязвимость.
Two security researchers have demonstrated a new technique to stealthily intercept internet traffic on a scale previously presumed to be unavailable to anyone outside of intelligence agencies like the National Security Agency.
The tactic exploits the internet routing protocol BGP (Border Gateway Protocol) to let an attacker surreptitiously monitor unencrypted internet traffic anywhere in the world, and even modify it before it reaches its destination.
The demonstration is only the latest attack to highlight fundamental security weaknesses in some of the internet’s core protocols. Those protocols were largely developed in the 1970s with the assumption that every node on the then-nascent network would be trustworthy. The world was reminded of the quaintness of that assumption in July, when researcher Dan Kaminsky disclosed a serious vulnerability in the DNS system. Experts say the new demonstration targets a potentially larger weakness.
«It’s a huge issue. It’s at least as big an issue as the DNS issue, if not bigger,» said Peiter «Mudge» Zatko, noted computer security expert and former member of the L0pht hacking group, who testified to Congress in 1998 that he could bring down the internet in 30 minutes using a similar BGP attack, and disclosed privately to government agents how BGP could also be exploited to eavesdrop. «I went around screaming my head about this about ten or twelve years ago…. We described this to intelligence agencies and to the National Security Council, in detail.»
The man-in-the-middle attack exploits BGP to fool routers into re-directing data to an eavesdropper’s network.
Anyone with a BGP router (ISPs, large corporations or anyone with space at a carrier hotel) could intercept data headed to a target IP address or group of addresses. The attack intercepts only traffic headed to target addresses, not from them, and it can’t always vacuum in traffic within a network — say, from one AT&T customer to another.
The method conceivably could be used for corporate espionage, nation-state spying or even by intelligence agencies looking to mine internet data without needing the cooperation of ISPs.
BGP eavesdropping has long been a theoretical weakness, but no one is known to have publicly demonstrated it until Anton «Tony» Kapela, data center and network director at 5Nines Data, and Alex Pilosov, CEO of Pilosoft, showed their technique at the recent DefCon hacker conference. The pair successfully intercepted traffic bound for the conference network and redirected it to a system they controlled in New York before routing it back to DefCon in Las Vegas.
The technique, devised by Pilosov, doesn’t exploit a bug or flaw in BGP. It simply exploits the natural way BGP works.
«We’re not doing anything out of the ordinary,» Kapela told Wired.com. «There’s no vulnerabilities, no protocol errors, there are no software problems. The problem arises (from) the level of interconnectivity that’s needed to maintain this mess, to keep it all working.»
The issue exists because BGP’s architecture is based on trust. To make it easy, say, for e-mail from Sprint customers in California to reach Telefonica customers in Spain, networks for these companies and others communicate through BGP routers to indicate when they’re the quickest, most efficient route for the data to reach its destination. But BGP assumes that when a router says it’s the best path, it’s telling the truth. That gullibility makes it easy for eavesdroppers to fool routers into sending them traffic.
Here’s how it works. When a user types a website name into his browser or clicks «send» to launch an e-mail, a Domain Name System server produces an IP address for the destination. A router belonging to the user’s ISP then consults a BGP table for the best route. That table is built from announcements, or «advertisements,» issued by ISPs and other networks — also known as Autonomous Systems, or ASes — declaring the range of IP addresses, or IP prefixes, to which they’ll deliver traffic.
The routing table searches for the destination IP address among those prefixes. If two ASes deliver to the address, the one with the more specific prefix «wins» the traffic. For example, one AS may advertise that it delivers to a group of 90,000 IP addresses, while another delivers to a subset of 24,000 of those addresses. If the destination IP address falls within both announcements, BGP will send data to the narrower, more specific one.
To intercept data, an eavesdropper would advertise a range of IP addresses he wished to target that was narrower than the chunk advertised by other networks. The advertisement would take just minutes to propagate worldwide, before data headed to those addresses would begin arriving to his network.
The attack is called an IP hijack and, on its face, isn’t new.
But in the past, known IP hijacks have created outages, which, because they were so obvious, were quickly noticed and fixed. That’s what occurred earlier this year when Pakistan Telecom inadvertently hijacked YouTube traffic from around the world. The traffic hit a dead-end in Pakistan, so it was apparent to everyone trying to visit YouTube that something was amiss.
Pilosov’s innovation is to forward the intercepted data silently to the actual destination, so that no outage occurs.
Ordinarily, this shouldn’t work — the data would boomerang back to the eavesdropper. But Pilosov and Kapela use a method called AS path prepending that causes a select number of BGP routers to reject their deceptive advertisement. They then use these ASes to forward the stolen data to its rightful recipients.
«Everyone … has assumed until now that you have to break something for a hijack to be useful,» Kapela said. «But what we showed here is that you don’t have to break anything. And if nothing breaks, who notices?»
Stephen Kent, chief scientist for information security at BBN Technologies, who has been working on solutions to fix the issue, said he demonstrated a similar BGP interception privately for the Departments of Defense and Homeland Security a few years ago.
Kapela said network engineers might notice an interception if they knew how to read BGP routing tables, but it would take expertise to interpret the data.
A handful of academic groups collect BGP routing information from cooperating ASes to monitor BGP updates that change traffic’s path. But without context, it can be difficult to distinguish a legitimate change from a malicious hijacking. There are reasons traffic that ordinarily travels one path could suddenly switch to another — say, if companies with separate ASes merged, or if a natural disaster put one network out of commission and another AS adopted its traffic. On good days, routing paths can remain fairly static. But «when the internet has a bad hair day,» Kent said, «the rate of (BGP path) updates goes up by a factor of 200 to 400.»
Kapela said eavesdropping could be thwarted if ISPs aggressively filtered to allow only authorized peers to draw traffic from their routers, and only for specific IP prefixes. But filtering is labor intensive, and if just one ISP declines to participate, it «breaks it for the rest of us,» he said.
«Providers can prevent our attack absolutely 100 percent,» Kapela said. «They simply don’t because it takes work, and to do sufficient filtering to prevent these kinds of attacks on a global scale is cost prohibitive.»
Filtering also requires ISPs to disclose the address space for all their customers, which is not information they want to hand competitors.
Filtering isn’t the only solution, though. Kent and others are devising processes to authenticate ownership of IP blocks, and validate the advertisements that ASes send to routers so they don’t just send traffic to whoever requests it.
Under the scheme, the five regional internet address registries would issue signed certificates to ISPs attesting to their address space and AS numbers. The ASes would then sign an authorization to initiate routes for their address space, which would be stored with the certificates in a repository accessible to all ISPs. If an AS advertised a new route for an IP prefix, it would be easy to verify if it had the right to do so.
The solution would authenticate only the first hop in a route to prevent unintentional hijacks, like Pakistan Telecom’s, but wouldn’t stop an eavesdropper from hijacking the second or third hop.
For this, Kent and BBN colleagues developed Secure BGP (SBGP), which would require BGP routers to digitally sign with a private key any prefix advertisement they propagated. An ISP would give peer routers certificates authorizing them to route its traffic; each peer on a route would sign a route advertisement and forward it to the next authorized hop.
«That means that nobody could put themselves into the chain, into the path, unless they had been authorized to do so by the preceding AS router in the path,» Kent said.
The drawback to this solution is that current routers lack the memory and processing power to generate and validate signatures. And router vendors have resisted upgrading them because their clients, ISPs, haven’t demanded it, due to the cost and man hours involved in swapping out routers.
Douglas Maughan, cybersecurity research program manager for the DHS’s Science and Technology Directorate, has helped fund research at BBN and elsewhere to resolve the BGP issue. But he’s had little luck convincing ISPs and router vendors to take steps to secure BGP.
«We haven’t seen the attacks, and so a lot of times people don’t start working on things and trying to fix them until they get attacked,» Maughan said. «(But) the YouTube (case) is the perfect example of an attack where somebody could have done much worse than what they did.»
ISPs, he said, have been holding their breath, «hoping that people don’t discover (this) and exploit it.»
«The only thing that can force them (to fix BGP) is if their customers … start to demand security solutions,» Maughan said.
Ссылки: