Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    All alerts showing as unk country code.. help

    Scheduled Pinned Locked Moved pfBlockerNG
    26 Posts 6 Posters 3.3k Views 7 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      serbus
      last edited by serbus

      Hello!

      Sorry to keep bugging you...

      It looks like pfb is just renaming the download from maxmind to ,mmdb without actually extracting the files.

      The GeoLite2-Country.mmdb file is 2048734 bytes, which is the same length as the GeoLite2-Country_20200303.tar.gz download from maxmind.

      cp GeoLite2-Country.mmdb GeoLite2-Country.tar.gz
      and then
      gzip -l ./GeoLite2-Country.tar.gz
      shows that the mmdb file was really a tar.gz file

      I think....

      John

      Lex parsimoniae

      1 Reply Last reply Reply Quote 0
      • S Offline
        serbus
        last edited by

        Hello!

        Just more guessing...I am not sure I am looking at the correct code...

        The download from maxmind is 'application/gzip'

        The code doesnt look like it will decompress this type, and will only rename the downloaded file.

        Maybe

        if ($file_type == 'application/x-gzip' || $file_type == 'application/gzip' )

        ?

        John

        Lex parsimoniae

        1 Reply Last reply Reply Quote 0
        • E Offline
          ex1580
          last edited by ex1580

          @BBcan177 I am still seeing this as of today on pfSense 2.4.5-RELEASE and pfBlockerNG-devel 2.2.5_30. Restarting the pfb_filter service didnt seem to fix it.
          8d41c7dd-4501-4ae1-a5b8-11406b2465b7-image.png

          BBcan177B 1 Reply Last reply Reply Quote 0
          • GertjanG Offline
            Gertjan
            last edited by

            If "191.232.138.2" isn't present in any of your GeoIP files, then the "unknown" is understandable.

            While waiting for a reply from BBcan177, have a look at the files and check if this is true ?

            No "help me" PM's please. Use the forum, the community will thank you.
            Edit : and where are the logs ??

            1 Reply Last reply Reply Quote 0
            • BBcan177B Offline
              BBcan177 Moderator @ex1580
              last edited by

              @ex1580
              Yes there was a change to the file mime-types in pfSense 2.4.5 and the change to fix Shallalist and UT1 is also needed to download one of the MaxMind databases.

              Install the latest version of the package and re-download MaxMind from the shell with this command:

              php -f /usr/local/www/pfblockerng/pfblockerng.php dc
              

              New events should show the GeoIP column in the alerts tab.

              "Experience is something you don't get until just after you need it."

              Website: http://pfBlockerNG.com
              Twitter: @BBcan177  #pfBlockerNG
              Reddit: https://www.reddit.com/r/pfBlockerNG/new/

              1 Reply Last reply Reply Quote 1
              • E Offline
                ex1580
                last edited by

                @BBcan177 Excellent! Working as expected now. Maybe someday there can be a button or comment explaining how to re-download from MaxMind because I didnt even know the command did that when I was looking at it. Thanks! Keep up the good work!

                1 Reply Last reply Reply Quote 0
                • First post
                  Last post
                Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.