0

I'm wondering if it is possible to have same IP address belonging to multiple ASes? especially in case

  1. Anycast IP, so we could provide the node in different ISP's networks?
  2. A router, so that we can have a more global (ISP's AS) and local (company's AS). If we could have same IP belonging to multiple ASes, how do we deal with IP registry in arin.net or other authorities?

Thank you!

2 Answers2

0

If you want every machine to use the same internet(public) IP to hide their real public IPs, use vpn tool. If you want every machine inside a LAN to use a single internet(public) IP, it is already done by most LAN routers, and it is called "NAT"

George Y
  • 380
  • 2
  • 11
-1

AS is a collection of IP prefixes, uniquely identifies an ultimate unicast destination. Therefore you can't have the same IP belonging to multiple ASes. If you use private ASes inside your network, you just group your assigned prefixes by them and cannot propagate private AS info to the outside world.

You must use your internal routers to deal with the paths to the destinations. You can use BGP, inject (redistribute) OSPF routes to BGP or vice versa, or rely on any other IGP alone or IGPs combination. But outside world just have to know how to reach your assigned AS, nothing more.

In the case of anycast you propagate your prefix through multiple routers, belonging to your AS. The idea behind this is to route the request to closest destination. If you plan to have geographically distributed resources, then it may be a good idea to consider CDN for that.

  • 1
    "_AS is a collection of IP prefixes_" No, not at all. An AS is a, autonomously controlled system. For example, I could get an AS number and set up some routers, connected internally with Private addresses, get external addresses from other ASes, and route traffic between the other ASes to which my AS is connected, but not have any of my own IP addresses. An AS really has nothing to do with IP addresses or prefixes, it is a system for BGP routing. – Ron Maupin Oct 20 '20 at 21:53
  • @Oleg Kirillov, does that mean if anycast IP (with a public Internet IP addresss) nodes have to be within same AS even if they are geographically dispersed? – pathscale Oct 21 '20 at 13:44
  • RFC 1772 clearly states that AS is a set of routrrs under a common administration. Therefore (by the nature of routers) it serves as a collection of IP prefixes, assigned to that administration entity, to allow EGP use between them. Other ASes collect the routing information to reach those prefixes not using complex and resource-demanding IGPs. In general ASes allow geographically dispersed IPs, that's not a problem for IGPs. But when you start using anycasts, it may leave distant resources unused. That's not a problem though if your source IPs also disprrsed geographically. – Oleg Kirillov Oct 21 '20 at 23:44
  • "_Therefore (by the nature of routers) it serves as a collection of IP prefixes, assigned to that administration entity_" No, an AS has nothing to do with IP prefixes. As I explained in my comment, I could use all Private addressing in my AS, and I would only advertise prefixes from/to all the other ASes to which I connect. I would be a transit AS, not having or advertising any prefixes of my own. Thinking that an AS is a collection of prefixes is completely wrong. It is a construct for BGP, not IP. – Ron Maupin Oct 22 '20 at 00:02
  • You can use anything inside your AS as it's completely under your administration, but outside world sees your AS only via EGPs (BGP in particuar) that advertise public prefixes and therefore AS from the external point of view is nothing more than a list of prefixes that can be reached. – Oleg Kirillov Oct 23 '20 at 07:41
  • No, in my scenario, the prefixes I advertise belong to others, not me. My AS number ends up in the AS_PATH for the prefixes that I advertise, by those are not my prefixes (I do not have any). My ISP has an AS that advertises Google prefixes to me, but they do not own those prefixes, they only advertise them as a way to reach those prefixes. AS has nothing to do with addressing, and an AS can have no prefixes, so an AS is _not_ a collection of prefixes as you have claimed. – Ron Maupin Oct 23 '20 at 17:30
  • In your scenario you are acting as transit AS, having no destination prefixes inside. – Oleg Kirillov Oct 25 '20 at 19:48
  • I guess I got your point. You think I insist that prefixes in some way have to belong to AS. No, this is not a requirement. A collection means that EGPs see a list of prefixes advertised as reachable via AS, but they do not care about their owner/administration entity. – Oleg Kirillov Oct 25 '20 at 19:56