Commit Graph

727 Commits

Author SHA1 Message Date
ljacqu ea824ea3f0 #1016 Update hash algorithms list, add test that Deprecated annotation is in sync between enum and hash impl. class 2017-10-19 21:52:55 +02:00
ljacqu fca77b940f #1016 Deprecate MD5, SHA1, SHA512: no longer allowed for active use
- Deprecate unsalted hashes: if such a hash is configured, move it to the legacy hashes setting to still support the existing hashes in the database but hash all passwords from now on with our default, SHA256.
2017-10-19 21:30:19 +02:00
ljacqu 7d445217d6 Merge redundant ConsoleLogger#debug overloads
- No need to distinguish between String[] and Object[] because log4j only has methods for Object[]
2017-10-19 20:14:17 +02:00
Gabriele C 22e95493de #1031 Introduce hasSession field in datasource (#1351)
* Introduce hasSession field in datasource

That makes isLogged more consistent as it will be '1' only when the player is online.

* Fixes

* Fix unit testing

* Update config doc

* Create SessionService

* Create test for SessionService, avoid DB operations if sessions are disabled

* Cleanup: remove outdated warning for session timeout = 0
- Remove outdated warning
- Encapsulate session enabled check in SessionService

* Fix failing SessionServiceTest, add data source integration tests for session methods
2017-10-15 18:32:51 +02:00
Gabriele C 29c30f6c22 Fix unit testing 2017-10-09 09:44:22 +02:00
ljacqu 5be3f8facc #1095 Update SMF hash algorithm to generate salt as SMF does
- The salt isn't used for password hashing but SMF requires that there be one to generate the authentication cookie. This does not yet enable registration from Minecraft: SMF has other non-null columns that need to be tackled. This is a first step.
2017-10-08 22:42:37 +02:00
ljacqu f21605bbb1 Fix failing test 2017-10-08 20:08:46 +02:00
ljacqu 867b32194b #1347 Adapt tests for new change password architecture 2017-10-05 23:44:16 +02:00
sgdc3 e268c3a624 Start working on the changepassword api method
TODO: fix unit testing
2017-10-04 20:12:53 +02:00
Gabriele C d6e2f35efd Fix unit test #1344 2017-10-02 09:03:30 +02:00
Gabriele C caf2a0ee9e Fix non-spigot server support 2017-10-02 08:05:35 +02:00
sgdc3 843baa8e4a Fix 1.7 and 1.8 compatibility 2017-10-01 19:53:15 +02:00
Gabriele C d9399568a3 Add custom tempban unit testing 2017-09-30 21:16:02 +02:00
Gabriele C 7d61f2679c Fix unit testing 2017-09-30 20:51:49 +02:00
Gabriele C e59df84a84 Fix session system (#1337)
* Old session system

* Actually check if sessions are enabled

* Cleanup

* Don't use cached isLogged value
2017-09-30 15:15:25 +02:00
sgdc3 f45092bdd2 Fix limbo player location on join 2017-09-30 15:13:35 +02:00
sgdc3 dc4124de0a Fix unit tests 2017-09-27 14:48:26 +02:00
ljacqu bd7d84a6d2 Small docs cleanup
- NewAPI class will be removed in 5.5, not 5.4
- Add entry for "Deprecated" recommendation in hash algorithms page
- Mention possibility of wildcards for restricted user rules
2017-09-17 11:33:24 +02:00
Gabriele C 6c6fbaf12d Login performance (#1331)
* Ignore intellij tmp files

* Enhance onLogin performance
2017-09-17 09:05:13 +02:00
Gabriele C 45db55a081 Whoops, fix test 2017-09-06 04:11:02 +02:00
Gabriele C 08182e41f6 Fix null address 2017-09-06 00:56:27 +02:00
Gabriele C 8ae8ccf5cf Fix failing tests 2017-09-03 02:54:29 +02:00
Gabriele C 58aad9ed41 Fix unit tests 2017-09-03 00:53:45 +02:00
Gabriele C c0a0a7e2a3 Use TestHelper.mockPlayerIp in tests 2017-09-02 12:47:26 +02:00
Gabriele C 6b875a9ba4 Add permission to bypass country check (#1323)
* Add permission to bypass country check

#1321 Still need to fix unit tests

* Fix test
2017-08-31 19:36:57 +02:00
Gabriele C b96ae61697 Remove some old plugin hooks, update dependencies 2017-08-31 11:47:55 +02:00
HexelDev 1dfb3575b5 #1119 email show permission and privacy improvements (#1312)
* #1119 new permission and email hider

* Updated commands.md

* Improved email hiding method

* Revert "Improved email hiding method"

This reverts commit cb60d7b

* New config option, updated tests, config.md and permission_nodes.md

* Moved to service import, fixed typo and updated config.md

* Removed unused imports O.o
2017-08-12 16:20:06 +02:00
ljacqu 30cb55dabd Update translations page 2017-08-05 14:07:02 +02:00
Gabriele C 7e957cb8c7 Add missing api methods #1304 2017-08-01 16:41:00 +02:00
ljacqu a801f03cf2 Merge pull request #1296 from AuthMe/5.4-Dev
Merge 5.4 development
2017-07-29 15:25:01 +02:00
HexelDev a973dc3f6d Implement restricted users rules with * wildcard support (Enhancement #1278 and #1227) (#1297) 2017-07-25 21:39:31 +02:00
ljacqu 027d0fc775 Create TestHelper method to make Settings mock return defaults 2017-07-23 18:00:51 +02:00
ljacqu efc06ef2a6 #1255 Create resource-closing tests for the MySQL extensions
- Remove test runs with different hash algorithms in the abstract super class
- Create resource-closing tests for the new extension classes
2017-07-23 17:29:36 +02:00
ljacqu 8eceaa8cbb #1255 Simplify MySQL data source extensions
- Mostly oving the logic of getting the ID from the DB to the extensions superclass
2017-07-23 16:38:35 +02:00
ljacqu cbc794ba20 #1255 Extract forum-specific data source actions into separate extension classes 2017-07-23 14:19:28 +02:00
ljacqu f88350b06d Fix Checkstyle violations
- Mostly missing Javadoc on large methods
- CommandInitializer: split command building method into multiple methods
2017-07-16 23:07:13 +02:00
ljacqu 4ac980111d Add some tests, minor Checkstyle fixes 2017-07-16 13:00:55 +02:00
ljacqu e1826c75c8 #1280 Add NOTHING as possible flight restore type 2017-07-10 21:45:05 +02:00
ljacqu cb73160bcd Minor - simplify CodeClimateConfigTest
- No need to load the class when we just want to ensure that the file exists
2017-07-08 23:10:42 +02:00
Gabriele C 919a715ded Cleanup 2017-07-08 22:51:01 +02:00
Gabriele C fe770ac29d Revert "Fix limbo service unit test"
This reverts commit 4cbfc8a812.
2017-07-08 22:45:32 +02:00
Gabriele C 4cbfc8a812 Fix limbo service unit test 2017-07-07 20:41:31 +02:00
Gabriele C cd4693eedf GeoIP: ignore local addresses 2017-07-07 20:41:10 +02:00
Gabriele C 001e5d0376 Pom cleanup, fix LimboService test dependencies
@ljacqu Could you fix the test please?
2017-07-07 15:06:02 +02:00
Gabriele C 4e61117ef7 Add xf table prefix to config
#957
2017-07-06 18:46:24 +02:00
Gabriele C cd4766e0a1 Add regex support to restricted users ip addresses #1227
Seems to work: https://regex101.com/r/zSp6Ke/1
@ljacqu What do you think?
2017-07-03 01:43:56 +02:00
ljacqu f150668fc1 Minor - remove unused imports
- As determined by CodeClimate
2017-07-02 11:00:17 +02:00
ljacqu ff99b63385 #1265 Limbo: fallback to old "group" during deserialization, favor old limbo's groups over new limbo's 2017-07-02 10:55:51 +02:00
Gabriele C c758e15cd7 Store the entire player's list of groups instead of primary group 2017-07-01 19:18:42 +02:00
Gabriele C e6e023a032 Remove legacy jar hint 2017-06-22 23:57:04 +02:00