Commit Graph

18 Commits

Author SHA1 Message Date
3meraldK 65a272d6cb Config option to disable GeoIP database #2720 2023-09-24 17:26:16 +02:00
ljacqu 571c6106a7 Fix some Checkstyle issues
- Remove unused imports
- Fix issues relating to line length / whitespace
- Update Checkstyle suppression in matcher classes with new check name
2022-01-30 10:32:49 +01:00
games647 fc8c9d8748
Open GEO connection after checking config values
(Related #2289)
2021-03-28 22:41:03 +02:00
Gabriele C 0e8da5a556 Fix the GeoIp DB updater 2020-01-26 22:29:14 +01:00
Gabriele C a43127dd2b
Update the GeoIp database download method [BREAKING] (#1990)
* Update the GeoIp database download method [BREAKING]

Now GeoIp database updates require a ClientID and a LicenseKey, which can be obtained for free at https://www.maxmind.com/en/accounts/current/license-key

* Codestyle
2020-01-21 10:28:50 +01:00
ljacqu c34f00f759 #1874 Introduce individual ConsoleLogger instance per class (#1875)
* #1874 Introduce individual ConsoleLogger instance per class
- Create ConsoleLoggerFactory from which a separate logger can be created for each class
- Allows to support individual log level settings in the future

* Fix CodeStyle issue

* Replace full class name with import

* Update usages after merge from master
2019-08-06 15:15:16 +02:00
ljacqu f79c364f84 Minor fixes as reported by CodeClimate 2018-09-01 09:17:42 +02:00
Gabriele C da7e7edc37
Fix messaging [WIP] (#1614)
* Fix messaging [WIP]

* Make codeclimate happy

* Codeclimate, pls

* got it, i hope

* Improvements

* Remove duplicated checks, other improvements, make login/logout broadcasts

* Optimize project imports

* Make codeclimate happy again
2018-08-26 15:29:47 +02:00
Gabriele C adb3c06f51 Fix #1617
Dinstinct invalid countries ("--") from localhost addresses ("LOCALHOST"), allow localhost access by default.
2018-08-22 16:56:14 +02:00
games647 0a3b66bc7d
Start a reading instance after downloading (Related #1581) 2018-06-03 13:34:51 +02:00
games647 135e323358
Set the downloading flag in order to mark it as successful (Related #1581) 2018-06-03 09:47:52 +02:00
games647 f39141ed53
Fix race condition starting multiple database downloads (Related #1581) 2018-06-02 21:50:43 +02:00
games647 5058747b10
Download database only if there is a newer one uploaded (Fixes #1581) 2018-06-02 21:50:02 +02:00
games647 f33446ee25 Migrate to GEO IP 2 (Related #1471) (#1529)
* Migrate to GEO IP 2, because support will drop in April

* Change all links of maxmind to https
* Update maxmind database dependency and add javatar to extract
the database from the tar archive
(now only a small difference in jar file size -> ~80KB smaller)
* Verify downloaded archive using MD5 (There are no other checksums available)
* Migrate to Java NIO instead of old java file I/O (Feedback?)
* Internal Optional usage for nullable values (Feedback?)

Minor:
* Schedule a Bukkit async task instead of creating a thread manually
* Validate ip input string
* Extract validation into single method
* Close all resources safely using try-resources

* More https links

* Add documentation

* Set the same last modification as in the tar archive

* Fix tests

* Comment how the legacy API responded to unknown entries

* Document missing function param

* Document our maxmind dependency modifications

* Include time unit into constant

* More logging for downloading the database

* Add missing return if the database cannot be found

* Delete temporarily file after working with it
2018-03-17 03:00:24 +01:00
Gabriele C cd4693eedf GeoIP: ignore local addresses 2017-07-07 20:41:10 +02:00
ljacqu 1f8307c8f6 Fix minor checkstyle issues
- Add JavaDoc where checkstyle expects it
- Fix line too long issues
- ...
2017-05-07 11:59:01 +02:00
Gabriele C b53f71706a Join process cleanup, change some default settings (should improve performance and security with default settings) 2016-11-15 18:41:27 +01:00
Gabriele C 7b5a857f74 Remove useless packages 2016-10-07 19:19:12 +02:00