
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:media="http://search.yahoo.com/mrss/">
    <channel>
        <title><![CDATA[ The Cloudflare Blog ]]></title>
        <description><![CDATA[ Get the latest news on how products at Cloudflare are built, technologies used, and join the teams helping to build a better Internet. ]]></description>
        <link>https://blog.cloudflare.com</link>
        <atom:link href="https://blog.cloudflare.com/" rel="self" type="application/rss+xml"/>
        <language>en-us</language>
        <image>
            <url>https://blog.cloudflare.com/favicon.png</url>
            <title>The Cloudflare Blog</title>
            <link>https://blog.cloudflare.com</link>
        </image>
        <lastBuildDate>Tue, 07 Apr 2026 19:34:28 GMT</lastBuildDate>
        <item>
            <title><![CDATA[One IP address, many users: detecting CGNAT to reduce collateral effects]]></title>
            <link>https://blog.cloudflare.com/detecting-cgn-to-reduce-collateral-damage/</link>
            <pubDate>Wed, 29 Oct 2025 13:00:00 GMT</pubDate>
            <description><![CDATA[ IPv4 scarcity drives widespread use of Carrier-Grade Network Address Translation, a practice in ISPs and mobile networks that places many users behind each IP address, along with their collected activity and volumes of traffic. We introduce the method we’ve developed to detect large-scale IP sharing globally and mitigate the issues that result.  ]]></description>
            <content:encoded><![CDATA[ <p>IP addresses have historically been treated as stable identifiers for non-routing purposes such as for geolocation and security operations. Many operational and security mechanisms, such as blocklists, rate-limiting, and anomaly detection, rely on the assumption that a single IP address represents a cohesive<b>, </b>accountable<b> </b>entity or even, possibly, a specific user or device.</p><p>But the structure of the Internet has changed, and those assumptions can no longer be made. Today, a single IPv4 address may represent hundreds or even thousands of users due to widespread use of <a href="https://en.wikipedia.org/wiki/Carrier-grade_NAT"><u>Carrier-Grade Network Address Translation (CGNAT)</u></a>, VPNs, and proxy<b> </b>middleboxes. This concentration of traffic can result in <a href="https://blog.cloudflare.com/consequences-of-ip-blocking/"><u>significant collateral damage</u></a> – especially to users in developing regions of the world – when security mechanisms are applied without taking into account the multi-user nature of IPs.</p><p>This blog post presents our approach to detecting large-scale IP sharing globally. We describe how we <a href="https://www.cloudflare.com/learning/ai/how-to-secure-training-data-against-ai-data-leaks/">build reliable training data</a>, and how detection can help avoid unintentional bias affecting users in regions where IP sharing is most prevalent. Arguably it's those regional variations that motivate our efforts more than any other. </p>
    <div>
      <h2>Why this matters: Potential socioeconomic bias</h2>
      <a href="#why-this-matters-potential-socioeconomic-bias">
        
      </a>
    </div>
    <p>Our work was initially motivated by a simple observation: CGNAT is a likely unseen source of bias on the Internet. Those biases would be more pronounced wherever there are more users and few addresses, such as in developing regions. And these biases can have profound implications for user experience, network operations, and digital equity.</p><p>The reasons are understandable for many reasons, not least because of necessity. Countries in the developing world often have significantly fewer available IPs, and more users. The disparity is a historical artifact of how the Internet grew: the largest blocks of IPv4 addresses were allocated decades ago, primarily to organizations in North America and Europe, leaving a much smaller pool for regions where Internet adoption expanded later. </p><p>To visualize the IPv4 allocation gap, we plot country-level ratios of users to IP addresses in the figure below. We take online user estimates from the <a href="https://data.worldbank.org/indicator/IT.NET.USER.ZS"><u>World Bank Group</u></a> and the number of IP addresses in a country from Regional Internet Registry (RIR) records. The colour-coded map that emerges shows that the usage of each IP address is more concentrated in regions that generally have poor Internet penetration. For example, large portions of Africa and South Asia appear with the highest user-to-IP ratios. Conversely, the lowest user-to-IP ratios appear in Australia, Canada, Europe, and the USA — the very countries that otherwise have the highest Internet user penetration numbers.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/2YBdqPx0ALt7pY7rmQZyLQ/049922bae657a715728700c764c4af16/BLOG-3046_2.png" />
          </figure><p>The scarcity of IPv4 address space means that regional differences can only worsen as Internet penetration rates increase. A natural consequence of increased demand in developing regions is that ISPs would rely even more heavily on CGNAT, and is compounded by the fact that CGNAT is common in mobile networks that users in developing regions so heavily depend on. All of this means that <a href="https://datatracker.ietf.org/doc/html/rfc7021"><u>actions known to be based</u></a> on IP reputation or behaviour would disproportionately affect developing economies. </p><p>Cloudflare is a global network in a global Internet. We are sharing our methodology so that others might benefit from our experience and help to mitigate unintended effects. First, let’s better understand CGNAT.</p>
    <div>
      <h3>When one IP address serves multiple users</h3>
      <a href="#when-one-ip-address-serves-multiple-users">
        
      </a>
    </div>
    <p>Large-scale IP address sharing is primarily achieved through two distinct methods. The first, and more familiar, involves services like VPNs and proxies. These tools emerge from a need to secure corporate networks or improve users' privacy, but can be used to circumvent censorship or even improve performance. Their deployment also tends to concentrate traffic from many users onto a small set of exit IPs. Typically, individuals are aware they are using such a service, whether for personal use or as part of a corporate network.</p><p>Separately, another form of large-scale IP sharing often goes unnoticed by users: <a href="https://en.wikipedia.org/wiki/Carrier-grade_NAT"><u>Carrier-Grade NAT (CGNAT)</u></a>. One way to explain CGNAT is to start with a much smaller version of network address translation (NAT) that very likely exists in your home broadband router, formally called a Customer Premises Equipment (or CPE), which translates unseen private addresses in the home to visible and routable addresses in the ISP. Once traffic leaves the home, an ISP may add an additional enterprise-level address translation that causes many households or unrelated devices to appear behind a single IP address.</p><p>The crucial difference between large-scale IP sharing is user choice: carrier-grade address sharing is not a user choice, but is configured directly by Internet Service Providers (ISPs) within their access networks. Users are not aware that CGNATs are in use. </p><p>The primary driver for this technology, understandably, is the exhaustion of the IPv4 address space. IPv4's 32-bit architecture supports only 4.3 billion unique addresses — a capacity that, while once seemingly vast, has been completely outpaced by the Internet's explosive growth. By the early 2010s, Regional Internet Registries (RIRs) had depleted their pools of unallocated IPv4 addresses. This left ISPs unable to easily acquire new address blocks, forcing them to maximize the use of their existing allocations.</p><p>While the long-term solution is the transition to IPv6, CGNAT emerged as the immediate, practical workaround. Instead of assigning a unique public IP address to each customer, ISPs use CGNAT to place multiple subscribers behind a single, shared IP address. This practice solves the problem of IP address scarcity. Since translated addresses are not publicly routable, CGNATs have also had the positive side effect of protecting many home devices that might be vulnerable to compromise. </p><p>CGNATs also create significant operational fallout stemming from the fact that hundreds or even thousands of clients can appear to originate from a single IP address. <b>This means an IP-based security system may inadvertently block or throttle large groups of users as a result of a single user behind the CGNAT engaging in malicious activity.</b></p><p>This isn't a new or niche issue. It has been recognized for years by the Internet Engineering Task Force (IETF), the organization that develops the core technical standards for the Internet. These standards, known as Requests for Comments (RFCs), act as the official blueprints for how the Internet should operate. <a href="https://www.rfc-editor.org/rfc/rfc6269.html"><u>RFC 6269</u></a>, for example, discusses the challenges of IP address sharing, while <a href="https://datatracker.ietf.org/doc/html/rfc7021"><u>RFC 7021</u></a> examines the impact of CGNAT on network applications. Both explain that traditional abuse-mitigation techniques, such as blocklisting or rate-limiting, assume a one-to-one relationship between IP addresses and users: when malicious activity is detected, the offending IP address can be blocked to prevent further abuse.</p><p>In shared IPv4 environments, such as those using CGNAT or other address-sharing techniques, this assumption breaks down because multiple subscribers can appear under the same public IP. Blocking the shared IP therefore penalizes many innocent users along with the abuser. In 2015 Ofcom, the UK's telecommunications regulator, reiterated these concerns in a <a href="https://oxil.uk/research/mc159-report-on-the-implications-of-carrier-grade-network-address-translators-final-report"><u>report</u></a> on the implications of CGNAT where they noted that, “In the event that an IPv4 address is blocked or blacklisted as a source of spam, the impact on a CGNAT would be greater, potentially affecting an entire subscriber base.” </p><p>While the hope was that CGNAT was only a temporary solution until the eventual switch to IPv6, as the old proverb says, nothing is more permanent than a temporary solution. While IPv6 deployment continues to lag, <a href="https://blog.apnic.net/2022/01/19/ip-addressing-in-2021/"><u>CGNAT deployments have become increasingly common</u></a>, and so do the related problems. </p>
    <div>
      <h2>CGNAT detection at Cloudflare</h2>
      <a href="#cgnat-detection-at-cloudflare">
        
      </a>
    </div>
    <p>To enable a fairer treatment of users behind CGNAT IPs by security techniques that rely on IP reputation, our goal is to identify large-scale IP sharing. This allows traffic filtering to be better calibrated and collateral damage minimized. Additionally, we want to distinguish CGNAT IPs from other large-scale sharing (LSS) IP technologies, such as VPNs and proxies, because we may need to take different approaches to different kinds of IP-sharing technologies.</p><p>To do this, we decided to take advantage of Cloudflare’s extensive view of the active IP clients, and build a supervised learning classifier that would distinguish CGNAT and VPN/proxy IPs from IPs that are allocated to a single subscriber (non-LSS IPs), based on behavioural characteristics. The figure below shows an overview of our supervised classifier: </p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7tFXZByKRCYxVaAFDG0Xda/d81e7f09b5d12e03e39c266696df9cc3/BLOG-3046_3.png" />
          </figure><p>While our classification approach is straightforward, a significant challenge is the lack of a reliable, comprehensive, and labeled dataset of CGNAT IPs for our training dataset.</p>
    <div>
      <h3>Detecting CGNAT using public data sources </h3>
      <a href="#detecting-cgnat-using-public-data-sources">
        
      </a>
    </div>
    <p>Detection begins by building an initial dataset of IPs believed to be associated with CGNAT. Cloudflare has vast HTTP and traffic logs. Unfortunately there is no signal or label in any request to indicate what is or is not a CGNAT. </p><p>To build an extensive labelled dataset to train our ML classifier, we employ a combination of network measurement techniques, as described below. We rely on public data sources to help disambiguate an initial set of large-scale shared IP addresses from others in Cloudflare’s logs.   </p>
    <div>
      <h4>Distributed Traceroutes</h4>
      <a href="#distributed-traceroutes">
        
      </a>
    </div>
    <p>The presence of a client behind CGNAT can often be inferred through traceroute analysis. CGNAT requires ISPs to insert a NAT step that typically uses the Shared Address Space (<a href="https://datatracker.ietf.org/doc/html/rfc6598"><u>RFC 6598</u></a>) after the customer premises equipment (CPE). By running a traceroute from the client to its own public IP and examining the hop sequence, the appearance of an address within 100.64.0.0/10 between the first private hop (e.g., 192.168.1.1) and the public IP is a strong indicator of CGNAT.</p><p>Traceroute can also reveal multi-level NAT, which CGNAT requires, as shown in the diagram below. If the ISP assigns the CPE a private <a href="https://datatracker.ietf.org/doc/html/rfc1918"><u>RFC 1918</u></a> address that appears right after the local hop, this indicates at least two NAT layers. While ISPs sometimes use private addresses internally without CGNAT, observing private or shared ranges immediately downstream combined with multiple hops before the public IP strongly suggests CGNAT or equivalent multi-layer NAT.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/57k4gwGCHcPggIWtSy36HU/6cf8173c1a4c568caa25a1344a516e9e/BLOG-3046_4.png" />
          </figure><p>Although traceroute accuracy depends on router configurations, detecting private and shared IP ranges is a reliable way to identify large-scale IP sharing. We apply this method to distributed traceroutes from over 9,000 RIPE Atlas probes to classify hosts as behind CGNAT, single-layer NAT, or no NAT.</p>
    <div>
      <h4>Scraping WHOIS and PTR records</h4>
      <a href="#scraping-whois-and-ptr-records">
        
      </a>
    </div>
    <p>Many operators encode metadata about their IPs in the corresponding reverse DNS pointer (PTR) record that can signal administrative attributes and geographic information. We first query the DNS for PTR records for the full IPv4 space and then filter for a set of known keywords from the responses that indicate a CGNAT deployment. For example, each of the following three records matches a keyword (<code>cgnat</code>, <code>cgn</code> or <code>lsn</code>) used to detect CGNAT address space:</p><p><code>node-lsn.pool-1-0.dynamic.totinternet.net
103-246-52-9.gw1-cgnat.mobile.ufone.nz
cgn.gsw2.as64098.net</code></p><p>WHOIS and Internet Routing Registry (IRR) records may also contain organizational names, remarks, or allocation details that reveal whether a block is used for CGNAT pools or residential assignments. </p><p>Given that both PTR and WHOIS records may be manually maintained and therefore may be stale, we try to sanitize the extracted data by validating the fact that the corresponding ISPs indeed use CGNAT based on customer and market reports. </p>
    <div>
      <h4>Collecting VPN and proxy IPs </h4>
      <a href="#collecting-vpn-and-proxy-ips">
        
      </a>
    </div>
    <p>Compiling a list of VPN and proxy IPs is more straightforward, as we can directly find such IPs in public service directories for anonymizers. We also subscribe to multiple VPN providers, and we collect the IPs allocated to our clients by connecting to a unique HTTP endpoint under our control. </p>
    <div>
      <h2>Modeling CGNAT with machine learning</h2>
      <a href="#modeling-cgnat-with-machine-learning">
        
      </a>
    </div>
    <p>By combining the above techniques, we accumulated a dataset of labeled IPs for more than 200K CGNAT IPs, 180K VPNs &amp; proxies and close to 900K IPs allocated that are not LSS IPs. These were the entry points to modeling with machine learning.</p>
    <div>
      <h3>Feature selection</h3>
      <a href="#feature-selection">
        
      </a>
    </div>
    <p>Our hypothesis was that aggregated activity from CGNAT IPs is distinguishable from activity generated from other non-CGNAT IP addresses. Our feature extraction is an evaluation of that hypothesis — since networks do not disclose CGNAT and other uses of IPs, the quality of our inference is strictly dependent on our confidence in the training data. We claim the key discriminator is diversity, not just volume. For example, VM-hosted scanners may generate high numbers of requests, but with low information diversity. Similarly, globally routable CPEs may have individually unique characteristics, but with volumes that are less likely to be caught at lower sampling rates.</p><p>In our feature extraction, we parse a 1% sampled HTTP requests log for distinguishing features of IPs compiled in our reference set, and the same features for the corresponding /24 prefix (namely IPs with the same first 24 bits in common). We analyse the features for each of the VPNs, proxies, CGNAT, or non LSS IP. We find that features from the following broad categories are key discriminators for the different types of IPs in our training dataset:</p><ul><li><p><b>Client-side signals:</b> We analyze the aggregate properties of clients connecting from an IP. A large, diverse user base (like on a CGNAT) naturally presents a much wider statistical variety of client behaviors and connection parameters than a single-tenant server or a small business proxy.</p></li><li><p><b>Network and transport-level behaviors:</b> We examine traffic at the network and transport layers. The way a large-scale network appliance (like a CGNAT) manages and routes connections often leaves subtle, measurable artifacts in its traffic patterns, such as in port allocation and observed network timing.</p></li><li><p><b>Traffic volume and destination diversity:</b> We also model the volume and "shape" of the traffic. An IP representing thousands of independent users will, on average, generate a higher volume of requests and target a much wider, less correlated set of destinations than an IP representing a single user.</p></li></ul><p>Crucially, to distinguish CGNAT from VPNs and proxies (which is absolutely necessary for calibrated security filtering), we had to aggregate these features at two different scopes: per-IP and per /24 prefixes. CGNAT IPs are typically allocated large blocks of IPs, whereas VPNs IPs are more scattered across different IP prefixes. </p>
    <div>
      <h3>Classification results</h3>
      <a href="#classification-results">
        
      </a>
    </div>
    <p>We compute the above features from HTTP logs over 24-hour intervals to increase data volume and reduce noise due to DHCP IP reallocation. The dataset is split into 70% training and 30% testing sets with disjoint /24 prefixes, and VPN and proxy labels are merged due to their similarity and lower operational importance compared to CGNAT detection.</p><p>Then we train a multi-class <a href="https://xgboost.readthedocs.io/en/stable/"><u>XGBoost</u></a> model with class weighting to address imbalance, assigning each IP to the class with the highest predicted probability. XGBoost is well-suited for this task because it efficiently handles large feature sets, offers strong regularization to prevent overfitting, and delivers high accuracy with limited parameter tuning. The classifier achieves 0.98 accuracy, 0.97 weighted F1, and 0.04 log loss. The figure below shows the confusion matrix of the classification.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/26i81Pe0yjlftHfIDrjB5X/45d001447fc52001a25176c8036a92cb/BLOG-3046_5.png" />
          </figure><p>Our model is accurate for all three labels. The errors observed are mainly misclassifications of VPN/proxy IPs as CGNATs, mostly for VPN/proxy IPs that are within a /24 prefix that is also shared by broadband users outside of the proxy service. We also evaluate the prediction accuracy using <a href="https://scikit-learn.org/stable/modules/cross_validation.html"><u>k-fold cross validation</u></a>, which provides a more reliable estimate of performance by training and validating on multiple data splits, reducing variance and overfitting compared to a single train–test split. We select 10 folds and we evaluate the <a href="https://developers.google.com/machine-learning/crash-course/classification/roc-and-auc"><u>Area Under the ROC Curve</u></a> (AUC) and the multi-class logloss. We achieve a macro-average AUC of 0.9946 (σ=0.0069) and log loss of 0.0429 (σ=0.0115). Prefix-level features are the most important contributors to classification performance.</p>
    <div>
      <h3>Users behind CGNAT are more likely to be rate limited</h3>
      <a href="#users-behind-cgnat-are-more-likely-to-be-rate-limited">
        
      </a>
    </div>
    <p>The figure below shows the daily number of CGNAT IP inferences generated by our CDN-deployed detection service between December 17, 2024 and January 9, 2025. The number of inferences remains largely stable, with noticeable dips during weekends and holidays such as Christmas and New Year’s Day. This pattern reflects expected seasonal variations, as lower traffic volumes during these periods lead to fewer active IP ranges and reduced request activity.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7hiYstptHAK6tFQrM2kEsf/7f8192051156fc6eaecdf26a829ef11c/BLOG-3046_6.png" />
          </figure><p>Next, recall that actions that rely on IP reputation or behaviour may be unduly influenced by CGNATs. One such example is bot detection. In an evaluation of our systems, we find that bot detection is resilient to those biases. However, we also learned that customers are more likely to rate limit IPs that we find are CGNATs.</p><p>We analyze bot labels by analyzing how often requests from CGNAT and non-CGNAT IPs are labeled as bots. <a href="https://www.cloudflare.com/resources/assets/slt3lc6tev37/JYknFdAeCVBBWWgQUtNZr/61844a850c5bba6b647d65e962c31c9c/BDES-863_Bot_Management_re_edit-_How_it_Works_r3.pdf"><u>Cloudflare assigns a bot score</u></a> to each HTTP request using CatBoost models trained on various request features, and these scores are then exposed through the Web Application Firewall (WAF), allowing customers to apply filtering rules. The median bot rate is nearly identical for CGNAT (4.8%) and non-CGNAT (4.7%) IPs. However, the mean bot rate is notably lower for CGNATs (7%) than for non-CGNATs (13.1%), indicating different underlying distributions. Non-CGNAT IPs show a much wider spread, with some reaching 100% bot rates, while CGNAT IPs cluster mostly below 15%. This suggests that non-CGNAT IPs tend to be dominated by either human or bot activity, whereas CGNAT IPs reflect mixed behavior from many end users, with human traffic prevailing.</p><p>Interestingly, despite bot scores that indicate traffic is more likely to be from human users, CGNAT IPs are subject to rate limiting three times more often than non-CGNAT IPs. This is likely because multiple users share the same public IP, increasing the chances that legitimate traffic gets caught by customers’ bot mitigation and firewall rules.</p><p>This tells us that users behind CGNAT IPs are indeed susceptible to collateral effects, and identifying those IPs allows us to tune mitigation strategies to disrupt malicious traffic quickly while reducing collateral impact on benign users behind the same address.</p>
    <div>
      <h2>A global view of the CGNAT ecosystem</h2>
      <a href="#a-global-view-of-the-cgnat-ecosystem">
        
      </a>
    </div>
    <p>One of the early motivations of this work was to understand if our knowledge about IP addresses might hide a bias along socio-economic boundaries—and in particular if an action on an IP address may disproportionately affect populations in developing nations, often referred to as the Global South. Identifying where different IPs exist is a necessary first step.</p><p>The map below shows the fraction of a country’s inferred CGNAT IPs over all IPs observed in the country. Regions with a greater reliance on CGNAT appear darker on the map. This view highlights the geodiversity of CGNATs in terms of importance; for example, much of Africa and Central and Southeast Asia rely on CGNATs. </p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4P2XcuEebKfcYdCgykMWuP/4a0aa86bd619ba24533de6862175e919/BLOG-3046_7.png" />
          </figure><p>As further evidence of continental differences, the boxplot below shows the distribution of distinct user agents per IP across /24 prefixes inferred to be part of a CGNAT deployment in each continent. </p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7bqJSHexFuXFs4A8am1ibQ/591be6880e8f58c9d61b147aaf0487f5/BLOG-3046_8.png" />
          </figure><p>Notably, Africa has a much higher ratio of user agents to IP addresses than other regions, suggesting more clients share the same IP in African <a href="https://www.cloudflare.com/learning/network-layer/what-is-an-autonomous-system/"><u>ASNs</u></a>. So, not only do African ISPs rely more extensively on CGNAT, but the number of clients behind each CGNAT IP is higher. </p><p>While the deployment rate of CGNAT per country is consistent with the users-per-IP ratio per country, it is not sufficient by itself to confirm deployment. The scatterplot below shows the number of users (according to <a href="https://stats.labs.apnic.net/aspop/"><u>APNIC user estimates</u></a>) and the number of IPs per ASN for ASNs where we detect CGNAT. ASNs that have fewer available IP addresses than their user base appear below the diagonal. Interestingly the scatterplot indicates that many ASNs with more addresses than users still choose to deploy CGNAT. Presumably, these ASNs provide additional services beyond broadband, preventing them from dedicating their entire address pool to subscribers. </p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/34GKPlJWvkwudU5MbOtots/c883760a7c448b12995997e3e6e51979/BLOG-3046_9.png" />
          </figure>
    <div>
      <h3>What this means for everyday Internet users</h3>
      <a href="#what-this-means-for-everyday-internet-users">
        
      </a>
    </div>
    <p>Accurate detection of CGNAT IPs is crucial for minimizing collateral effects in network operations and for ensuring fair and effective application of security measures. Our findings underscore the potential socio-economic and geographical variations in the use of CGNATs, revealing significant disparities in how IP addresses are shared across different regions. </p><p>At Cloudflare we are going beyond just using these insights to evaluate policies and practices. We are using the detection systems to improve our systems across our application security suite of features, and working with customers to understand how they might use these insights to improve the protections they configure.</p><p>Our work is ongoing and we’ll share details as we go. In the meantime, if you’re an ISP or network operator that operates CGNAT and want to help, get in touch at <a><u>ask-research@cloudflare.com</u></a>. Sharing knowledge and working together helps make better and equitable user experience for subscribers, while preserving web service safety and security.</p> ]]></content:encoded>
            <category><![CDATA[Research]]></category>
            <category><![CDATA[WAF]]></category>
            <category><![CDATA[Web Application Firewall]]></category>
            <category><![CDATA[Better Internet]]></category>
            <category><![CDATA[Security]]></category>
            <category><![CDATA[Bots]]></category>
            <category><![CDATA[IPv4]]></category>
            <category><![CDATA[Network Services]]></category>
            <guid isPermaLink="false">9cTCNUkDdgVjdBN6M6JLv</guid>
            <dc:creator>Vasilis Giotsas</dc:creator>
            <dc:creator>Marwan Fayed</dc:creator>
        </item>
        <item>
            <title><![CDATA[A framework for measuring Internet resilience]]></title>
            <link>https://blog.cloudflare.com/a-framework-for-measuring-internet-resilience/</link>
            <pubDate>Tue, 28 Oct 2025 13:00:00 GMT</pubDate>
            <description><![CDATA[ We present a data-driven framework to quantify cross-layer Internet resilience. We also share a list of measurements with which to quantify facets of Internet resilience for geographical areas. ]]></description>
            <content:encoded><![CDATA[ <p></p><p>On July 8, 2022, a massive outage at Rogers, one of Canada's largest telecom providers, knocked out Internet and mobile services for over 12 million users. Why did this single event have such a catastrophic impact? And more importantly, why do some networks crumble in the face of disruption while others barely stumble?</p><p>The answer lies in a concept we call <b>Internet resilience</b>: a network's ability not just to stay online, but to withstand, adapt to, and rapidly recover from failures.</p><p>It’s a quality that goes far beyond simple "uptime." True resilience is a multi-layered capability, built on everything from the diversity of physical subsea cables to the security of BGP routing and the health of a competitive market. It's an emergent property much like <a href="https://en.wikipedia.org/wiki/Psychological_resilience"><u>psychological resilience</u></a>: while each individual network must be robust, true resilience only arises from the collective, interoperable actions of the entire ecosystem. In this post, we'll introduce a data-driven framework to move beyond abstract definitions and start quantifying what makes a network resilient. All of our work is based on public data sources, and we're sharing our metrics to help the entire community build a more reliable and secure Internet for everyone.</p>
    <div>
      <h2>What is Internet resilience?</h2>
      <a href="#what-is-internet-resilience">
        
      </a>
    </div>
    <p>In networking, we often talk about "reliability" (does it work under normal conditions?) and "robustness" (can it handle a sudden traffic surge?). But resilience is more dynamic. It's the ability to gracefully degrade, adapt, and most importantly, recover. For our work, we've adopted a pragmatic definition:</p><p><b><i>Internet resilience</i></b><i> is the measurable capability of a national or regional network ecosystem to maintain diverse and secure routing paths in the face of challenges, and to rapidly restore connectivity following a disruption.</i></p><p>This definition links the abstract goal of resilience to the concrete, measurable metrics that form the basis of our analysis.</p>
    <div>
      <h3>Local decisions have global impact</h3>
      <a href="#local-decisions-have-global-impact">
        
      </a>
    </div>
    <p>The Internet is a global system but is built out of thousands of local pieces. Every country depends on the global Internet for economic activity, communication, and critical services, yet most of the decisions that shape how traffic flows are made locally by individual networks.</p><p>In most national infrastructures like water or power grids, a central authority can plan, monitor, and coordinate how the system behaves. The Internet works very differently. Its core building blocks are Autonomous Systems (ASes), which are networks like ISPs, universities, cloud providers or enterprises. Each AS controls autonomously how it connects to the rest of the Internet, which routes it accepts or rejects, how it prefers to forward traffic, and with whom it interconnects. That’s why they’re called Autonomous Systems in the first place! There’s no global controller. Instead, the Internet’s routing fabric emerges from the collective interaction of thousands of independent networks, each optimizing for its own goals.</p><p>This decentralized structure is one of the Internet’s greatest strengths: no single failure can bring the whole system down. But it also makes measuring resilience at a country level tricky. National statistics can hide local structures that are crucial to global connectivity. For example, a country might appear to have many international connections overall, but those connections could be concentrated in just a handful of networks. If one of those fails, the whole country could be affected.</p><p>For resilience, the goal isn’t to isolate national infrastructure from the global Internet. In fact, the opposite is true: healthy integration with diverse partners is what makes both local and global connectivity stronger. When local networks invest in secure, redundant, and diverse interconnections, they improve their own resilience and contribute to the stability of the Internet as a whole.</p><p>This perspective shapes how we design and interpret resilience metrics. Rather than treating countries as isolated units, we look at how well their networks are woven into the global fabric: the number and diversity of upstream providers, the extent of international peering, and the richness of local interconnections. These are the building blocks of a resilient Internet.</p>
    <div>
      <h3>Route hygiene: Keeping the Internet healthy</h3>
      <a href="#route-hygiene-keeping-the-internet-healthy">
        
      </a>
    </div>
    <p>The Internet is constructed according to a <i>layered</i> model, by design, so that different Internet components and features can evolve independent of the others. The Physical layer stores, carries, and forwards, all the bits and bytes transmitted in packets between devices. It consists of cables, routers and switches, but also buildings that house interconnection facilities. The Application layer sits above all others and has virtually no information about the network so that applications can communicate without having to worry about the underlying details, for example, if a network is ethernet or Wi-Fi. The application layer includes web browsers, web servers, as well as caching, security, and other features provided by Content Distribution Networks (CDNs). Between the physical and application layers is the Network layer responsible for Internet routing. It is ‘logical’, consisting of software that learns about interconnection and routes, and makes (local) forwarding decisions that deliver packets to their destinations. </p><p>Good route hygiene works like personal hygiene: it prevents problems before they spread. The Internet relies on the <a href="https://www.cloudflare.com/learning/security/glossary/what-is-bgp/"><u>Border Gateway Protocol</u></a> (BGP) to exchange routes between networks, but BGP wasn’t built with security in mind. A single bad route announcement, whether by mistake or attack, can send traffic the wrong way or cause widespread outages.</p><p>Two practices help stop this: The <b>RPKI</b> (Resource Public Key Infrastructure) lets networks publish cryptographic proof that they’re allowed to announce specific IP prefixes. <b>ROV </b>(Route Origin Validation) checks those proofs before accepting routes.</p><p>Together, they act like passports and border checks for Internet routes, helping filter out hijacks and leaks early.</p><p>Hygiene doesn’t just happen in the routing table – it spans multiple layers of the Internet’s architecture, and weaknesses in one layer can ripple through the rest. At the physical layer, having multiple, geographically diverse cable routes ensures that a single cut or disaster doesn’t isolate an entire region. For example, distributing submarine landing stations along different coastlines can protect international connectivity when one corridor fails. At the network layer, practices like multi-homing and participation in Internet Exchange Points (IXPs) give operators more options to reroute traffic during incidents, reducing reliance on any single upstream provider. At the application layer, Content Delivery Networks (CDNs) and caching keep popular content close to users, so even if upstream routes are disrupted, many services remain accessible. Finally, policy and market structure also play a role: open peering policies and competitive markets foster diversity, while dependence on a single ISP or cable system creates fragility.</p><p>Resilience emerges when these layers work together. If one layer is weak, the whole system becomes more vulnerable to disruption.</p><p>The more networks adopt these practices, the stronger and more resilient the Internet becomes. We actively support the deployment of RPKI, ROV, and diverse routing to keep the global Internet healthy.</p>
    <div>
      <h2>Measuring resilience is harder than it sounds</h2>
      <a href="#measuring-resilience-is-harder-than-it-sounds">
        
      </a>
    </div>
    <p>The biggest hurdle in measuring resilience is data access. The most valuable information, like internal network topologies, the physical paths of fiber cables, or specific peering agreements, is held by private network operators. This is the ground truth of the network.</p><p>However, operators view this information as a highly sensitive competitive asset. Revealing detailed network maps could expose strategic vulnerabilities or undermine business negotiations. Without access to this ground truth data, we're forced to rely on inference, approximation, and the clever use of publicly available data sources. Our framework is built entirely on these public sources to ensure anyone can reproduce and build upon our findings.</p><p>Projects like RouteViews and RIPE RIS collect BGP routing data that shows how networks connect. <a href="https://www.cloudflare.com/en-in/learning/network-layer/what-is-mtr/"><u>Traceroute</u></a> measurements reveal paths at the router level. IXP and submarine cable maps give partial views of the physical layer. But each of these sources has blind spots: peering links often don’t appear in BGP data, backup paths may remain hidden, and physical routes are hard to map precisely. This lack of a single, complete dataset means that resilience measurement relies on combining many partial perspectives, a bit like reconstructing a city map from scattered satellite images, traffic reports, and public utility filings. It’s challenging, but it’s also what makes this field so interesting.</p>
    <div>
      <h3>Translating resilience into quantifiable metrics</h3>
      <a href="#translating-resilience-into-quantifiable-metrics">
        
      </a>
    </div>
    <p>Once we understand why resilience matters and what makes it hard to measure, the next step is to translate these ideas into concrete metrics. These metrics give us a way to evaluate how well different parts of the Internet can withstand disruptions and to identify where the weak points are. No single metric can capture Internet resilience on its own. Instead, we look at it from multiple angles: physical infrastructure, network topology, interconnection patterns, and routing behavior. Below are some of the key dimensions we use. Some of these metrics are inspired from existing research, like the <a href="https://pulse.internetsociety.org/en/resilience/"><u>ISOC Pulse</u></a> framework. All described methods rely on public data sources and are fully reproducible. As a result, in our visualizations we intentionally omit country and region names to maintain focus on the methodology and interpretation of the results. </p>
    <div>
      <h3>IXPs and colocation facilities</h3>
      <a href="#ixps-and-colocation-facilities">
        
      </a>
    </div>
    <p>Networks primarily interconnect in two types of physical facilities: colocation facilities (colos), and Internet Exchange Points (IXPs) often housed within the colos. Although symbiotically linked, they serve distinct functions in a nation’s digital ecosystem. A colocation facility provides the foundational infrastructure —- secure space, power, and cooling – for network operators to place their equipment. The IXP builds upon this physical base to provide the logical interconnection fabric, a role that is transformative for a region’s Internet development and resilience. The networks that connect at these facilities are its members. </p><p>Metrics that reflect resilience include:</p><ul><li><p><b>Number and distribution of IXPs</b>, normalized by population or geography. A higher IXP count, weighted by population or geographic coverage, is associated with improved local connectivity.</p></li><li><p><b>Peering participation rates</b> — the percentage of local networks connected to domestic IXPs. This metric reflects the extent to which local networks rely on regional interconnection rather than routing traffic through distant upstream providers.</p></li><li><p><b>Diversity of IXP membership</b>, including ISPs, CDNs, and cloud providers, which indicates how much critical content is available locally, making it accessible to domestic users even if international connectivity is severely degraded.</p></li></ul><p>Resilience also depends on how well local networks connect globally:</p><ul><li><p>How many <b>local networks peer at international IXPs</b>, increasing their routing options</p></li><li><p>How many <b>international networks peer at local IXPs</b>, bringing content closer to users</p></li></ul><p>A balanced flow in both directions strengthens resilience by ensuring multiple independent paths in and out of a region.</p><p>The geographic distribution of IXPs further enhances resilience. A resilient IXP ecosystem should be geographically dispersed to serve different regions within a country effectively, reducing the risk of a localized infrastructure failure from affecting the connectivity of an entire country. Spatial distribution metrics help evaluate how infrastructure is spread across a country’s geography or its population. Key spatial metrics include:</p><ul><li><p><b>Infrastructure per Capita</b>: This metric – inspired by <a href="https://en.wikipedia.org/wiki/Telephone_density"><u>teledensity</u></a>  – measures infrastructure relative to population size of a sub-region, providing a per-person availability indicator. A low IXP-per-population ratio in a region suggests that users there rely on distant exchanges, increasing the bit-risk miles.</p></li><li><p><b>Infrastructure per Area (Density)</b>: This metric evaluates how infrastructure is distributed per unit of geographic area, highlighting spatial coverage. Such area-based metrics are crucial for critical infrastructures to ensure remote areas are not left inaccessible.</p></li></ul><p>These metrics can be summarized using the <a href="https://www.bls.gov/k12/students/economics-made-easy/location-quotients.pdf"><u>Location Quotient (LQ)</u></a>. The location quotient is a widely used geographic index that measures a region’s share of infrastructure relative to its share of a baseline (such as population or area).</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4S52jlwCpQ8WVS6gRSdNqp/4722abb10331624a54b411708f1e576b/image5.png" />
          </figure><p>For example, the figure above represents US states where a region hosts more or less infrastructure that is expected for its population, based on its LQ score. This statistic illustrates how even for the states with the highest number of facilities this number is <i>still</i> lower than would be expected given the population size of those states.</p>
    <div>
      <h4>Economic-weighted metrics</h4>
      <a href="#economic-weighted-metrics">
        
      </a>
    </div>
    <p>While spatial metrics capture the physical distribution of infrastructure, economic and usage-weighted metrics reveal how infrastructure is actually used. These account for traffic, capacity, or economic activity, exposing imbalances that spatial counts miss. <b>Infrastructure Utilization Concentration</b> measures how usage is distributed across facilities, using indices like the <b>Herfindahl–Hirschman Index (HHI)</b>. HHI sums the squared market shares of entities, ranging from 0 (competitive) to 10,000 (highly concentrated). For IXPs, market share is defined through operational metrics such as:</p><ul><li><p><b>Peak/Average Traffic Volume</b> (Gbps/Tbps): indicates operational significance</p></li><li><p><b>Number of Connected ASNs</b>: reflects network reach</p></li><li><p><b>Total Port Capacity</b>: shows physical scale</p></li></ul><p>The chosen metric affects results. For example, using connected ASNs yields an HHI of 1,316 (unconcentrated) for a Central European country, whereas using port capacity gives 1,809 (moderately concentrated).</p><p>The <b>Gini coefficient</b> measures inequality in resource or traffic distribution (0 = equal, 1 = fully concentrated). The <b>Lorenz curve</b> visualizes this: a straight 45° line indicates perfect equality, while deviations show concentration.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/30bh4nVHRX5O3HMKvGRYh7/e0c5b3a7cb8294dfe3caaec98a0557d0/Screenshot_2025-10-27_at_14.10.57.png" />
          </figure><p>The chart on the left suggests substantial geographical inequality in colocation facility distribution across the US states. However, the population-weighted analysis in the chart on the right demonstrates that much of that geographic concentration can be explained by population distribution.</p>
    <div>
      <h3>Submarine cables</h3>
      <a href="#submarine-cables">
        
      </a>
    </div>
    <p>Internet resilience, in the context of undersea cables, is defined by the global network’s capacity to withstand physical infrastructure damage and to recover swiftly from faults, thereby ensuring the continuity of intercontinental data flow. The metrics for quantifying this resilience are multifaceted, encompassing the frequency and nature of faults, the efficiency of repair operations, and the inherent robustness of both the network’s topology and its dedicated maintenance resources. Such metrics include:</p><ul><li><p>Number of <b>landing stations</b>, cable corridors, and operators. The goal is to ensure that national connectivity should withstand single failure events, be they natural disaster, targeted attack, or major power outage. A lack of diversity creates single points of failure, as highlighted by <a href="https://www.theguardian.com/news/2025/sep/30/tonga-pacific-island-internet-underwater-cables-volcanic-eruption"><u>incidents in Tonga</u></a> where damage to the only available cable led to a total outage.</p></li><li><p><b>Fault rates</b> and <b>mean time to repair (MTTR)</b>, which indicate how quickly service can be restored. These metrics measure a country’s ability to prevent, detect, and recover from cable incidents, focusing on downtime reduction and protection of critical assets. Repair times hinge on <b>vessel mobilization</b> and <b>government permits</b>, the latter often the main bottleneck.</p></li><li><p>Availability of <b>satellite backup capacity</b> as an emergency fallback. While cable diversity is essential, resilience planning must also cover worst-case outages. The Non-Terrestrial Backup System Readiness metric measures a nation’s ability to sustain essential connectivity during major cable disruptions. LEO and MEO satellites, though costlier and lower capacity than cables, offer proven emergency backup during conflicts or disasters. Projects like HEIST explore hybrid space-submarine architectures to boost resilience. Key indicators include available satellite bandwidth, the number of NGSO providers under contract (for diversity), and the deployment of satellite terminals for public and critical infrastructure. Tracking these shows how well a nation can maintain command, relief operations, and basic connectivity if cables fail.</p></li></ul>
    <div>
      <h3>Inter-domain routing</h3>
      <a href="#inter-domain-routing">
        
      </a>
    </div>
    <p>The network layer above the physical interconnection infrastructure governs how traffic is routed across the Autonomous Systems (ASes). Failures or instability at this layer – such as misconfigurations, attacks, or control-plane outages – can disrupt connectivity even when the underlying physical infrastructure remains intact. In this layer, we look at resilience metrics that characterize the robustness and fault tolerance of AS-level routing and BGP behavior.</p><p><b>AS Path Diversity</b> measures the number and independence of AS-level routes between two points. High diversity provides alternative paths during failures, enabling BGP rerouting and maintaining connectivity. Low diversity leaves networks vulnerable to outages if a critical AS or link fails. Resilience depends on upstream topology.</p><ul><li><p>Single-homed ASes rely on one provider, which is cheaper and simpler but more fragile.</p></li><li><p>Multi-homed ASes use multiple upstreams, requiring BGP but offering far greater redundancy and performance at higher cost.</p></li></ul><p>The <b>share of multi-homed ASes</b> reflects an ecosystem’s overall resilience: higher rates signal greater protection from single-provider failures. This metric is easy to measure using <b>public BGP data</b> (e.g., RouteViews, RIPE RIS, CAIDA). Longitudinal BGP monitoring helps reveal hidden backup links that snapshots might miss.</p><p>Beyond multi-homing rates, <b>the distribution of single-homed ASes per transit provider</b> highlights systemic weak points. For each provider, counting customer ASes that rely exclusively on it reveals how many networks would be cut off if that provider fails. </p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/1ECZveUVwyM6TmGa1SaZnl/1222c7579c81fd62a5d8d80d63000ec3/image1.png" />
          </figure><p>The figure above shows Canadian transit providers for July 2025: the x-axis is total customer ASes, the y-axis is single-homed customers. Canada’s overall single-homing rate is 30%, with some providers serving many single-homed ASes, mirroring vulnerabilities seen during the <a href="https://en.wikipedia.org/wiki/2022_Rogers_Communications_outage"><u>2022 Rogers outage</u></a>, which disrupted over 12 million users.</p><p>While multi-homing metrics provide a valuable, static view of an ecosystem’s upstream topology, a more dynamic and nuanced understanding of resilience can be achieved by analyzing the characteristics of the actual BGP paths observed from global vantage points. These path-centric metrics move beyond simply counting connections to assess the diversity and independence of the routes to and from a country’s networks. These metrics include:</p><ul><li><p><b>Path independence</b> measures whether those alternative routes truly avoid shared bottlenecks. Multi-homing only helps if upstream paths are truly distinct. If two providers share upstream transit ASes, redundancy is weak. Independence can be measured with the Jaccard distance between AS paths. A stricter <b>path disjointness score</b> calculates the share of path pairs with no common ASes, directly quantifying true redundancy.</p></li><li><p><b>Transit entropy</b> measures how evenly traffic is distributed across transit providers. High Shannon entropy signals a decentralized, resilient ecosystem; low entropy shows dependence on few providers, even if nominal path diversity is high.</p></li><li><p><b>International connectivity ratios</b> evaluate the share of domestic ASes with direct international links. High percentages reflect a mature, distributed ecosystem; low values indicate reliance on a few gateways.</p></li></ul><p>The figure below encapsulates the aforementioned AS-level resilience metrics into single polar pie charts. For the purpose of exposition we plot the metrics for infrastructure from two different nations with very different resilience profiles.</p>
          <figure>
          <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/PKxDcl4m1XXCAuvFUcTdZ/d0bce797dcbd5e1baf39ca66e7ac0056/image4.png" />
          </figure><p>To pinpoint critical ASes and potential single points of failure, graph centrality metrics can provide useful insights. <b>Betweenness Centrality (BC)</b> identifies nodes lying on many shortest paths, but applying it to BGP data suffers from vantage point bias. ASes that provide BGP data to the RouteViews and RIS collectors appear falsely central. <b>AS Hegemony</b>, developed by<a href="https://dl.acm.org/doi/10.1145/3123878.3131982"><u> Fontugne et al.</u></a>, corrects this by filtering biased viewpoints, producing a 0–1 score that reflects the true fraction of paths crossing an AS. It can be applied globally or locally to reveal Internet-wide or AS-specific dependencies.</p><p><b>Customer cone size</b> developed by <a href="https://asrank.caida.org/about#customer-cone"><u>CAIDA</u></a> offers another perspective, capturing an AS’s economic and routing influence via the set of networks it serves through customer links. Large cones indicate major transit hubs whose failure affects many downstream networks. However, global cone rankings can obscure regional importance, so <a href="https://www.caida.org/catalog/papers/2023_on_importance_being_as/on_importance_being_as.pdf"><u>country-level adaptations</u></a> give more accurate resilience assessments.</p>
    <div>
      <h4>Impact-Weighted Resilience Assessment</h4>
      <a href="#impact-weighted-resilience-assessment">
        
      </a>
    </div>
    <p>Not all networks have the same impact when they fail. A small hosting provider going offline affects far fewer people than if a national ISP does. Traditional resilience metrics treat all networks equally, which can mask where the real risks are. To address this, we use impact-weighted metrics that factor in a network’s user base or infrastructure footprint. For example, by weighting multi-homing rates or path diversity by user population, we can see how many people actually benefit from redundancy — not just how many networks have it. Similarly, weighting by the number of announced prefixes highlights networks that carry more traffic or control more address space.</p><p>This approach helps separate theoretical resilience from practical resilience. A country might have many multi-homed networks, but if most users rely on just one single-homed ISP, its resilience is weaker than it looks. Impact weighting helps surface these kinds of structural risks so that operators and policymakers can prioritize improvements where they matter most.</p>
    <div>
      <h3>Metrics of network hygiene</h3>
      <a href="#metrics-of-network-hygiene">
        
      </a>
    </div>
    <p>Large Internet outages aren’t always caused by cable cuts or natural disasters — sometimes, they stem from routing mistakes or security gaps. Route hijacks, leaks, and spoofed announcements can disrupt traffic on a national scale. How well networks protect themselves against these incidents is a key part of resilience, and that’s where network hygiene comes in.</p><p>Network hygiene refers to the security and operational practices that make the global routing system more trustworthy. This includes:</p><ul><li><p><b>Cryptographic validation</b>, like RPKI, to prevent unauthorized route announcements. <b>ROA Coverage</b> measures the share of announced IPv4/IPv6 space with valid Route Origin Authorizations (ROAs), indicating participation in the RPKI ecosystem. <b>ROV Deployment</b> gauges how many networks drop invalid routes, but detecting active filtering is difficult. Policymakers can improve visibility by supporting independent measurements, data transparency, and standardized reporting.</p></li><li><p><b>Filtering and cooperative norms</b>, where networks block bogus routes and follow best practices when sharing routing information.</p></li><li><p><b>Consistent deployment across both domestic networks and their international upstreams</b>, since traffic often crosses multiple jurisdictions.</p></li></ul><p>Strong hygiene practices reduce the likelihood of systemic routing failures and limit their impact when they occur. We actively support and monitor the adoption of these mechanisms, for instance through <a href="https://isbgpsafeyet.com/"><u>crowd-sourced measurements</u></a> and public advocacy, because every additional network that validates routes and filters traffic contributes to a safer and more resilient Internet for everyone.</p><p>Another critical aspect of Internet hygiene is mitigating DDoS attacks, which often rely on IP address spoofing to amplify traffic and obscure the attacker’s origin. <a href="https://datatracker.ietf.org/doc/bcp38/"><u>BCP-38</u></a>, the IETF’s network ingress filtering recommendation, addresses this by requiring operators to block packets with spoofed source addresses, reducing a region’s role as a launchpad for global attacks. While BCP-38 does not prevent a network from being targeted, its deployment is a key indicator of collective security responsibility. Measuring compliance requires active testing from inside networks, which is carried out by the <a href="https://spoofer.caida.org/summary.php"><u>CAIDA Spoofer Project</u></a>. Although the global sample remains limited, these metrics offer valuable insight into both the technical effectiveness and the security engagement of a nation’s network community, complementing RPKI in strengthening the overall routing security posture.</p>
    <div>
      <h3>Measuring the collective security posture</h3>
      <a href="#measuring-the-collective-security-posture">
        
      </a>
    </div>
    <p>Beyond securing individual networks through mechanisms like RPKI and BCP-38, strengthening the Internet’s resilience also depends on collective action and visibility. While origin validation and anti-spoofing reduce specific classes of threats, broader frameworks and shared measurement infrastructures are essential to address systemic risks and enable coordinated responses.</p><p>The <a href="https://manrs.org/"><u>Mutually Agreed Norms for Routing Security (MANRS)</u></a> initiative promotes Internet resilience by defining a clear baseline of best practices. It is not a new technology but a framework fostering collective responsibility for global routing security. MANRS focuses on four key actions: filtering incorrect routes, anti-spoofing, coordination through accurate contact information, and global validation using RPKI and IRRs. While many networks implement these independently, MANRS participation signals a public commitment to these norms and to strengthening the shared security ecosystem.</p><p>Additionally, a region’s participation in public measurement platforms reflects its Internet observability, which is essential for fault detection, impact assessment, and incident response. <a href="https://atlas.ripe.net/"><u>RIPE Atlas</u></a> and <a href="https://www.caida.org/projects/ark/"><u>CAIDA Ark</u></a> provide dense data-plane measurements; <a href="https://www.routeviews.org/routeviews/"><u>RouteViews</u></a> and <a href="https://www.ripe.net/analyse/internet-measurements/routing-information-service-ris/"><u>RIPE RIS</u></a> collect BGP routing data to detect anomalies; and <a href="https://www.peeringdb.com/"><u>PeeringDB</u></a> documents interconnection details, reflecting operational maturity and integration into the global peering fabric. Together, these platforms underpin observatories like <a href="https://ioda.inetintel.cc.gatech.edu/"><u>IODA</u></a> and <a href="https://grip.oie.gatech.edu/home"><u>GRIP</u></a>, which combine BGP and active data to detect outages and routing incidents in near real time, offering critical visibility into Internet health and security.</p>
    <div>
      <h2>Building a more resilient Internet, together</h2>
      <a href="#building-a-more-resilient-internet-together">
        
      </a>
    </div>
    <p>Measuring Internet resilience is complex, but it's not impossible. By using publicly available data, we can create a transparent and reproducible framework to identify strengths, weaknesses, and single points of failure in any network ecosystem.</p><p>This isn't just a theoretical exercise. For policymakers, this data can inform infrastructure investment and pro-competitive policies that encourage diversity. For network operators, it provides a benchmark to assess their own resilience and that of their partners. And for everyone who relies on the Internet, it's a critical step toward building a more stable, secure, and reliable global network.</p><p><i>For more details of the framework, including a full table of the metrics and links to source code, please refer to the full paper: </i> <a href="https://papers.ssrn.com/sol3/papers.cfm?abstract_id=5376106"><u>Regional Perspectives for Route Resilience in a Global Internet: Metrics, Methodology, and Pathways for Transparency</u></a> published at <a href="https://www.tprcweb.com/tprc23program"><u>TPRC23</u></a>.</p> ]]></content:encoded>
            <category><![CDATA[Research]]></category>
            <category><![CDATA[Better Internet]]></category>
            <category><![CDATA[Routing Security]]></category>
            <category><![CDATA[Insights]]></category>
            <guid isPermaLink="false">48ry6RI3JhA9H3t280EWUX</guid>
            <dc:creator>Vasilis Giotsas</dc:creator>
            <dc:creator>Cefan Daniel Rubin</dc:creator>
            <dc:creator>Marwan Fayed</dc:creator>
        </item>
        <item>
            <title><![CDATA[Helping build a safer Internet by measuring BGP RPKI Route Origin Validation]]></title>
            <link>https://blog.cloudflare.com/rpki-updates-data/</link>
            <pubDate>Fri, 16 Dec 2022 14:00:00 GMT</pubDate>
            <description><![CDATA[ Is BGP safe yet? If the question needs asking, then it isn't. But how far the Internet is from this goal is what we set out to answer. ]]></description>
            <content:encoded><![CDATA[ 
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/1VWVhVnz5Xbv2u1jm48KeJ/dd52aaf9426c64b5d2b68a0b7651cb93/image7-7.png" />
            
            </figure><p>The <a href="https://www.cloudflare.com/learning/security/glossary/what-is-bgp/">Border Gateway Protocol</a> (BGP) is the glue that keeps the entire Internet together. However, despite its vital function, BGP wasn't originally designed to protect against malicious actors or routing mishaps. It has since been updated to account for this shortcoming with the <a href="https://en.wikipedia.org/wiki/Resource_Public_Key_Infrastructure">Resource Public Key Infrastructure</a> (RPKI) framework, but can we declare it to be safe yet?</p><p>If the question needs asking, you might suspect we can't. There is a shortage of reliable data on how much of the Internet is protected from preventable routing problems. Today, we’re releasing a new method to measure exactly that: what percentage of Internet users are protected by their Internet Service Provider from these issues. We find that there is a long way to go before the Internet is protected from routing problems, though it varies dramatically by country.</p>
    <div>
      <h3>Why RPKI is necessary to secure Internet routing</h3>
      <a href="#why-rpki-is-necessary-to-secure-internet-routing">
        
      </a>
    </div>
    <p>The Internet is a network of independently-managed networks, called <a href="https://www.cloudflare.com/learning/network-layer/what-is-an-autonomous-system/">Autonomous Systems (ASes)</a>. To achieve global reachability, ASes interconnect with each other and determine the feasible paths to a given destination IP address by exchanging routing information using BGP. BGP enables routers with only local network visibility to construct end-to-end paths based on the arbitrary preferences of each administrative entity that operates that equipment. Typically, Internet traffic between a user and a destination traverses multiple AS networks using paths constructed by BGP routers.</p><p>BGP, however, lacks built-in security mechanisms to protect the integrity of the exchanged routing information and to provide authentication and authorization of the advertised IP address space. Because of this, AS operators must implicitly trust that the routing information exchanged through BGP is accurate. As a result, the Internet is vulnerable to the injection of bogus routing information, which cannot be mitigated by security measures at the client or server level of the network.</p><p>An adversary with access to a BGP router can inject fraudulent routes into the routing system, which can be used to execute an array of attacks, including:</p><ul><li><p>Denial-of-Service (DoS) through traffic blackholing or redirection,</p></li><li><p>Impersonation attacks to eavesdrop on communications,</p></li><li><p>Machine-in-the-Middle exploits to modify the exchanged data, and subvert reputation-based filtering systems.</p></li></ul><p>Additionally, local misconfigurations and fat-finger errors can be propagated well beyond the source of the error and cause major disruption across the Internet.</p><p>Such an incident happened on <a href="/how-verizon-and-a-bgp-optimizer-knocked-large-parts-of-the-internet-offline-today/">June 24, 2019</a>. Millions of users were unable to access Cloudflare address space when a regional ISP in Pennsylvania accidentally advertised routes to Cloudflare through their capacity-limited network. This was effectively the Internet equivalent of routing an entire freeway through a neighborhood street.</p><p>Traffic misdirections like these, either unintentional or intentional, are not uncommon. The Internet Society’s <a href="https://www.manrs.org/">MANRS</a> (Mutually Agreed Norms for Routing Security) initiative estimated that in 2020 alone there were <a href="https://www.manrs.org/2021/03/a-regional-look-into-bgp-incidents-in-2020/">over 3,000 route leaks and hijacks</a>, and new occurrences can be <a href="/route-leak-detection-with-cloudflare-radar/">observed every day through Cloudflare Radar.</a></p><p>The most prominent proposals to secure BGP routing, standardized by the <a href="https://www.ietf.org/about/introduction/">IETF</a> focus on validating the origin of the advertised routes using <a href="https://en.wikipedia.org/wiki/Resource_Public_Key_Infrastructure">Resource Public Key Infrastructure</a> (RPKI) and verifying the integrity of the paths with <a href="https://en.wikipedia.org/wiki/BGPsec">BGPsec</a>. Specifically, RPKI (defined in <a href="https://www.rfc-editor.org/rfc/rfc7115.html">RFC 7115</a>) relies on a <a href="https://en.wikipedia.org/wiki/Public_key_infrastructure">Public Key Infrastructure</a> to validate that an AS advertising a route to a destination (an IP address space) is the legitimate owner of those IP addresses.</p><p>RPKI has been defined for a long time but lacks adoption. It requires network operators to cryptographically sign their prefixes, and routing networks to perform an RPKI Route Origin Validation (ROV) on their routers. This is a two-step operation that requires coordination and participation from many actors to be effective.</p>
    <div>
      <h3>The two phases of RPKI adoption: signing origins and validating origins</h3>
      <a href="#the-two-phases-of-rpki-adoption-signing-origins-and-validating-origins">
        
      </a>
    </div>
    <p>RPKI has two phases of deployment: first, an AS that wants to protect its own IP prefixes can cryptographically sign Route Origin Authorization (ROA) records thereby attesting to be the legitimate origin of that signed IP space. Second, an AS can avoid selecting invalid routes by performing Route Origin Validation (ROV, defined in <a href="https://www.rfc-editor.org/rfc/rfc6483">RFC 6483</a>).</p><p>With ROV, a BGP route received by a neighbor is validated against the available RPKI records. A route that is valid or missing from RPKI is selected, while a route with RPKI records found to be invalid is typically rejected, thus preventing the use and propagation of hijacked and misconfigured routes.</p><p>One issue with RPKI is the fact that implementing ROA is meaningful only if other ASes implement ROV, and vice versa. Therefore, securing BGP routing requires a united effort and a lack of broader adoption disincentivizes ASes from commiting the resources to validate their own routes. Conversely, increasing RPKI adoption can lead to network effects and accelerate RPKI deployment. Projects like MANRS and Cloudflare’s <a href="https://isbgpsafeyet.com/">isbgpsafeyet.com</a> are promoting good Internet citizenship among network operators, and make the benefits of RPKI deployment known to the Internet. You can check whether your own ISP is being a good Internet citizen by testing it on <a href="https://isbgpsafeyet.com/">isbgpsafeyet.com</a>.</p><p>Measuring the extent to which both ROA (signing of addresses by the network that controls them) and ROV (filtering of invalid routes by ISPs) have been implemented is important to evaluating the impact of these initiatives, developing situational awareness, and predicting the impact of future misconfigurations or attacks.</p><p>Measuring ROAs is straightforward since ROA data is <a href="https://ftp.ripe.net/rpki/">readily available</a> from RPKI repositories. Querying RPKI repositories for publicly routed IP prefixes (e.g. prefixes visible in the <a href="http://www.routeviews.org/">RouteViews</a> and <a href="https://www.ripe.net/analyse/internet-measurements/routing-information-service-ris">RIPE RIS</a> routing tables) allows us to estimate the percentage of addresses covered by ROA objects. Currently, there are 393,344 IPv4 and 86,306 IPv6 ROAs in the global RPKI system, covering about 40% of the globally routed prefix-AS origin pairs<sup>1</sup>.</p><p>Measuring ROV, however, is significantly more challenging given it is configured inside the BGP routers of each AS, not accessible by anyone other than each router’s administrator.</p>
    <div>
      <h3>Measuring ROV deployment</h3>
      <a href="#measuring-rov-deployment">
        
      </a>
    </div>
    <p>Although we do not have direct access to the configuration of everyone’s BGP routers, it is possible to infer the use of ROV by comparing the reachability of RPKI-valid and RPKI-invalid prefixes from measurement points within an AS<sup>2</sup>.</p><p>Consider the following toy topology as an example, where an RPKI-invalid origin is advertised through AS0 to AS1 and AS2. If AS1 filters and rejects RPKI-invalid routes, a user behind AS1 would not be able to connect to that origin. By contrast, if AS2 does not reject RPKI invalids, a user behind AS2 would be able to connect to that origin.</p><p>While occasionally a user may be unable to access an origin due to transient network issues, if multiple users act as vantage points for a measurement system, we would be able to collect a large number of data points to infer which ASes deploy ROV.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3ix5pgVzjgMlL7BugvGJDD/aff6d6eaf101da010a24fa8e7908b106/1-1.png" />
            
            </figure><p>If, in the figure above, AS0 filters invalid RPKI routes, then vantage points in both AS1 and AS2 would be unable to connect to the RPKI-invalid origin, making it hard to distinguish if ROV is deployed at the ASes of our vantage points or in an AS along the path. One way to mitigate this limitation is to announce the RPKI-invalid origin from multiple locations from an anycast network taking advantage of its direct interconnections to the measurement vantage points as shown in the figure below. As a result, an AS that does not itself deploy ROV is less likely to observe the benefits of upstream ASes using ROV, and we would be able to accurately infer ROV deployment per AS<sup>3</sup>.</p><p><i>Note that it’s also important that the IP address of the RPKI-invalid origin should not be covered by a less specific prefix for which there is a valid or unknown RPKI route, otherwise even if an AS filters invalid RPKI routes its users would still be able to find a route to that IP.</i></p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7HDnUbqxvRQ3DbhArqJsMg/a21bfe1ef026a4aa615ac21f759d3f3f/2-1.png" />
            
            </figure><p>The measurement technique described here is the one implemented by Cloudflare’s <a href="https://isbgpsafeyet.com">isbgpsafeyet.com</a> website, allowing end users to assess whether or not their ISPs have deployed BGP ROV.</p><p>The <a href="https://isbgpsafeyet.com/">isbgpsafeyet.com</a> website itself doesn't submit any data back to Cloudflare, but recently we started measuring whether end users’ browsers can successfully connect to invalid RPKI origins when ROV is present. We use the same mechanism as is used for <a href="/network-performance-update-developer-week/">global performance data</a><sup>4</sup>. In particular, every measurement session (an individual end user at some point in time) attempts a request to both valid.rpki.cloudflare.com, which should always succeed as it’s RPKI-valid, and invalid.rpki.cloudflare.com, which is RPKI-invalid and should fail when the user’s ISP uses ROV.</p><p>This allows us to have continuous and up-to-date measurements from hundreds of thousands of browsers on a daily basis, and develop a greater understanding of the state of ROV deployment.</p>
    <div>
      <h3>The state of global ROV deployment</h3>
      <a href="#the-state-of-global-rov-deployment">
        
      </a>
    </div>
    <p>The figure below shows the raw number of ROV probe requests per hour during October 2022 to <i>valid.rpki.cloudflare.com</i> and <i>invalid.rpki.cloudflare.com</i>. In total, we observed 69.7 million successful probes from 41,531 ASNs.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/16AWpr0oNevsWJynpNN1v4/51885d284ed9360416c915a935f19d6d/3-1.png" />
            
            </figure><p>Based on <a href="https://labs.apnic.net/?p=526">APNIC's estimates</a> on the number of end users per ASN, our weighted<sup>5</sup> analysis covers 96.5% of the world's Internet population. As expected, the number of requests follow a diurnal pattern which reflects established user behavior in daily and weekly Internet activity<sup>6</sup>.</p><p>We can also see that the number of successful requests to <i>valid.rpki.cloudflare.com</i> (<b><i>gray line</i></b>) closely follows the number of sessions that issued at least one request (<b><i>blue line</i></b>), which works as a smoke test for the correctness of our measurements.</p><p>As we don't store the IP addresses that contribute measurements, we don’t have any way to count individual clients and large spikes in the data may introduce unwanted bias. We account for that by capturing those instants and excluding them.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/2rou45RM7Y0NdF2opTgGZE/0e708f6e801926147cd498a355751b21/4-1.png" />
            
            </figure><p>Overall, we estimate that out of the four billion Internet users, <b>only 261 million (6.5%) are protected by BGP Route Origin Validation</b>, but the true state of global ROV deployment is more subtle than this.</p><p>The following map shows the fraction of dropped RPKI-invalid requests from ASes with over 200 probes over the month of October. It depicts how far along each country is in adopting ROV but doesn’t necessarily represent the fraction of protected users in each country, as we will discover.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3UzNnhgQaIpcQktYHwNwpf/b6a389c9ed94e49456c75aa0f8689264/5-1.png" />
            
            </figure><p>Sweden and Bolivia appear to be the countries with the highest level of adoption (over 80%), while only a few other countries have crossed the 50% mark (e.g. Finland, Denmark, Chad, Greece, the United States).</p><p>ROV adoption may be driven by a few ASes hosting large user populations, or by many ASes hosting small user populations. To understand such disparities, the map below plots the contrast between overall adoption in a country (as in the previous map) and median adoption over the individual ASes within that country. Countries with stronger reds have relatively few ASes deploying ROV with high impact, while countries with stronger blues have more ASes deploying ROV but with lower impact per AS.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6m2lvwtrbDEzDObM6NfW5W/2371a8bdb5f7ed5ed4981103d4aad4c5/6-1.png" />
            
            </figure><p>In the Netherlands, Denmark, Switzerland, or the United States, adoption appears mostly driven by their larger ASes, while in Greece or Yemen it’s the smaller ones that are adopting ROV.</p><p>The following histogram summarizes the worldwide level of adoption for the 6,765 ASes covered by the previous two maps.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/5zg7hScwuknrlGP0z76zvx/6fa811c1f9f92f50397ec64267b0af73/7.png" />
            
            </figure><p>Most ASes either don’t validate at all, or have close to 100% adoption, which is what we’d intuitively expect. However, it's interesting to observe that there are small numbers of ASes all across the scale. ASes that exhibit partial RPKI-invalid drop rate compared to total requests may either implement ROV partially (on some, but not all, of their BGP routers), or appear as dropping RPKI invalids due to ROV deployment by other ASes in their upstream path.</p><p>To estimate the number of users protected by ROV we only considered ASes with an observed adoption above <b>95%</b>, as an AS with an incomplete deployment still leaves its users vulnerable to route leaks from its BGP peers.</p><p>If we take the previous histogram and summarize by the number of users behind each AS, the green bar on the right corresponds to the <b>261 million</b> users currently protected by ROV according to the above criteria (686 ASes).</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/NAtYPcWbDWsiBiMfX56es/40a59d3253b0cba83c6e1bde2bbf83a6/8.png" />
            
            </figure><p>Looking back at the country adoption map one would perhaps expect the number of protected users to be larger. But worldwide ROV deployment is still mostly partial, lacking larger ASes, or both. This becomes even more clear when compared with the next map, plotting just the fraction of fully protected users.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7kAM05eOwaPusgkvSIASoB/e86386a84c161919b3bdc9018145eb1c/9.png" />
            
            </figure><p>To wrap up our analysis, we look at two world economies chosen for their contrasting, almost symmetrical, stages of deployment: the United States and the European Union.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3DShkKyva4l7rm5qC7gQnP/2ba1802f7d305815450bc1b9df372abb/10.png" />
            
            </figure>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4Q0ipIYrllZ63MXSRYEh59/bc25c31c0de0b71c157f909e5eb8522f/11.png" />
            
            </figure><p>112 million Internet users are protected by 111 ASes from the United States with comprehensive ROV deployments. Conversely, more than twice as many ASes from countries making up the European Union have fully deployed ROV, but end up covering only half as many users. This can be reasonably explained by end user ASes being more likely to operate within a single country rather than span multiple countries.</p>
    <div>
      <h3>Conclusion</h3>
      <a href="#conclusion">
        
      </a>
    </div>
    <p>Probe requests were performed from end user browsers and very few measurements were collected from transit providers (which have few end users, if any). Also, paths between end user ASes and Cloudflare are often very short (a nice outcome of our extensive peering) and don't traverse upper-tier networks that they would otherwise use to reach the rest of the Internet.</p><p>In other words, the methodology used focuses on ROV adoption by <b>end user networks</b> (e.g. ISPs) and isn’t meant to reflect the eventual effect of indirect validation from (perhaps validating) upper-tier transit networks. While indirect validation may limit the "blast radius" of (malicious or accidental) route leaks, it still leaves non-validating ASes vulnerable to leaks coming from their peers.</p><p>As with indirect validation, an AS remains vulnerable until its ROV deployment reaches a sufficient level of completion. We chose to only consider AS deployments above 95% as truly comprehensive, and <a href="https://radar.cloudflare.com">Cloudflare Radar</a> will soon begin using this threshold to track ROV adoption worldwide, as part of our mission to help build a better Internet.</p><p>When considering only comprehensive ROV deployments, some countries such as Denmark, Greece, Switzerland, Sweden, or Australia, already show an effective coverage above 50% of their respective Internet populations, with others like the Netherlands or the United States slightly above 40%, mostly driven by few large ASes rather than many smaller ones.</p><p>Worldwide we observe a very low effective coverage of just <b>6.5%</b> over the measured ASes, corresponding to <b>261 million</b> end users currently safe from (malicious and accidental) route leaks, which means there’s still a long way to go before we can declare BGP to be safe.</p><p>......</p><p><sup>1</sup><a href="https://rpki.cloudflare.com/">https://rpki.cloudflare.com/</a></p><p><sup>2</sup>Gilad, Yossi, Avichai Cohen, Amir Herzberg, Michael Schapira, and Haya Shulman. "Are we there yet? On RPKI's deployment and security." Cryptology ePrint Archive (2016).</p><p><sup>3</sup>Geoff Huston. “Measuring ROAs and ROV”. <a href="https://blog.apnic.net/2021/03/24/measuring-roas-and-rov/">https://blog.apnic.net/2021/03/24/measuring-roas-and-rov/</a>
<sup>4</sup>Measurements are issued stochastically when users encounter 1xxx error pages from default (non-customer) configurations.</p><p><sup>5</sup>Probe requests are weighted by AS size as calculated from Cloudflare's <a href="https://radar.cloudflare.com/">worldwide HTTP traffic</a>.</p><p><sup>6</sup>Quan, Lin, John Heidemann, and Yuri Pradkin. "When the Internet sleeps: Correlating diurnal networks with external factors." In Proceedings of the 2014 Conference on Internet Measurement Conference, pp. 87-100. 2014.</p> ]]></content:encoded>
            <category><![CDATA[Impact Week]]></category>
            <category><![CDATA[Radar]]></category>
            <category><![CDATA[BGP]]></category>
            <category><![CDATA[RPKI]]></category>
            <category><![CDATA[Routing Security]]></category>
            <category><![CDATA[Better Internet]]></category>
            <guid isPermaLink="false">dMGl1iwWVn3YZWRTxIzgV</guid>
            <dc:creator>Carlos Rodrigues</dc:creator>
            <dc:creator>Vasilis Giotsas</dc:creator>
        </item>
        <item>
            <title><![CDATA[How we detect route leaks and our new Cloudflare Radar route leak service]]></title>
            <link>https://blog.cloudflare.com/route-leak-detection-with-cloudflare-radar/</link>
            <pubDate>Wed, 23 Nov 2022 16:00:00 GMT</pubDate>
            <description><![CDATA[ In this blog post, we will introduce our new system designed to detect route leaks and its integration on Cloudflare Radar and its public API. ]]></description>
            <content:encoded><![CDATA[ <p></p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/5tjdb8oktiBnsjsr6Fj109/dca51bae6a054cc120d91c11a35c54fe/image5-19.png" />
            
            </figure><p>Today we’re introducing Cloudflare Radar’s route leak data and API so that anyone can get information about route leaks across the Internet. We’ve built a comprehensive system that takes in data from public sources and Cloudflare’s view of the Internet drawn from our massive global network. The system is now feeding route leak data on Cloudflare Radar’s ASN pages and via the API.</p><p>This blog post is in two parts. There’s a discussion of BGP and route leaks followed by details of our route leak detection system and how it feeds Cloudflare Radar.</p>
    <div>
      <h2>About BGP and route leaks</h2>
      <a href="#about-bgp-and-route-leaks">
        
      </a>
    </div>
    <p>Inter-domain routing, i.e., exchanging reachability information among networks, is critical to the wellness and performance of the Internet. The <a href="https://www.cloudflare.com/learning/security/glossary/what-is-bgp/">Border Gateway Protocol</a> (BGP) is the de facto routing protocol that exchanges routing information among organizations and networks. At its core, BGP assumes the information being exchanged is genuine and trust-worthy, which unfortunately is <a href="/rpki/">no longer a valid assumption</a> on the current Internet. In many cases, networks can make mistakes or intentionally lie about the reachability information and propagate that to the rest of the Internet. Such incidents can cause significant disruptions of the normal operations of the Internet. One type of such disruptive incident is <b>route leaks</b>.</p><p>We consider route leaks as the propagation of routing announcements beyond their intended scope (<a href="https://www.rfc-editor.org/rfc/rfc7908.html">RFC7908</a>). Route leaks can cause significant disruption affecting millions of Internet users, as we have seen in many past notable incidents. For example, <a href="/how-verizon-and-a-bgp-optimizer-knocked-large-parts-of-the-internet-offline-today/">in June 2019 a misconfiguration</a> in a small network in Pennsylvania, US (<a href="https://radar.cloudflare.com/traffic/as396531">AS396531</a> - Allegheny Technologies Inc) accidentally leaked a Cloudflare prefix to Verizon, which proceeded to propagate the misconfigured route to the rest of its peers and customers. As a result, the traffic of a large portion of the Internet was squeezed through the limited-capacity links of a small network. The resulting congestion caused most of Cloudflare traffic to and from the affected IP range to be dropped.</p><p>A similar incident in November 2018 caused widespread unavailability of Google services when a Nigerian ISP (<a href="https://radar.cloudflare.com/traffic/as37282">AS37282</a> - Mainone) <a href="/how-a-nigerian-isp-knocked-google-offline/">accidentally leaked</a> a large number of Google IP prefixes to its peers and providers violating the <a href="https://ieeexplore.ieee.org/document/974527">valley-free principle</a>.</p><p>These incidents illustrate not only that route leaks can be very impactful, but also the snowball effects that misconfigurations in small regional networks can have on the global Internet.</p><p>Despite the criticality of detecting and rectifying route leaks promptly, they are often detected only when users start reporting the noticeable effects of the leaks. The challenge with detecting and preventing route leaks stems from the fact that AS business relationships and BGP routing policies are generally <a href="https://ieeexplore.ieee.org/document/974523">undisclosed</a>, and the affected network is often remote to the root of the route leak.</p><p>In the past few years, solutions have been proposed to prevent the propagation of leaked routes. Such proposals include <a href="https://datatracker.ietf.org/doc/rfc9234/">RFC9234</a> and <a href="https://datatracker.ietf.org/doc/html/draft-ietf-sidrops-aspa-verification">ASPA</a>, which extends the BGP to annotate sessions with the relationship type between the two connected AS networks to enable the detention and prevention of route leaks.</p><p>An alternative proposal to implement similar signaling of BGP roles is through the use of <a href="https://en.wikipedia.org/wiki/Border_Gateway_Protocol#Communities">BGP Communities</a>; a transitive attribute used to encode metadata in BGP announcements. While these directions are promising in the long term, they are still in very preliminary stages and are not expected to be adopted at scale soon.</p><p>At Cloudflare, we have developed a system to detect route leak events automatically and send notifications to multiple channels for visibility. As we continue our efforts to bring more relevant <a href="https://developers.cloudflare.com/radar/">data to the public</a>, we are happy to announce that we are starting an <a href="https://developers.cloudflare.com/api/operations/radar_get_BGPRouteLeakEvents">open data API</a> for our route leak detection results today and integrate results to <a href="https://radar.cloudflare.com/">Cloudflare Radar</a> pages.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4bWYvHZtatR3ooYMKq2WCb/79ef433f8c46c40aefa2fefe35905aa7/image4-32.png" />
            
            </figure>
    <div>
      <h2>Route leak definition and types</h2>
      <a href="#route-leak-definition-and-types">
        
      </a>
    </div>
    <p>Before we jump into how we design our systems, we will first do a quick primer on what a route leak is, and why it is important to detect it.</p><p>We refer to the published IETF RFC7908 document <a href="https://www.rfc-editor.org/rfc/rfc7908.html"><i>"Problem Definition and Classification of BGP Route Leaks"</i></a> to define route leaks.</p><p>&gt; A route leak is the propagation of routing announcement(s) beyond their intended scope.</p><p>The <i>intended scope</i> is often concretely defined as inter-domain routing policies based on business relationships between Autonomous Systems (ASes). These business relationships <a href="https://ieeexplore.ieee.org/document/974527">are broadly classified into four categories</a>: customers, transit providers, peers and siblings, although more complex arrangements are possible.</p><p>In a customer-provider relationship the customer AS has an agreement with another network to transit its traffic to the global routing table. In a peer-to-peer relationship two ASes agree to free bilateral traffic exchange, but only between their own IPs and the IPs of their customers. Finally, ASes that belong under the same administrative entity are considered siblings, and their traffic exchange is often unrestricted.  The image below illustrates how the three main relationship types translate to export policies.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3XAOHLT8UtzkLQigSbcrUd/34f8de710fcdda2c4feb7fd1eaaec576/image7-7.png" />
            
            </figure><p>By categorizing the types of AS-level relationships and their implications on the propagation of BGP routes, we can define multiple phases of a prefix origination announcements during propagation:</p><ul><li><p>upward: all path segments during this phase are <b>customer to provider</b></p></li><li><p>peering: one peer-peer path segment</p></li><li><p>downward: all path segments during this phase are <b>provider to customer</b></p></li></ul><p>An AS path that follows <a href="https://ieeexplore.ieee.org/document/6363987"><b>valley-free routing principle</b></a> will have <b>upward, peering, downward</b> phases, <b>all optional</b> but have to be <b>in that order</b>. Here is an example of an AS path that conforms with valley-free routing.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7mm4sD88Ai3cFOS7ugzhoH/d0ea889e5d22d60d4648b7f13a69b08b/image11-4.png" />
            
            </figure><p>In RFC7908, <a href="https://www.rfc-editor.org/rfc/rfc7908.html"><i>"Problem Definition and Classification of BGP Route Leaks"</i></a>, the authors define six types of route leaks, and we refer to these definitions in our system design. Here are illustrations of each of the route leak types.</p>
    <div>
      <h3>Type 1: Hairpin Turn with Full Prefix</h3>
      <a href="#type-1-hairpin-turn-with-full-prefix">
        
      </a>
    </div>
    <p>&gt; A multihomed AS learns a route from one upstream ISP and simply propagates it to another upstream ISP (the turn essentially resembling a hairpin).  Neither the prefix nor the AS path in the update is altered.</p><p>An AS path that contains a provider-customer and customer-provider segment is considered a type 1 leak. The following example: AS4 → AS5 → AS6 forms a type 1 leak.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6Njxtz1neeF3ejVaLH6RPi/4836161f45d7f547608839f3a11467dd/image9-5.png" />
            
            </figure><p>Type 1 is the most recognized type of route leaks and is very impactful. In many cases, a customer route is preferable to a peer or a provider route. In this example, AS6 will likely prefer sending traffic via AS5 instead of its other peer or provider routes, causing AS5 to unintentionally become a transit provider. This can significantly affect the performance of the traffic related to the leaked prefix or cause outages if the leaking AS is not provisioned to handle a large influx of traffic.</p><p>In June 2015, Telekom Malaysia (<a href="https://radar.cloudflare.com/traffic/as4788">AS4788</a>), a regional ISP, <a href="https://www.bgpmon.net/massive-route-leak-cause-internet-slowdown/">leaked over 170,000 routes</a> learned from its providers and peers to its other provider Level3 (<a href="https://radar.cloudflare.com/traffic/as3549">AS3549</a>, now Lumen). Level3 accepted the routes and further propagated them to its downstream networks, which in turn caused significant network issues globally.</p>
    <div>
      <h3>Type 2: Lateral ISP-ISP-ISP Leak</h3>
      <a href="#type-2-lateral-isp-isp-isp-leak">
        
      </a>
    </div>
    <p>Type 2 leak is defined as propagating routes obtained from one peer to another peer, creating two or more consecutive peer-to-peer path segments.</p><p>Here is an example: AS3 → AS4 → AS5 forms a  type 2 leak.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/18VJCjED1cnQmJd0cXPnBU/f38d68dacc38637c0a9d72e5cdafa5ae/image1-70.png" />
            
            </figure><p>One example of such leaks is <a href="https://archive.nanog.org/meetings/nanog41/presentations/mauch-lightning.pdf">more than three very large networks appearing in sequence</a>. Very large networks (such as Verizon and Lumen) do not purchase transit from each other, and having <a href="https://puck.nether.net/bgp/leakinfo.cgi/">more than three such networks</a> on the path in sequence is often an indication of a route leak.</p><p>However, in the real world, it is not unusual to see multiple small peering networks exchanging routes and passing on to each other. Legit business reasons exist for having this type of network path. We are less concerned about this type of route leak as compared to type 1.</p>
    <div>
      <h3>Type 3 and 4: Provider routes to peer; peer routes to provider</h3>
      <a href="#type-3-and-4-provider-routes-to-peer-peer-routes-to-provider">
        
      </a>
    </div>
    <p>These two types involve propagating routes from a provider or a peer not to a customer, but to another peer or provider. Here are the illustrations of the two types of leaks:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6T2roi9v4ATputaICUVuUv/50831a0a631774e101e5f04abfb25876/image10-3.png" />
            
            </figure>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/18D2LnLHkNkbzLsORnD95y/1c033cd2c3cea76e556013bc777889a9/image13-1.png" />
            
            </figure><p>As in the <a href="/how-a-nigerian-isp-knocked-google-offline/">previously mentioned example</a>, a Nigerian ISP who peers with Google accidentally leaked its route to its provider <a href="https://radar.cloudflare.com/traffic/as4809">AS4809</a>, and thus generated a type 4 route leak. Because routes via customers are usually preferred to others, the large provider (AS4809) rerouted its traffic to Google via its customer, i.e. the leaking ASN, overwhelmed the small ISP and took down Google for over one hour.</p>
    <div>
      <h2>Route leak summary</h2>
      <a href="#route-leak-summary">
        
      </a>
    </div>
    <p>So far, we have looked at the four types of route leaks defined in <a href="https://www.rfc-editor.org/rfc/rfc7908.html">RFC7908</a>. The common thread of the four types of route leaks is that they're all defined using AS-relationships, i.e., peers, customers, and providers. We summarize the types of leaks by categorizing the AS path propagation based on where the routes are learned from and propagate to. The results are shown in the following table.</p><table>
<thead>
  <tr>
    <th>Routes from / propagates to</th>
    <th>To provider</th>
    <th>To peer</th>
    <th>To customer</th>
  </tr>
</thead>
<tbody>
  <tr>
    <td>From provider</td>
    <td>Type 1</td>
    <td>Type 3</td>
    <td>Normal</td>
  </tr>
  <tr>
    <td>From peer</td>
    <td>Type 4</td>
    <td>Type 2</td>
    <td>Normal</td>
  </tr>
  <tr>
    <td>From customer</td>
    <td>Normal</td>
    <td>Normal</td>
    <td>Normal</td>
  </tr>
</tbody>
</table><p>We can summarize the whole table into one single rule: <b>routes obtained from a non-customer AS can only be propagated to customers</b>.</p><p><i>Note: Type 5 and type 6 route leaks are defined as prefix re-origination and announcing of private prefixes. Type 5 is more closely related to</i> <a href="https://www.cloudflare.com/learning/security/glossary/bgp-hijacking/"><i>prefix hijackings</i></a><i>, which we plan to expand our system to as the next steps, while type 6 leaks are outside the scope of this work. Interested readers can refer to sections 3.5 and 3.6 of</i> <a href="https://www.rfc-editor.org/rfc/rfc7908.html"><i>RFC7908</i></a> <i>for more information.</i></p>
    <div>
      <h2>The Cloudflare Radar route leak system</h2>
      <a href="#the-cloudflare-radar-route-leak-system">
        
      </a>
    </div>
    <p>Now that we know what a  route leak is, let’s talk about how we designed our route leak detection system.</p><p>From a very high level, we compartmentalize our system into three different components:</p><ol><li><p><b>Raw data collection module</b>: responsible for gathering BGP data from multiple sources and providing BGP message stream to downstream consumers.</p></li><li><p><b>Leak detection module</b>: responsible for determining whether a given AS-level path is a route leak, estimate the confidence level of the assessment, aggregating and providing all external evidence needed for further analysis of the event.</p></li><li><p><b>Storage and notification module</b>: responsible for providing access to detected route leak events and sending out notifications to relevant parties. This could also include building a dashboard for easy access and search of the historical events and providing the user interface for high-level analysis of the event.</p></li></ol>
    <div>
      <h3>Data collection module</h3>
      <a href="#data-collection-module">
        
      </a>
    </div>
    <p>There are three types of data input we take into consideration:</p><ol><li><p>Historical: BGP archive files for some time range in the pasta. <a href="https://www.routeviews.org/routeviews/">RouteViews</a> and <a href="https://ris.ripe.net/docs/20_raw_data_mrt.html#name-and-location">RIPE RIS</a> BGP archives</p></li><li><p>Semi-real-time: BGP archive files as soon as they become available, with a 10-30 minute delay.a. RouteViews and RIPE RIS archives with data broker that checks new files periodically (e.g. <a href="https://bgpkit.com/broker">BGPKIT Broker</a>)</p></li><li><p>Real-time: true real-time data sourcesa. <a href="https://ris-live.ripe.net/">RIPE RIS Live</a>b. Cloudflare internal BGP sources</p></li></ol>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6p32es0tPhqsESHMazR8Ni/96910fef1be1cccf2bd69aa750b063c8/image6-11.png" />
            
            </figure><p>For the current version, we use the semi-real-time data source for the detection system, i.e., the BGP updates files from RouteViews and RIPE RIS. For data completeness, we process data from all public collectors from these two projects (a total of 63 collectors and over 2,400 collector peers) and implement a pipeline that’s capable of handling the BGP data processing as the data files become available.</p><p>For data files indexing and processing, we deployed an on-premises <a href="https://github.com/bgpkit/bgpkit-broker-backend">BGPKIT Broker instance</a> with Kafka feature enabled for message passing, and a custom concurrent <a href="https://www.rfc-editor.org/rfc/rfc6396.html">MRT</a> data processing pipeline based on <a href="https://github.com/bgpkit/bgpkit-parser">BGPKIT Parser</a> Rust SDK. The data collection module processes MRT files and converts results into a BGP messages stream at over two billion BGP messages per day (roughly 30,000 messages per second).</p>
    <div>
      <h3>Route leak detection</h3>
      <a href="#route-leak-detection">
        
      </a>
    </div>
    <p>The route leak detection module works at the level of individual BGP announcements. The detection component investigates one BGP message at a time, and estimates how likely a given BGP message is a result of a route leak event.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3uLtzc0IV8IAuxze3lYUXY/8eb3553e71a84930fe6851e8732f849f/image8-5.png" />
            
            </figure><p>We base our detection algorithm mainly on the <a href="https://ieeexplore.ieee.org/document/6363987">valley-free model</a>, which we believe can capture most of the notable route leak incidents. As mentioned previously, the key to having low false positives for detecting route leaks with the valley-free model is to have accurate AS-level relationships. While those relationship types are not publicized by every AS, there have been over two <a href="https://ieeexplore.ieee.org/document/6027863">decades of research</a> on the inference of the relationship types using publicly observed BGP data.</p><p>While state-of-the-art relationship inference algorithms have been shown to be <a href="https://dl.acm.org/doi/10.1145/2504730.2504735">highly accurate</a>, even a small margin of errors can still incur inaccuracies in the detection of route leaks. To alleviate such artifacts, we synthesize multiple data sources for inferring AS-level relationships, including <a href="https://www.caida.org/">CAIDA/UCSD</a>’s <a href="https://www.caida.org/catalog/datasets/as-relationships/">AS relationship</a> data and our in-house built AS relationship dataset. Building on top of the two AS-level relationships, we create a much more granular dataset at the per-prefix and per-peer levels. The improved dataset allows us to answer the question like what is the relationship between AS1 and AS2 with respect to prefix P observed by collector peer X. This eliminates much of the ambiguity for cases where networks have multiple different relationships based on prefixes and geo-locations, and thus helps us reduce the number of false positives in the system. Besides the AS-relationships datasets, we also apply the <a href="https://ihr.iijlab.net/ihr/en-us/documentation#AS_dependency">AS Hegemony dataset</a> from <a href="https://ihr.iijlab.net/ihr/en-us/">IHR IIJ</a> to further reduce false positives.</p>
    <div>
      <h3>Route leak storage and presentation</h3>
      <a href="#route-leak-storage-and-presentation">
        
      </a>
    </div>
    <p>After processing each BGP message, we store the generated route leak entries in a database for long-term storage and exploration. We also aggregate individual route leak BGP announcements and group relevant leaks from the same leak ASN within a short period together into <b>route-leak events</b>. The route leak events will then be available for consumption by different downstream applications like web UIs, an <a href="https://developers.cloudflare.com/api/operations/radar_get_BGPRouteLeakEvents">API</a>, or alerts.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7f4kKk1DFYPIltkyzArwDy/4347df7a5bee4ca6686455d6205324f7/image12-2.png" />
            
            </figure>
    <div>
      <h2>Route leaks on Cloudflare Radar</h2>
      <a href="#route-leaks-on-cloudflare-radar">
        
      </a>
    </div>
    <p>At Cloudflare, we aim to help build a better Internet, and that includes sharing our efforts on monitoring and securing Internet routing. Today, we are releasing our route leak detection system as public beta.</p><p>Starting today, users going to the Cloudflare Radar ASN pages will now find the list of route leaks that affect that AS. We consider that an AS is being affected when the leaker AS is one hop away from it in any direction, before or after.</p><p>The Cloudflare Radar ASN page is directly accessible via <a href="https://radar.cloudflare.com/as{ASN}"><b>https://radar.cloudflare.com/as{ASN}</b></a>. For example, one can navigate to <a href="https://radar.cloudflare.com/as174">https://radar.cloudflare.com/as174</a> to view the overview page for Cogent AS174. ASN pages now show a dedicated card for route leaks detected relevant to the current ASN within the selected time range.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/5CoRAfRuDBdZr5zQxCtoGn/1a89ba21ea72c44cbd45da3661705f65/image2-54.png" />
            
            </figure><p>Users can also start using our <a href="https://developers.cloudflare.com/api/operations/radar_get_BGPRouteLeakEvents">public data API</a> to lookup route leak events with regards to any given ASN.  Our API supports filtering route leak results by time ranges, and ASes involved. Here is a screenshot of the <a href="https://developers.cloudflare.com/api/operations/radar_get_BGPRouteLeakEvents">route leak events API documentation page</a> on the <a href="/building-a-better-developer-experience-through-api-documentation/">newly updated API docs site</a>.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/5IgJJ1GO4uHepxxQc5vwV7/9e809b7ef9264f9c03d70c70c27d4bb5/image3-44.png" />
            
            </figure>
    <div>
      <h2>More to come on routing security</h2>
      <a href="#more-to-come-on-routing-security">
        
      </a>
    </div>
    <p>There is a lot more we are planning to do with route-leak detection. More features like a global view page, route leak notifications, more advanced APIs, custom automations scripts, and historical archive datasets will begin to ship on Cloudflare Radar over time. Your feedback and suggestions are also very important for us to continue improving on our detection results and serve better data to the public.</p><p>Furthermore, we will continue to expand our work on other important topics of Internet routing security, including global BGP hijack detection (not limited to our customer networks), RPKI validation monitoring, open-sourcing tools and architecture designs, and centralized routing security web gateway. Our goal is to provide the best data and tools for routing security to the communities so that we can build a better and more secure Internet together.</p><p>In the meantime, we opened a <a href="https://discord.com/channels/595317990191398933/1035553707116478495">Radar room</a> on our Developers Discord Server. Feel free to <a href="https://discord.com/channels/595317990191398933/1035553707116478495">join</a> and talk to us; the team is eager to receive feedback and answer questions.</p><p>Visit <a href="https://radar.cloudflare.com/">Cloudflare Radar</a> for more Internet insights. You can also follow us <a href="https://twitter.com/cloudflareradar">on Twitter</a> for more Radar updates.</p> ]]></content:encoded>
            <category><![CDATA[Radar]]></category>
            <category><![CDATA[BGP]]></category>
            <category><![CDATA[Routing Security]]></category>
            <guid isPermaLink="false">72oaP8g7ZckKtIVQxA8EX4</guid>
            <dc:creator>Mingwei Zhang</dc:creator>
            <dc:creator>Vasilis Giotsas</dc:creator>
            <dc:creator>Celso Martinho</dc:creator>
        </item>
        <item>
            <title><![CDATA[“Look, Ma, no probes!” — Characterizing CDNs’ latencies with passive measurement]]></title>
            <link>https://blog.cloudflare.com/cdn-latency-passive-measurement/</link>
            <pubDate>Fri, 15 Oct 2021 13:02:06 GMT</pubDate>
            <description><![CDATA[ In this article we describe an alternative approach to active measurements, which accurately predicts network latencies using only passively collected data. ]]></description>
            <content:encoded><![CDATA[ <p></p><p>Something that comes up a lot at Cloudflare is how well our network and systems are performing. Like many service providers, we need to be engaged in a constant process of introspection to evaluate aspects of Cloudflare’s service with respect to customers, within our own network and systems and, as was the case in a recent <a href="/last-mile-insights/">blog post</a>, the clients (such as web browsers). Many of these questions are obvious, but answering them is decisive in opening paths to new and improved services. The important point here is that it’s relatively straightforward to monitor and assess aspects of our service we can see or measure directly.</p><p>However, for certain aspects of our performance we may not have access to the necessary data, for a number of reasons. For instance, the data sources may be outside our <a href="https://www.cloudflare.com/learning/access-management/what-is-the-network-perimeter/">network perimeter</a>, or we may avoid collecting certain measurements that would violate the privacy of end users. In particular, the questions below are important to gain a better understanding of our performance, but harder to answer due to limitations in data availability:</p><ul><li><p>How much better (or worse!) are we doing compared to other service providers (<a href="https://www.cloudflare.com/learning/cdn/what-is-a-cdn/">CDNs</a>) by being in certain locations?</p></li><li><p>Can we know “a priori” and rank where data centers will have the greatest improvement and know which locations might deteriorate service?</p></li></ul><p>The last question is particularly important because it requires the predictive power of synthesising available network measurements to model and <i>infer</i> network features that cannot be directly observed. For such predictions to be informative and meaningful, it’s critical to distill our measurements in a way that illuminates the interdependence of network structure, content distribution practices and routing policies, and their impact on network performance.</p>
    <div>
      <h2>Active measurements are inadequate or unavailable</h2>
      <a href="#active-measurements-are-inadequate-or-unavailable">
        
      </a>
    </div>
    <p>Measuring and comparing the performance of Content Distribution Networks (CDN) is critical in terms of understanding the level of service offered to end users, detecting and <a href="https://www.cloudflare.com/learning/cdn/common-cdn-issues/">debugging</a> network issues, and planning the deployment of new network locations. Measuring our own existing infrastructure is relatively straightforward, for example, by collecting <a href="https://www.cloudflare.com/learning/dns/what-is-dns/">DNS</a> and HTTP request statistics received at each one of our data centers.</p><p>But what if we want to understand and evaluate the performance of other networks? Understandably, such data is not shared among networks due to privacy and business concerns. An alternative to data sharing is <i>direct</i> observation with what are called “active measurements.” An example of active measurement is when a measuring tape is used to determine the size of a room — one must take an action to perform the measurement.</p><p>Active measurements from Cloudflare data centers to other CDNs, however, don’t say much about the client experience. The only way to actively measure CDNs is by probing from third-party points of view, namely some type of end-client or globally distributed measurement platform. For example, ping probes might be launched from <a href="https://atlas.ripe.net/">RIPE Atlas clients</a> to many CDNs; alternatively, we might rely on data obtained from <a href="https://en.wikipedia.org/wiki/Real_user_monitoring">Real User Measurements (RUM)</a> services that embed JavaScript requests into various services and pages around the world.</p><p>Active measurements are extremely valuable, and we heavily rely on them to collect a wide range of performance metrics. However, active measurements are not always reliable. Consider ping probes from RIPE Atlas. A collection of direct pings is most assuredly accurate. The weakness is that the distribution of its probes is heavily concentrated in Europe and North America, and it offers very sparse coverage of Autonomous Systems (ASes) in other regions (Asia, Africa, South America). Additionally, the distribution of RIPE Atlas probes to ASes does not reflect the distribution of users to ASes, instead university networks and hosting providers or enterprises are overrepresented in the probes' population.</p><p>Similarly, data from third party Real User Measurements (RUM) services have weaknesses too. RUM platforms compare CDNs by embedding JavaScript request probes in websites visited by users all over the world. This sounds great, except the data cannot be validated by outside parties, which is an important aspect of measurement. For example, consider the following chart that shows Cloudfront’s median <a href="https://www.cloudflare.com/learning/cdn/glossary/round-trip-time-rtt/">Round-Trip Time (RTT)</a> in Greece as measured by the two leading RUM platforms, <a href="https://www.cedexis.com/">Cedexis</a> and <a href="https://perfops.net/">Perfops</a>. While both platforms follow the same measurement method, their results for the same time period and the same networks differ considerably. If the two sets of measurements for the same thing differ, then neither can be relied upon.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/nP0ZN4fYPeYJG8XwvFKvb/680b0d37a7568b803169e8f3cd9b0584/2-14.png" />
            
            </figure><p>Comparison of Real User Measurements (RUM) from two leading RUM providers, Cedexis and Perfops. While both RUM datasets were collected during the same period for the same location, there is a pronounced disparity between the two measurements which highlights the sensitivity of RUM data on specific deployment details.</p><p>Ultimately, active measurements are always limited to and by the things that they directly see. Simply relying on existing measurements does not in and of itself translate to predictive models that help assess the potential impact of infrastructure and policy changes on performance. However, when the biases of active measurements are well understood, they can do two things really well: inform our understanding, and help validate models of our understanding of the world — and we’re going to showcase both as we develop a mechanism for evaluating CDN latencies passively.</p>
    <div>
      <h2>Predicting CDNs’ RTTs with Passive Network Measurements</h2>
      <a href="#predicting-cdns-rtts-with-passive-network-measurements">
        
      </a>
    </div>
    <p>So, how might we measure without active probes? We’ve devised a method to understand latency across CDNs by using our own RTT measurements. In particular, we can use these measurements as a proxy for estimating the latency between clients and other CDNs. With this technique, we can understand latency to locations where CDNs have deployed their infrastructure, as well as show performance improvements in locations where one CDN exists, but others do not. Importantly, we have validated the assumptions shown below through a large-scale traceroute and ping measurement campaign, and we’ve designed this technique so that it can be reproduced by others. After all, independent validation is important across measurement communities.</p>
    <div>
      <h3>Step 1. Predicting Anycast Catchments</h3>
      <a href="#step-1-predicting-anycast-catchments">
        
      </a>
    </div>
    <p>The first step in RTT inference is to predict the anycast catchments, namely predict the set of data centers that will be used by an IP. To this end, we compile the network footprint of each CDN provider whose performance we want to predict, which allows us to predict the CDN location where a request from a particular client AS will arrive. In particular, we collect the following data:</p><ul><li><p>List of ISPs that host off-net server caches of CDNs using the methodology and code developed in <a href="https://dl.acm.org/doi/10.1145/3452296.3472928">Gigis et al. paper</a>.</p></li><li><p>List of on-net city-level data centers according to <a href="https://www.peeringdb.com/">PeeringDB</a>, the network maps in the websites of each individual CDN, and IP geolocation measurements.</p></li><li><p>List of Internet eXchange Points (IXPs) where each CDN is connected, in conjunction with the other ASes that are also members of the same IXPs, from IXP databases such as <a href="https://www.peeringdb.com/">PeeringDB</a>, the <a href="https://ixpdb.euro-ix.net/">Euro-IX IXP-DB</a>, and <a href="https://www.pch.net/">Packet Clearing House</a>.</p></li><li><p>List of CDN interconnections to other ASes extracted from BGP data collected from <a href="http://www.routeviews.org/">RouteViews</a> and <a href="https://www.ripe.net/analyse/internet-measurements/routing-information-service-ris">RIPE RIS</a>.</p></li></ul><p>The figure below shows the IXP connections for nine CDNs, according to the above-mentioned datasets. Cloudflare is present in 258 IXPs, which is 56 IXPs more than Google, the second CDN in the list.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4tpNEGB2VefICSiApc6Lm5/21ab3ee5dfd9b520078021344fe15304/4-6.png" />
            
            </figure><p>Heatmap of IXP connections per country for 9 major service providers, according to data from PeeringDB, Euro-IX and Packet Clearing House (PCH) for October 2021.</p><p>With the above data, we can compute the possible paths between a client AS and the CDN’s data centers and infer the Anycast Catchments using techniques similar to the recent papers by <a href="https://dl.acm.org/doi/10.1145/3452296.3472935">Zhang et al.</a> and <a href="https://dl.acm.org/doi/10.1145/3341617.3326145">Sermpezis and Kotronis</a>, which predict paths by reproducing the Internet inter-domain routing policies. For CDNs that use BGP-based Anycast, we can predict which data center will receive a request based on the possible routing paths between the client and the CDN.  For CDNs that rely on DNS-based redirection, we don’t make an inference yet, but we first predict the latency to each data center, and we select the path with the lowest latency assuming that CDN operators manage to offer the path with the smallest latency.</p><p>The challenge in predicting paths emanates from the incomplete knowledge of the varying routing policies implemented by individual ASes, which are either hosting web clients (for instance an ISP or an <a href="https://www.cloudflare.com/learning/network-layer/enterprise-networking/">enterprise network</a>), or are along the path between the CDN and the client’s network. However, in our prediction problem, we can already partition the IP address space to Anycast Catchment regions (as proposed by <a href="https://dl.acm.org/doi/10.1145/3431832.3431834">Schomp and Al-Dalky</a>) based on our extensive data center footprint, which allows us to reverse engineer the routing decisions of client ASes that are visible to Cloudflare. That’s a lot to unpack, so let’s go through an example.</p>
    <div>
      <h4>Example</h4>
      <a href="#example">
        
      </a>
    </div>
    <p>First, assume that an ISP has two potential paths to a CDN: one over a transit provider and one through a direct peering connection over an IXP, and each path terminates at a different data center, as shown in the figure below. In the example below, routing through a transit AS incurs a cost, while IXP peering links do not incur transit exchange costs. Therefore, we would predict that the client ISP would use the path to data center 2 through the IXP.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/p3RWX3R79ZtqBSiNWZDJr/6a626e30dfc0dec4e27c26cce8684740/5-4.png" />
            
            </figure><p>A client ISP may have paths to multiple data centers of a CDN. The prediction of which data center will eventually be used by the client, the so-called anycast catchment, combines both topological and routing policy data.</p>
    <div>
      <h2>Step 2. Predicting CDN Path Latencies</h2>
      <a href="#step-2-predicting-cdn-path-latencies">
        
      </a>
    </div>
    <p>The next step is to estimate the RTT between the client AS and the corresponding CDN location. To this end, we utilize passive RTT measurements from Cloudflare’s own infrastructure. For each of our data centers, we calculate the median TCP RTT for each IP /24 subnet that sends us HTTP requests. We then assume that a request from a given IP subnet to a data center that is common between Cloudflare and another CDN will have a comparable RTT (our approach focuses on the performance of the anycast network and omits host software differences). This assumption is generally true, because the distance between two endpoints is the dominant factor in determining latency. Note that the median RTT is selected to represent client performance. In contrast, the minimum RTT is an indication of closeness to clients (not expected performance). Our approach on estimating latencies is similar to the work of <a href="https://dl.acm.org/doi/10.1145/1177080.1177092">Madhyastha et al.</a> who combined the median RTT of existing measurements with a path prediction technique informed by network topologies to infer end-to-end latencies that cannot be measured directly. While this work reported an accuracy of 65% for arbitrary ASes, we focus on CDNs which, on average, have much smaller paths (most clients are within 1 AS hop) making the path prediction problem significantly easier (as noted by <a href="https://dl.acm.org/doi/10.1145/2815675.2815719">Chiu et al.</a> and <a href="https://dl.acm.org/doi/abs/10.1145/2934872.2959053">Singh and Gill</a>). Also note that for the purposes of RTT estimation, it’s important to predict which CDN data center the request from a client IP will use, not the actual hops along the path.</p>
    <div>
      <h4>Example</h4>
      <a href="#example">
        
      </a>
    </div>
    <p>Assume that for a certain IP subnet used by AS3379 (a Greek ISP), the following table shows the median RTT for each Cloudflare data center that receives HTTP requests from that subnet. Note that while requests from an IP typically land at the nearest data center (Athens in that case), some requests may arrive at different data centers due to traffic load management and different <a href="https://www.cloudflare.com/plans/">service tiers</a>.</p><table><tr><td><p><b>Data Center</b></p></td><td><p><b>Athens</b></p></td><td><p><b>Sofia</b></p></td><td><p><b>Milan</b></p></td><td><p><b>Frankfurt</b></p></td><td><p><b>Amsterdam</b></p></td></tr><tr><td><p><b>Median RTT</b></p></td><td><p>22 ms</p></td><td><p>42 ms</p></td><td><p>43 ms</p></td><td><p>70 ms</p></td><td><p>75 ms</p></td></tr></table><p>Assume that another CDN B does not have data centers or cache servers in Athens and Sofia, but only in Milan, Frankfurt, and Amsterdam. Based on the topology and colocation data of CDN B, we will predict the anycast catchments, and we find that for AS3379 the data center in Frankfurt will be used. In that case, we will use the corresponding latency as an estimate of the median latency between CDN B and the given prefix.</p><p>The above methodology works well because Cloudflare’s global network allows us to collect network measurements between 63,832 ASes (virtually every AS which hosts clients), and 300 cities in 115 different countries where Cloudflare infrastructure is deployed, allowing us to cover the vast majority of regions where other CDNs have deployed infrastructure.</p>
    <div>
      <h2>Step 3. Validation</h2>
      <a href="#step-3-validation">
        
      </a>
    </div>
    <p>To validate the above measurement, we run a global campaign of traceroute and ping measurements from 9,990 Atlas probes in 161 different countries (see the <a href="https://atlas.ripe.net/results/maps/network-coverage/">interactive map</a> for real-time data on the geographical distribution of probes).</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/2jnCkRq97yrEyP7vKSBxwO/1e547add88b468e4aa4063592919cd74/6-2.png" />
            
            </figure><p>Geographical distribution of the RIPE Atlas probes used for the validation of our predictions</p><p>For each CDN as a measurement target, we selected a destination hostname that is anycasted from all locations, and we selected the DNS resolution to run on each measurement probe so that the returned IP corresponds to the probe’s nearest location.</p><p>After the measurements were completed, we first evaluated the Anycast Catchment prediction, namely the prediction of which CDN data center will be used by each RIPE Atlas probe. To this end, we geolocated the destination IPs of each completed traceroute measurement against the predicted data center. <b>Nearly 90% of our predicted data centers agreed with the measured data centers.</b></p><p>We also validated our RTT predictions. The figure below shows the absolute difference between the measured RTT and the predicted RTT in milliseconds, across all data centers. More than 50% of the predictions have an RTT difference of 3 ms or less, while almost 95% of the predictions have an RTT difference of at most 10 ms.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4xXmpUGVi1i36sQ7ZGaIdE/28181ad1e302fd49d43bced21d36492e/7-1.png" />
            
            </figure><p>Histogram of the absolute difference in milliseconds between the predicted RTT and the RTT measured through the RIPE Atlas measurement campaign.</p>
    <div>
      <h2>Results</h2>
      <a href="#results">
        
      </a>
    </div>
    <p>We applied our methodology on nine major CDNs, including Cloudflare, in September 2021. As shown in the boxplot below, Cloudflare exhibits the lowest median RTT across all observed clients, with a median RTT close to 10 ms.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3OsQkNEDKMD6Zgkw6ioRQi/ed28acf0524ec0338216e521c1f9f551/8-1.png" />
            
            </figure><p>Boxplot of the global RTT distributions for each of the 9 networks we considered in our experiments. We anonymize the rest of the networks since the focus on this measurement is not to provide a ranking of content providers but to contextualize the performance of Cloudflare’s network compared to other comparable networks. </p>
    <div>
      <h2>Limitations of measurement methodology</h2>
      <a href="#limitations-of-measurement-methodology">
        
      </a>
    </div>
    <p>Because our approach relies on estimating latency, it is not possible to obtain millisecond-accurate measurements. However, such measurements are essentially infeasible even when using real user measurements because the network conditions are highly dynamic, meaning that measured RTT may differ significantly between different measurements.</p><p>Secondly, our approach obviously cannot be used to monitor network hygiene in real time and detect <a href="https://www.cloudflare.com/learning/cdn/common-cdn-issues/">performance issues</a> that may often lie outside Cloudflare’s network. Instead, our approach is useful for understanding the expected performance of our network topology and connectivity, and we can test what-if scenarios to predict the impact on performance that different events may have (e.g. deployment of a new data center, interruption of connectivity to an ISP or IXP).</p><p>Finally, while Cloudflare has the most extensive coverage of data centers and IXPs compared to other CDNs, there are certain countries where Cloudflare does not have a data center in contrast to other CDNs. In some other countries, Cloudflare is present to a partner data center but not in a carrier-neutral data center which may restrict the number of direct peering links between Cloudflare’s and other regional ISPs. In such countries, client IPs may be routed to a data center outside the country because the BGP decision process typically prioritizes cost over proximity. Therefore, for about 7% of the client /24 IP prefixes, we do not have a measured RTT between a data center in the same country as the IP. We are working to alleviate this with traceroute measurements and will report back later.</p>
    <div>
      <h2>Looking Ahead</h2>
      <a href="#looking-ahead">
        
      </a>
    </div>
    <p>The ability to predict and compare the performance of different CDN networks allows us to evaluate the impact of different peering and data center strategies, as well as identify shortcomings in our Anycast Catchments and traffic engineering policies. Our ongoing work focuses on measuring and quantifying the impact of peering on IXPs on end-to-end latencies, as well as identifying cases of local Internet ecosystems where an open peering policy may lead to latency increases. This work will eventually enable us to optimize our infrastructure placement and control-plane policies to the specific topological properties of different regions and minimize latency for end users.</p> ]]></content:encoded>
            <category><![CDATA[Research]]></category>
            <category><![CDATA[Speed & Reliability]]></category>
            <guid isPermaLink="false">6hm0oQNiiTzdYUnrCxrRK1</guid>
            <dc:creator>Vasilis Giotsas</dc:creator>
            <dc:creator>Marwan Fayed</dc:creator>
        </item>
        <item>
            <title><![CDATA[Unboxing the Last Mile: Introducing Last Mile Insights]]></title>
            <link>https://blog.cloudflare.com/last-mile-insights/</link>
            <pubDate>Thu, 16 Sep 2021 12:59:45 GMT</pubDate>
            <description><![CDATA[ “The last 20% of the work requires 80% of the effort.” The Pareto Principle applies in many domains — nowhere more so on the Internet, however, than on the Last Mile. ]]></description>
            <content:encoded><![CDATA[ 
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6wlfF9aZn7cQx8iwKKyUml/940d86cf8ce2c800acc1331005caeab5/Last-mile.png" />
            
            </figure><p>“The last 20% of the work requires 80% of the effort.” The Pareto Principle applies in many domains — nowhere more so on the Internet, however, than on the Last Mile. Last Mile networks are heterogeneous and independent of each other, but all of them need to be running to allow for everyone to use the Internet. They’re typically the responsibility of Internet Service Providers (ISPs). However, if you’re an organization running a mission-critical service on the Internet, not paying attention to Last Mile networks is in effect handing off responsibility for the uptime and performance of your service over to those ISPs.</p><p>Probably not the best idea.</p><p>When a customer puts a service on Cloudflare, part of our job is to offer a good experience across the whole Internet. We couldn’t do that without focusing on Last Mile networks. In particular, we’re focused on two things:</p><ul><li><p>Cloudflare needs to have strong connectivity to Last Mile ISPs and needs to be as close as possible to every Internet-connected person on the planet.</p></li><li><p>Cloudflare needs good observability tools to know when something goes wrong, and needs to be able to surface that data to you so that you can be informed.</p></li></ul><p>Today, we’re excited to announce Last Mile Insights, to help with this last problem in particular. Last Mile Insights allows customers to see where their end-users are having trouble connecting to their Cloudflare properties. Cloudflare can now show customers the traffic that failed to connect to Cloudflare, where it failed to connect, and why. If you’re an enterprise Cloudflare customer, you can sign up to join the beta in the Cloudflare Dashboard starting today: in the Analytics tab under Edge Reachability.</p><p>The Last Mile is historically the most complicated, least understood, and in some ways the most important part of operating a reliable network. We’re here to make it easier.</p>
    <div>
      <h3>What is the Last Mile?</h3>
      <a href="#what-is-the-last-mile">
        
      </a>
    </div>
    <p>The Last Mile is the connection between your home and your ISP. When we talk about how users connect to content on the Internet, we typically do it like this:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/7DwcjkdeiL32Iu98kc9q9y/b3e0cf94b995f4b069b4ffd14d7c26dc/image6-4.png" />
            
            </figure><p>This is useful, but in reality, there are lots of things in the path between a user and anything on the Internet. Say that a user is connecting to a resource hosted behind Cloudflare. The path would look like this:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/6DsNzK5aYOsmVppSscumET/226d7ec1a09ef2bf609676d0e51db6bd/image3-17.png" />
            
            </figure><p>Cloudflare is a global Anycast network that takes traffic from the Internet and proxies it to your origin. Because we function as a proxy, we think of the life of a request in two legs: before it reaches Cloudflare (end users to Cloudflare), and after it reaches Cloudflare (Cloudflare to origin). However, in Internet parlance, there are generally three legs: the First Mile tends to represent the path from an origin server to the data that you are requesting. The Middle Mile represents the path from an origin server to any proxies or other network hops. And finally, there is the final hop from the ISP to the user, which is known as the Last Mile.</p><p>Issues with the Last Mile are difficult to detect. If users are unable to reach something on the Internet, it is difficult for the resource to report that there was a problem. This is because if a user never reaches the resource, then the resource will never know something is wrong. Multiply that one problem across hundreds of thousands of Last Mile ISPs coming from a diverse set of regions, and it can be really hard for services to keep track of all the possible things that can go wrong on the Internet. The above graphic actually doesn’t really reflect the scope of the problem, so let’s revise it a bit more:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/282Htt2lur4oMmIRxazr48/492affdf559d4f246eef635a2e37ed2a/image1-14.png" />
            
            </figure><p>It’s not an easy problem to keep on top of.</p>
    <div>
      <h3>Brand New Last Mile Insights</h3>
      <a href="#brand-new-last-mile-insights">
        
      </a>
    </div>
    <p>Cloudflare is launching a closed beta of a brand new Last Mile reporting tool, Last Mile Insights. Last Mile Insights allows for customers to see where their end-users are having trouble connecting to their Cloudflare properties. Cloudflare can now show customers the traffic that failed to connect to Cloudflare, where it failed to connect, and why.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/2xpSHY4nDn6GbysOq3obLv/c43b04dc6f312b9c143a6d2245492b13/image8.png" />
            
            </figure><p>Access to this data is useful to our customers because when things break, knowing what is broken and why — and then communicating with your end users — is vital. During issues, users and employees may create support/helpdesk tickets and social media posts to understand what’s going on. Knowing what is going on, and then communicating effectively about what the problem is and where it’s happening, can give end users confidence that issues are identified and being investigated… even if the issues are occurring on a third party network. Beyond that, understanding the root of the problem can help with mitigations and speed time to resolution.</p>
    <div>
      <h3>How do Last Mile Insights work?</h3>
      <a href="#how-do-last-mile-insights-work">
        
      </a>
    </div>
    <p>Our Last Mile monitoring tools use a combination of signals and <a href="https://www.cloudflare.com/learning/ai/what-is-machine-learning/">machine learning</a> to detect errors and performance regressions on the Last Mile.</p><p>Among the signals: <a href="https://www.w3.org/TR/network-error-logging/">Network Error Logging</a> (NEL) is a browser-based reporting system that allows users’ browsers to report connection failures to an endpoint specified by the webpage that failed to load. When a user is able to connect to Cloudflare on a site with NEL enabled, Cloudflare will pass back two headers that indicate to the browser that they should report any network failures to an endpoint specified in the headers. The browser will then operate as usual, and if something happens that prevents the browser from being able to connect to the site, it will log the failure as a report and send it to the endpoint. This all happens in real time; the endpoint receives failure reports instantly after the browser experiences them.</p><p>The browser can send failure reports for many reasons: it could send reports because the TLS certificate was incorrect, the ISP or an upstream transit was having issues on the request path, the terminating server was overloaded and dropping requests, or a data center was unreachable. The W3C specification outlines specific buckets that the browser should break reports into and uploads those as reasons the browser could not connect. So the browser is literally telling the reporting endpoint why it was unable to reach the desired site. Here’s an example of a sample report a browser gives to Cloudflare’s endpoint:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/75PZvAhZZCgzwKlrvlLPmX/6f82016253527d4b132694fd30c394b6/image7.png" />
            
            </figure><p>The report itself is a JSON blob that contains a lot of things, but the things we care about are when in the request the failure occurred (phase), why the request failed (tcp.timed_out), the ASN the request came over, and the metro area where the request came from. This information allows anyone looking at the reports to see where things are failing and why. Personal Identifiable Information is not captured in NEL reports. For more information, please see our <a href="https://support.cloudflare.com/hc/en-us/articles/360050691831-Understanding-Network-Error-Logging">KB article on NEL</a>.</p><p>Many services can operate their own reporting endpoints and set their own headers indicating that users who connect to their site should upload these reports to the endpoint they specify. Cloudflare is also an operator of one such endpoint, and we’re excited to open up the data collected by us for customer use and visibility.  Let’s talk about a customer who used Last Mile Insights to help make a bad day on the Internet a little better.</p>
    <div>
      <h3>Case Study: Canva</h3>
      <a href="#case-study-canva">
        
      </a>
    </div>
    <p>Canva is a Cloudflare customer that provides a design and collaboration platform hosted in the cloud. With more than 60 million users around the world, having constant access to Canva’s platform is critical. Last year, Canva users connecting through Cox Communications in San Diego started to experience connectivity difficulties. Around 50% of Canva’s users connecting via Cox Communications saw disconnects during that time period, and these users weren’t able to access Canva or Cloudflare at all. This wasn’t a Canva or Cloudflare outage, but rather, was caused by Cox routing traffic destined for Canva incorrectly, and causing errors for mutual Cox/Canva customers as a result.</p><p>Normally, this scenario would have taken hours to diagnose and even longer to mitigate. Canva would’ve seen a slight drop in traffic, but as the outage wasn’t on Canva’s side, it wouldn’t have flagged any alerts based on traffic drops. Canva engineers, in this case, would be notified by the users which would then be followed by a lengthy investigation to diagnose the problem.</p><p>Fortunately, Cloudflare has invested in monitoring systems to proactively identify issues exactly like these. Within minutes of the routing anomaly being introduced on Cox’s network, Canva was made aware of the issue via our monitoring, and a conversation with Cox was started to remediate the issue. Meanwhile, Canva could advise their users on the steps to fix it.</p><p>Cloudflare is excited to be offering our internal <a href="https://www.cloudflare.com/application-services/solutions/app-performance-monitoring/">monitoring solution</a> to our customers so that they can see what we see.</p><p>But providing insights into seeing where problems happen on the Last Mile is only part of the solution. In order to truly deliver a reliable, fast network, we also need to be as close to end users as possible.</p>
    <div>
      <h3>Getting close to users</h3>
      <a href="#getting-close-to-users">
        
      </a>
    </div>
    <p>Getting close to end users is important for one reason: it minimizes the time spent on the Last Mile. These networks can be unreliable and slow. The best way to improve performance is to spend as little time on them as possible. And the only way to do that is to get close to our users. In order to get close to our users, Cloudflare is constantly expanding our presence into new cities and markets. We’ve <a href="/250-cities-is-just-the-start/">just announced expansion into new markets</a> and are adding even more new markets all the time to get as close to every network and every user as we can.</p><p>This is because not every network is the same. Some users may be clustered very close together in cities with high bandwidth, in others, this may not be the case. Because user populations are not homogeneous, each ISP operates their network differently to meet the needs of their users. Physical distance from where servers are matters a great deal, because nobody can outrun the speed of light. If you’re farther away from the content you want, it will take longer to reach it. But distance is not the only variable; bandwidth and speed will also vary, because networks are operated differently all over the world. But one thing we do know is that your network performance will also be impacted by how healthy your Last Mile network is.</p>
    <div>
      <h3>Healthier networks perform better</h3>
      <a href="#healthier-networks-perform-better">
        
      </a>
    </div>
    <p>A healthy network has no downtime, minimal congestion, and low packet loss.  These things all add latency. If you’re driving somewhere, street closures, traffic, and bad roads will prevent you from going as fast as possible to where you need to be. Healthy networks provide the best possible conditions for you to connect, and Last Mile performance is better because of it.  Consider three networks in the same country: ISP A, ISP B, and ISP C. These ISPs have similar distribution among their users. ISP A is healthy and is directly connected with Cloudflare. ISP B is healthy but is not directly connected to Cloudflare.  ISP C is an unhealthy network. Our data shows that Last Mile latencies for ISP C are significantly slower than Network A or B because the network quality of ISP C is worse.</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4e2Y5J2efSredpNcRrGRNj/079b2800d47f8ff0dfb8e4ade52796fe/image4-12.png" />
            
            </figure><p>This box plot shows that the latencies to Cloudflare for ISP C are 360% higher than ISPs A or B.</p><p>We want all networks to be like Network A, but that’s not always the case, and it’s something Cloudflare can’t control. The only thing Cloudflare can do to mitigate performance problems like these is to limit how much time you spend on these networks.</p>
    <div>
      <h3>Shrinking the Last Mile gives better performance</h3>
      <a href="#shrinking-the-last-mile-gives-better-performance">
        
      </a>
    </div>
    <p>By placing data centers close to our users, we reduce the amount of time spent on these Last Mile networks, and the latency between end users and Cloudflare goes down. A great example of this is how bringing up new locations in Africa affected the latency for the Internet-connected population there.  Blue shows the latency before these locations were added, and red shows after:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/4CoocVadwANp3T12FRacP6/40ab018d81c0a33172904cfb2e85bc6c/image5-10.png" />
            
            </figure><p>Our efforts globally have brought 95% of the Internet-connected population within 50ms of us:</p>
            <figure>
            
            <img src="https://cf-assets.www.cloudflare.com/zkvhlag99gkb/3Cdk1q51Xvzi7Vys8Rm0MU/c788ae4dde2307ffab24b61c3d7c9ab9/image2-19.png" />
            
            </figure><p>You will also notice that 80% of the Internet is within 30ms of us. The tail for Last Mile latencies is very long, and every data center we add helps bring that tail closer to great performance. As we expand into more locations and countries, more of the Internet will be even better connected.</p><p>But even when the Last Mile is shrunken down by our infrastructure expansions, networks can still have issues that are difficult to detect. Existing logging and monitoring solutions don’t provide a good way to see what the problem is. Cloudflare has built a sophisticated set of tools to identify issues with Last Mile networks outside our control, and help reduce time to resolution for this purpose, and it has already found problems on the Last Mile for our customers.</p>
    <div>
      <h3>Cloudflare has unique performance and insight into Last Mile networking</h3>
      <a href="#cloudflare-has-unique-performance-and-insight-into-last-mile-networking">
        
      </a>
    </div>
    <p>Running an application on the Internet requires customers to look at the whole Internet. Many cloud services optimize latency starting at the first mile and work their way out, because it’s easier to optimize for things they can control. Because the Last Mile is controlled by hundreds or thousands of ISPs, it is difficult to influence how the Last Mile behaves.</p><p>Cloudflare is focused on closing performance gaps everywhere, including close to your users and employees. Last mile performance and reliability is critically important to delivering content, keeping employees productive, and all the other things the world depends on the Internet to do. If a Last Mile provider is having a problem, then users connecting to the Internet through them will have a bad day.</p><p>Cloudflare’s efforts to provide better Last Mile performance and visibility allow customers to rely on Cloudflare to optimize the Last Mile, making it one less thing they have to think about. Through Last Mile Insights and network expansion efforts — available today in the Cloudflare Dashboard,  in the Analytics tab under Edge Reachability — we want to provide you the ability to see what’s really happening on the Internet while knowing that Cloudflare is working on giving your users the best possible Internet experience.</p>
    <div>
      <h3>Watch on Cloudflare TV</h3>
      <a href="#watch-on-cloudflare-tv">
        
      </a>
    </div>
    <div></div> ]]></content:encoded>
            <category><![CDATA[Speed Week]]></category>
            <category><![CDATA[Speed & Reliability]]></category>
            <category><![CDATA[Product News]]></category>
            <guid isPermaLink="false">2TnrvKgwz0lKy8qrfP96G0</guid>
            <dc:creator>David Tuber</dc:creator>
            <dc:creator>Vasilis Giotsas</dc:creator>
        </item>
    </channel>
</rss>