Skip to content

Commit

Permalink
Add maxmind server ip addresses
Browse files Browse the repository at this point in the history
  • Loading branch information
kevcenteno committed May 29, 2024
1 parent 53892ec commit f9356f0
Show file tree
Hide file tree
Showing 11 changed files with 170 additions and 33 deletions.
21 changes: 21 additions & 0 deletions assets/scss/_alert.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
.alert {
--mm-color-primary-text: #444;
--mm-spacing: 20px;
background: linear-gradient(#fff, var(--mm-color-sidebar));
border-bottom: 1px solid #eee;
border-left: 1px solid #eee;
border-color: #f5f5f5 #eee #ddd #7eadda;
border-radius: 0 var(--mm-border-radius) var(--mm-border-radius) 0;
border-top: 1px solid #eee;
border-style: solid;
border-width: 1px 1px 1px 6px;
box-shadow: 0 1px 3px #0000001a;
color: var(--mm-color-primary-text);
margin: var(--mm-spacing) 0;
padding: calc(var(--mm-spacing) / 2) var(--mm-spacing);
position: relative;
}

.alert--warning {
border-left-color: #e89f29;
}
17 changes: 17 additions & 0 deletions assets/scss/_mm-ips.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
.mm-ips {
background-color: var(--mm-color-background-code);
border-radius: var(--mm-border-radius);
padding: 1rem;

span {
color: #ddd;
display: block;
font-family: monospace;
font-size: 0.9rem;
}
}

.mm-ips__last-updated {
font-style: italic;
margin-top: 0.5rem;
}
2 changes: 2 additions & 0 deletions assets/scss/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
@import 'product-featured';
@import 'fourohfour';
@import 'codeset';
@import 'mm-ips';
@import 'alert';

*:focus {
outline-color: var(--mm-color-logo-blue-light);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
---
draft: false
layout: mm-ips
title: MaxMind Server IP Addresses
outputs:
- rss
- html
_comment: json feed is handled by module mounts. see hugo.toml
---

import { FaRss as RssFeed } from 'react-icons/fa';
import { RiBracesFill as JsonFeed } from 'react-icons/ri';

<Alert type="warning">

{{< warning >}}
In January 2024, we began using R2 presigned URLs for all database downloads.
Database downloads will no longer use the IP addresses specified below.

For information about IP addresses used to serve database downloads see
[the appropriate section below](#database-download-ip-addresses).

[Read our release note for more information.](/geoip/release-notes/2024#presigned-urls-for-database-downloads)

</Alert>
{{< /warning >}}

This page lists the IP addresses that may be used for minFraud, GeoIP, and
GeoLite web service requests by our \*.maxmind.com API hostnames. We strongly
Expand All @@ -25,30 +25,13 @@ this page will be in use at a given time. The IPs returned in DNS could change
at any time. Note that the IPs below don’t apply to the `www.maxmind.com`
hostname, which could use any IP and changes frequently.

<IpAddresses />
{{< mm-ips >}}

## Monitoring Changes

MaxMind provides RSS and JSON feeds, allowing you to monitor changes to our
MaxMind provides [**RSS**](/maxmind-server-ip-addresses/index.xml) and [**JSON**](/maxmind-server-ip-addresses.json) feeds, allowing you to monitor changes to our
minFraud, GeoIP, and GeoLite web service server IP addresses.

<LinkGroupContainer>
<LinkGroup>
<LinkGroupCard
description="Subscribe to our RSS and be notified when IP addresses change."
heading="RSS Feed"
icon={RssFeed}
to="/maxmind-server-ip-addresses.xml"
/>
<LinkGroupCard
description="Integrate our JSON feed in your application for change automation."
heading="JSON Feed"
icon={JsonFeed}
to="/maxmind-server-ip-addresses.json"
/>
</LinkGroup>
</LinkGroupContainer>

## Database download IP addresses

MaxMind uses Cloudflare to serve our GeoIP and GeoLite database downloads.
Expand Down
File renamed without changes.
18 changes: 15 additions & 3 deletions hugo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,23 @@ title = 'MaxMind'
tabWidth = 4

[menus]
[[menus.main]]
[[menus.minfraud]]
name = 'minFraud'
pageRef = '/minfraud'
weight = 10
[[menus.main]]
[[menus.geoip]]
name = 'GeoIP'
pageRef = '/geoip'
weight = 20
weight = 10
[[menus.general]]
name = 'MaxMind Server IP Addresses'
pageRef = '/maxmind-server-ip-addresses'
weight = 10

[module]
[[module.mounts]]
source = "data/mm_ips.json"
target = "static/maxmind-server-ip-addresses.json"

[outputs]
home = ["HTML"]
30 changes: 30 additions & 0 deletions layouts/_default/mm-ips.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<rss
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" version="2.0">
<channel>
<title>
{{ .Page.Title }}
</title>
<description>
Feed of MaxMind server addresses.
</description>
<link>https://dev.maxmind.com</link>
<lastBuildDate>{{ index $.Site.Data.mm_ips "lastUpdated" }}</lastBuildDate>
<item>
<title>
{{ .Page.Title }}
</title>
<link>https://dev.maxmind.com/maxmind-server-ip-addresses</link>
<pubDate>{{ index $.Site.Data.mm_ips "lastUpdated" }}</pubDate>
<content:encoded>
{{ range index $.Site.Data.mm_ips "IPv4"}}
{{ . }}<br />
{{ end }}
{{ range index $.Site.Data.mm_ips "IPv6"}}
{{ . }}<br />
{{ end }}
</content:encoded>
</item>
</channel>
</rss>
66 changes: 62 additions & 4 deletions layouts/partials/sidebar.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{{ $currentPage := . }}
<nav aria-label="Main Navigation">
<ul>
{{ $currentPage := . }}
{{ range .Site.Menus.main }}
{{ range .Site.Menus.minfraud }}
<li>
<a
class="{{ if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) }}is-active{{ end }}"
class="{{ if or ($currentPage.IsMenuCurrent "minfraud" .) ($currentPage.HasMenuCurrent "minfraud" .) }}is-active{{ end }}"
href="{{ .URL }}"
{{ if eq .Params.external true }}
target="_blank" rel="noopener noreferrer"
Expand All @@ -17,7 +17,65 @@
{{ range .Children }}
<li>
<a
class="{{ if $currentPage.IsMenuCurrent "main" . }}is-active{{ end }}"
class="{{ if $currentPage.IsMenuCurrent "minfraud" . }}is-active{{ end }}"
href="{{ .URL }}">
{{ .Name }}
</a>
</li>
{{ end }}
</ul>
{{ end }}
</li>
{{ end }}
</ul>

<ul>
{{ range .Site.Menus.geoip }}
<li>
<a
class="{{ if or ($currentPage.IsMenuCurrent "geoip" .) ($currentPage.HasMenuCurrent "geoip" .) }}is-active{{ end }}"
href="{{ .URL }}"
{{ if eq .Params.external true }}
target="_blank" rel="noopener noreferrer"
{{ end }}
>
{{ .Name }}
</a>
{{ if .HasChildren }}
<ul>
{{ range .Children }}
<li>
<a
class="{{ if $currentPage.IsMenuCurrent "geoip" . }}is-active{{ end }}"
href="{{ .URL }}">
{{ .Name }}
</a>
</li>
{{ end }}
</ul>
{{ end }}
</li>
{{ end }}
</ul>

<ul>
{{ range .Site.Menus.general }}
<li>
<a
class="{{ if or ($currentPage.IsMenuCurrent "general" .) ($currentPage.HasMenuCurrent "general" .) }}is-active{{ end }}"
href="{{ .URL }}"
{{ if eq .Params.external true }}
target="_blank" rel="noopener noreferrer"
{{ end }}
>
{{ .Name }}
</a>
{{ if .HasChildren }}
<ul>
{{ range .Children }}
<li>
<a
class="{{ if $currentPage.IsMenuCurrent "general" . }}is-active{{ end }}"
href="{{ .URL }}">
{{ .Name }}
</a>
Expand Down
10 changes: 10 additions & 0 deletions layouts/shortcodes/mm-ips.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<div class="mm-ips">
{{ range index $.Site.Data.mm_ips "IPv4"}}
<span>{{ . }}</span>
{{ end }}
{{ range index $.Site.Data.mm_ips "IPv6"}}
<span>{{ . }}</span>
{{ end }}
</div>

<p class="mm-ips__last-updated">Last updated: {{ index $.Site.Data.mm_ips "lastUpdated" | time.Format "January 02, 2006 3:04 PM Z07:00" }}</p>
3 changes: 3 additions & 0 deletions layouts/shortcodes/warning.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<div class="alert alert--warning">
{{ .Inner | .Page.RenderString }}
</div>
1 change: 1 addition & 0 deletions static/_redirects
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/maxmind-server-ip-addresses.xml /maxmind-server-ip-addresses/index.xml 302

0 comments on commit f9356f0

Please sign in to comment.