Discover Centmin Mod today
Register Now

Beta Branch fix CSF country blocking via GeoLite2 mirror fallback without shared …

Discussion in 'Centmin Mod Github Commits' started by eva2000, Sep 3, 2026 at 6:04 AM.

  1. eva2000

    eva2000 Administrator Staff Member

    59,680
    12,541
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,185
    Local Time:
    6:49 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    fix CSF country blocking via GeoLite2 mirror fallback without shared MaxMind key in 140.00beta01

    Centmin Mod no longer injects the shared MaxMind API key into
    /etc/csf/csf.conf. The Centmin Mod CSF Firewall fork (16.33+) can run
    CC_SRC="1" MaxMind GeoLite2 CSV format with an empty MM_LICENSE_KEY by
    downloading from the Centmin Mod GeoLite2 mirror at
    https://mxmind.centminmod.com/, so CC_SRC="1" becomes the default country
    data source. Fixes country blocking silently doing nothing when the key was
    missing and the thinner ipdeny country zones used by CC_SRC="2".
    https://community.centminmod.com/threads/32694/

    Changes:
    - inc/csfinstall.inc: rewrite csf_maxmind_rego() - sync a personal
    MM_LICENSE_KEY from /etc/centminmod/custom_config.inc into csf.conf, clear
    csf.conf's key only when it exactly matches the shared key, never touch an
    unknown key, set CC_INTERVAL="14", single csf -ra only when something changed
    - inc/csfinstall.inc: gate the new behaviour on the installed CSF build
    carrying the mirror fallback; older CSF builds keep their key and stay on
    CC_SRC="2"
    - inc/csfinstall.inc: remove csf_maxmind_geolite_two_download() and its stale
    December 2019 csf-geolite2.tar.gz bootstrap archive with the relative path
    file check bug
    - centmin.sh, centmin-cli.sh: MM_CSF_SRC default 'n' -> 'y' (CC_SRC="1");
    'n' still selects CC_SRC="2" db-ip/ipdeny; custom_config.inc override kept
    - example/custom_config.inc: add MM_LICENSE_KEY and MM_CSF_SRC documentation

    Continue reading...

    140.00beta01 branch