]> git.ipfire.org Git - ipfire.org.git/commitdiff
location: Reword the entire index page
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 3 Apr 2024 13:51:53 +0000 (13:51 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 3 Apr 2024 13:51:53 +0000 (13:51 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/templates/location/index.html
src/web/__init__.py
src/web/location.py

index a7c10d9fd909848678b37b9edfebe8c8ccb2abed..232c68cd9828b9c0b88e4ca45db5df9a36edf6e4 100644 (file)
                <div class="hero-body">
                        <div class="container">
                                <h1 class="title">{{ _("IPFire Location") }}</h1>
-                               <h6 class="subtitle">
-                                       {{ _("A powerful, free IP address location database") }}
-                               </h6>
-                       </div>
-               </div>
-       </section>
 
-       {% if address.country_code %}
-               <section class="has-background-light">
-                       <div class="container">
-                               <p class="has-text-centered px-2 py-1">
-                                       {{ _("We have detected you visiting us from %s.") % format_country_name(address.country_code) }}
-                                       <a href="/location/lookup/{{ address }}">{{ _("Learn More") }}</a>
-                               </p>
-                       </div>
-               </section>
-       {% end %}
-
-       <section class="section">
-               <div class="container">
-                       <div class="block">
-                               <p class="is-size-4">
-                                       IPFire<span class="has-text-primary">_</span> Location is being used in
-                                       firewalls or other threat detection software, load-balancers, online shops,
-                                       websites, analytics &amp; reporting tools and more to detect the
-                                       originating country by IP address.
-                                       We are proud that our software is faster than others
-                                       by maintaining a smaller memory footprint which puts it
-                                       first in performance.
-                               </p>
-                       </div>
-
-                       <div class="block">
-                               <p>
-                                       Our daily updated database does not only have information
-                                       about the originating country of all IPv6 and IPv4 addresses.
-                                       It identifies the Autonomous System (AS) these IP
-                                       addresses belong to, as well and more...
-                                       <code>libloc</code> is the C/C++ library that fires our
-                                       location services and runs on *nix, Mac OS X and more.
-                                       Integration into existing software is very easy and
-                                       bindings for languages like Python and Perl are available.
-                               </p>
-                       </div>
-
-                       <div class="buttons are-medium">
-                               <a class="button is-light" href="/location/how-to-use">
-                                       {{ _("How To Use") }}
-                               </a>
-
-                               <a class="button is-primary" href="/donate">
-                                       {{ _("Donate") }}
-                               </a>
-                       </div>
-               </section>
-       </div>
+                               <h6 class="subtitle mb-6">
+                                       {{ _("Discover the Internet, One Location at a Time") }}
+                               </h6>
 
-       <section class="hero is-medium is-light">
-               <div class="hero-body">
-                       <div class="container">
-                               <div class="columns is-multiline">
+                               <div class="columns is-multiline my-6">
                                        <div class="column is-half">
                                                <div class="columns is-mobile is-vcentered">
                                                        <div class="column is-3 has-text-centered">
                                                        <div class="column">
                                                                <p class="title is-5">{{ _("Threat Detection") }}</p>
 
-                                                               <p>
-                                                                       {{ _("Location information is crucial to identify where an attacker is coming from.") }}
-                                                                       <br>
-                                                                       {{ _("Analyze your traffic for malicious autonomous systems and block the straight away with IPFire.") }}
-                                                               </p>
+                                                               <div class="content">
+                                                                       <p>
+                                                                               By accurately identifying the geographical location of IP addresses,
+                                                                               users can implement targeted security measures to mitigate risks
+                                                                               associated with specific regions or countries.
+                                                                       </p>
+                                                               </div>
                                                        </div>
                                                </div>
                                        </div>
                                        <div class="column is-half">
                                                <div class="columns is-mobile is-vcentered">
                                                        <div class="column is-3 has-text-centered">
-                                                               <span class="fas fa-balance-scale fa-5x"></span>
+                                                               <span class="fas fa-location-dot fa-5x"></span>
                                                        </div>
 
                                                        <div class="column">
-                                                               <p class="title is-5">{{ _("Load-Balancing") }}</p>
+                                                               <p class="title is-5">{{ _("Localization") }}</p>
+
+                                                               <div class="content">
+                                                                       <p>
+                                                                               Businesses can use geolocation data to tailor content and services based
+                                                                               on the location of their users, enhancing user experience and engagement.
+                                                                       </p>
+                                                               </div>
+                                                       </div>
+                                               </div>
+                                       </div>
 
-                                                               <p>
-                                                                       {{ _("Redirect your users to the nearest data center to given them a better user experience with faster websites and faster downloads.") }}
-                                                               </p>
+                                       <div class="column is-half">
+                                               <div class="columns is-mobile is-vcentered">
+                                                       <div class="column is-3 has-text-centered">
+                                                               <span class="fas fa-lock fa-5x"></span>
+                                                       </div>
+
+                                                       <div class="column">
+                                                               <p class="title is-5">{{ _("Access Control") }}</p>
+
+                                                               <div class="content">
+                                                                       <p>
+                                                                               The Location database enables users to enforce access controls based on
+                                                                               geographic criteria, allowing them to restrict or grant access to
+                                                                               resources based on location.
+                                                                       </p>
+                                                               </div>
                                                        </div>
                                                </div>
                                        </div>
                                        <div class="column is-half">
                                                <div class="columns is-mobile is-vcentered">
                                                        <div class="column is-3 has-text-centered">
-                                                               <span class="fas fa-route fa-5x"></span>
+                                                               <span class="fas fa-ethernet fa-5x"></span>
                                                        </div>
 
                                                        <div class="column">
-                                                               <p class="title is-5">{{ _("Online Visitors") }}</p>
+                                                               <p class="title is-5">{{ _("Network Optimization") }}</p>
+
+                                                               <div class="content">
+                                                                       <p>
+                                                                               Geolocation data can be used to optimize network performance by directing
+                                                                               traffic through the most efficient routes based on geographic proximity.
+                                                                       </p>
+                                                               </div>
+                                                       </div>
+                                               </div>
+                                       </div>
 
-                                                               <p>
-                                                                       {{ _("Comply with legal requirements and show visitors the correct information depending on the country they are visiting from.") }}
-                                                               </p>
+                                       <div class="column is-half">
+                                               <div class="columns is-mobile is-vcentered">
+                                                       <div class="column is-3 has-text-centered">
+                                                               <span class="fas fa-gavel fa-5x"></span>
+                                                       </div>
+
+                                                       <div class="column">
+                                                               <p class="title is-5">{{ _("Compliance") }}</p>
+
+                                                               <div class="content">
+                                                                       <p>
+                                                                               Many regulatory requirements necessitate geolocation data for compliance
+                                                                               purposes.
+                                                                               The IPFire Location database helps users meet these requirements by providing
+                                                                               accurate location information.
+                                                                       </p>
+                                                               </div>
                                                        </div>
                                                </div>
                                        </div>
                                                        </div>
 
                                                        <div class="column">
-                                                               <p class="title is-5">{{ _("Open Source") }}</p>
+                                                               <p class="title is-5">{{ _("Open Source & Free Forever") }}</p>
+
+                                                               <div class="content">
+                                                                       <p>
+                                                                               IPFire Location is open source, ensuring transparency, flexibility, and
+                                                                               community-driven development for users who value open and collaborative solutions.
+                                                                       </p>
+                                                               </div>
+                                                       </div>
+                                               </div>
+                                       </div>
+                               </div>
+                       </div>
+               </div>
+       </section>
 
+       <section class="hero">
+               <div class="hero-body">
+                       <div class="container">
+                               <h5 class="title is-5">{{ _("Why Use IPFire Location?") }}</h5>
+
+                               <div class="columns">
+                                       <div class="column is-half">
+                                               <div class="block">
+                                                       <p class="title is-5">{{ _("Accuracy") }}</p>
+
+                                                       <div class="content">
+                                                               <p>
+                                                                       {{ _("IPFire Location aims to be the most accurate database on the market.") }}
+                                                                       {{ _("By gathering data from many sources, we achieve highest accuracy.") }}
+                                                               </p>
+                                                       </div>
+                                               </div>
+
+                                               <div class="block">
+                                                       <p class="title is-5">{{ _("A Multitude Of Information") }}</p>
+
+                                                       <div class="content">
                                                                <p>
-                                                                       {{ _("libloc is free software and relies on support from the community.") }}
-                                                                       {{ _("You can support us by helping to improve our database or with your donation.") }}
+                                                                       {{ _("Unlike other Geolocation databases, IPFire Location does not only hold country information. Instead we have:") }}
+                                                               </p>
+
+                                                               <ul>
+                                                                       <li>{{ _("Country Codes") }}</li>
+                                                                       <li>{{ _("Network Prefixes") }}</li>
+                                                                       <li>{{ _("AS Number & Names") }}</li>
+                                                                       <li>
+                                                                               {{ _("Flags for") }}
+                                                                               <ul>
+                                                                                       <li>{{ _("Anycast Networks") }}</li>
+                                                                                       <li>{{ _("Satellite Networks") }}</li>
+                                                                                       <li>{{ _("Anonymous Proxies") }}</li>
+                                                                                       <li>{{ _("Hostile Networks") }}</li>
+                                                                               </ul>
+                                                                       </li>
+                                                                       <li>
+                                                                               {{ _("A full list of bogons") }}
+                                                                       </li>
+                                                               </ul>
+                                                       </div>
+                                               </div>
+                                       </div>
+
+                                       <div class="column is-half">
+                                               <div class="block">
+                                                       <p class="title is-5">{{ _("Performance") }}</p>
+
+                                                       <div class="content">
+                                                               <p>
+                                                                       {{ _("For some applications, performance is key.") }}
+                                                                       {{ _("IPFire Location is designed to organise all data for the fastest lookups enabling applications that were not possible before.") }}
+                                                               </p>
+                                                       </div>
+                                               </div>
+
+                                               <div class="block">
+                                                       <p class="title is-5">{{ _("Easy Integration") }}</p>
+
+                                                       <div class="content">
+                                                               <p>
+                                                                       {{ _("IPFire Location uses a proprietary database format that is read and written by our own software.") }}
+                                                                       {{ _("A lightweight C library is the core of this application and there are bindings available for Python, Perl and Lua, too.") }}
+                                                               </p>
+                                                       </div>
+                                               </div>
+
+                                               <div class="block">
+                                                       <p class="title is-5">{{ _("Secure And Instant Updates") }}</p>
+
+                                                       <div class="content">
+                                                               <p>
+                                                                       {{ _("The database is small to download and cryptographically signed which is a necessity to be deployed in security applications.") }}
                                                                </p>
                                                        </div>
                                                </div>
                                        </div>
                                </div>
+
+                               <a class="button is-medium is-primary is-fullwidth" href="/location/how-to-use">
+                                       {{ _("Learn How To Use IPFire Location") }}
+                               </a>
                        </div>
                </div>
        </section>
        <section class="hero">
                <div class="hero-body">
                        <div class="container">
-                               <h4 class="title is-4">{{ _("Who Is Using IPFire Location?") }}</h4>
+                               <h5 class="title is-5">{{ _("Who Is Using IPFire Location?") }}</h5>
 
                                <div class="level">
                                        <div class="level-item">
index 42b0c3e9900049aa3df11273bdd2b870281999f4..36de832acb767e634404f47a3ecd76a923ff7dee 100644 (file)
@@ -195,7 +195,7 @@ class Application(tornado.web.Application):
                        (r"/.well-known/change-password", auth.WellKnownChangePasswordHandler),
 
                        # Location
-                       (r"/location/?", location.IndexHandler),
+                       (r"/location/?", StaticHandler, { "template" : "location/index.html" }),
                        (r"/location/download", tornado.web.RedirectHandler, { "url" : "/location/install" }),
                        (r"/location/how\-to\-use", StaticHandler, { "template" : "location/how-to-use/index.html" }),
                        (r"/location/how\-to\-use/cli", StaticHandler, { "template" : "location/how-to-use/cli.html" }),
index 1808983262a93c7d04610c94df95b6e8327652ac..90fd45b4cf62a6811da05586e0962361960f07a4 100644 (file)
@@ -3,13 +3,6 @@
 from .. import util
 from . import base
 
-class IndexHandler(base.AnalyticsMixin, base.BaseHandler):
-       def get(self):
-               self.render("location/index.html",
-                       address=self.current_address,
-               )
-
-
 class LookupHandler(base.AnalyticsMixin, base.BaseHandler):
        async def get(self, address):
                # Lookup address