Code Monkey home page Code Monkey logo

mcauthenticator's Introduction

MCAuthenticator

MCAuthenticator is a Bukkit API based plugin designed to allow for 2 Factor Authentication (otherwise known as TOTP, or the Time-Based One-Time Password Algorithm (RFC6238)) for all players on a server to optionally use, with configurable enforcement for certain players through permission nodes. This is designed to allow for more secure minecraft server environments, especially when account cracking and hacking are so prevalent. This plugin reduces the risk of a compromised staff account greatly, making it much harder to compromise a staff account and compromise a server in general.

Popular 2FA (TOTP) Apps by Mobile Device Operating System

Windows Phone

Android

iOS

Installation

To install MCAuthenticator, you simply put the MCAuthenticator.jar within the plugins/ folder of your Bukkit/Spigot/BungeeCord server. Once you start the server, the plugin will generate a configuration as described below.

Compatibility

Build Status

MCAuthenticator is tested with Spigot 1.8.8, on Java 8. However, MCAuthenticator is compatible with Java 7, and there is no reason it shouldn't work with Bukkit 1.6.x or 1.7.x servers. We will officially support 1.6.x spigot and up.

If you find issues on any server versions 1.6.x and up, please report them in issues.

Commands

MCAuthenticator uses 1 root command, /auth (with aliases /2fa, /authenticator, and /mcauthenticator) with a set of sub commands:

  • /auth enable [player] - Enables 2FA on an account, or your own account if a player isn't specified.
  • /auth disable [player] - Disables 2FA on an account, or your own account if a player isn't specified.
  • /auth reset [player] - Keeps 2FA enabled, but resets the 2FA on your account or another player's if player is specified.
  • /auth reload - Reloads the configuration, then re-authenticates all players based on configured authentication rules.

Permissions

MCAuthenticator uses the root permission mcauthenticator, with a set of sub permissions to control the behaviour of various aspects of the plugin.

Explanation of defaults

Each permission has one of two defaults: op and console only. If a permission is defaulting to console only, even if a player has op, they will not be able to perform the command unless they explicitly have the listed permission.

Command controlling permissions

  • mcauthenticator.use (default: op) - Allows for the root use of the /auth command. In order to do anything with the /auth command, the player must have this permission.
  • mcauthenticator.enable (default: op) - Allows for the user to do /auth enable on themselves. This does not control whether the player is allowed to have 2FA enabled on their account; if console or a player with mcauthenticator.enable.other enables 2FA on their account, the plugin will let them.
  • mcauthenticator.disable (default: op) - Allows for the user to do /auth disable on themselves.
  • mcauthenticator.enable.other (default: console only) - Allows for the user to perform /auth enable , enabling authentication for another player. The other player does not need to have mcauthenticator.enable in order to have 2FA enabled on their account.
  • mcauthenticator.disable.other (default: console only) - Allows for the user to perform /auth disable , disabling another player's authentication.
  • mcauthenticator.reset (default: op) - Allows for a player to reset their own account's authentication.
  • mcauthenticator.reset.other (default: console only) - Allows for the user to reset other user's authentications.
  • mcauthenticator.reload (default: console only) - Allows for the user to reload the configuration

Enforcement Permissions

  • mcauthenticator.lock (default: op) - Does one of 2 things:
    1. Forces the user to always 2FA enabled, not allowing them to disable or reset their own authentication
    2. Does not allow anyone but console to reset or disable their authentication. Even if the user has any of the .other permission nodes, the plugin will not allow them to perform any changes to authentication. This should be given to any staff members, as it will prevent any other compromised account from then chainly compromising other staff (or important persons) accounts.

Configuration

The configuration of the plugin can be default out of the box, but it is highly suggested that at least some of the configuration defaults be customized to your server.

All of the configuration is located in plugins/MCAuthenticator/config.yml. Each of the configuration options listed below are all located within this yml.

Available Authentication Mechanisms

Since 1.1.0, MCAuthentication has supported multiple types of authentication mechanisms:

  • 2fa
  • Yubikey

Each of these can be turned on and off within the config file under authenticators. When setting up 2FA, the user may use any of the configured authentication mechanisms. The plugin will auto-detect which mechanism they use, and authenticate them off of only that method in the future.

Yubikey

In order to offer authentication through Yubikey, you must have a clientId as well as a clientSecret. Both of these are offered at https://upgrade.yubico.com/getapikey/. If you do not add these api credentials, Yubikey authentication will not function correctly. These should be entered under yubikey within the configuration.

GAuth

The serverIp field specifies what will be displayed to the user within their 2FA app.

For example, with a username Ichbinjoe and serverIp set to ibj.io, a sample GAuth entry will look like the following:

Sample GAuth Entry

Forcing Same IP Authentication

By default, MCAuthenticator does not force a player to re-authenticate if they rejoin from the last IP they were authenticated from. This can be disabled by setting forceSameIPAuthentication to true. When set to true, the plugin force the user to re-authenticate through 2FA each and every time they log into the server.

Message customization

Under the messages section of the configuration, MCAuthenticator allows you to customize all publicly displayed messages, in order to modify color schemes and the prefix to better fit your server's color scheme/language requirements. All staff commands are hardcoded, simply because there is much less of a reason to customize these messages.

Each entry supports &<opcode> based colorcodes, as well as the \n character for splitting up messages onto multiple lines. Where contextually logical, a %player% replacement has been added to customize each message based on occurrence.

Data Source Configuration

MCAuthenticator supports 1 of 3 different data sources:

  • Single File - Stores all player data in one file
  • Directory - Stores each player in their own file within a directory
  • MySQL - Stores all player data within a table in a MySQL/MariaDB table.

Single File Data Source

To enable the single file data source, dataBacking.type should be set to single. The file to which the single file data source saves to is configured by setting dataBacking.file. This file is then by default present in plugins/MCAuthenticator

Directory Data Source

To enable the directory data source, dataBacking.type should be set to directory. The directory to which all of the player data is saved is configured by the dataBacking.directory field. Within this directory, a file for each player, structured <uuid>.json stores a single JSON object with the authentication details.

MySQL Data Source

To enable the MySQL data source, dataBacking.type should be set to mysql. The database connection details should then be set in dataBacking.mysql. The default connection url is jdbc:mysql://localhost:3000/db, with the format jdbc:mysql://<ip>:<port>/<databaseName>. username and password should also be set to a username and password that is able to access the database.

Building MCAuthenticator

To build MCAuthenticator, run mvn package in a command terminal, and the result of the build will save the jar to target/MCAuthenticator-<version>.jar.

BungeeCord Mode

BungeeCord support will only require one authentication per player join, not every time the player switches servers, does not require same IP to be true, and will deny BungeeCord commands until the player is authenticated. To enable BungeeCord support, enable under the bungee should be set to true, and channel should be set to the same channel as the BungeeCord plugin's pluginChannel is set to. BungeeCord mode requires that the plugin also be installed on the BungeeCord instance(s).

Contributing

We love contributions! Feel free to fork this project and PR any changes/ enhancements! Of note, we use the MIT License, which is listed here.

Reporting Issues/Bugs or Suggesting Additions

We request that issues/ suggestions be submitted on the Github issue manager. This allows us to be more vigilant of issues, and allow more flexibility in managing the project.

mcauthenticator's People

Contributors

aaomidi avatar astei avatar ichbinjoe avatar itsjh avatar oloflarsson avatar phoenix616 avatar robomwm avatar techcable avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mcauthenticator's Issues

No Messages for everything

Hello

When someone with permissions who has a locked account, joines, that he has he to authenticate, he dosent get any inputs, that he should have to authenticate himself or that when i've resettet him, to reconnect the app for the auth-code.

What does here not work?

ThankYou for our support!

Greatings, calgia

Authenticate every Login

Hi

Can i setup the Plugin that i‘ve have to authenticate every Time i‘ve log me in on the Server

Server Crash Bug on auth reload?

Looks like there's a bug in this that's causing Paper 1.9 to crash.

Judging by the fact that all I did on the server (no one else was on) is to /auth reload after changing a small thing I'd assume that this is likely to effect multiple people.

[21:20:47 INFO]: Fayettemat issued server command: /auth
[21:20:50 INFO]: Fayettemat issued server command: /auth enable
[21:21:11 INFO]: Fayettemat issued server command: /auth reset
[21:22:01 INFO]: [LogViewer] Fayettemat issued command: auth reload
[LogServer] Command sent.
[21:22:01 INFO]: [MCAuthenticator] Using RFC6238 (Google Authenticator 2FA) based > authentication.
[21:23:03 ERROR]: The server has stopped responding!`

Crash Dump Log

I'm going to try this again on another server in a few to see if it'll do it with just MCAuthenticator and the latest Paper 1.9. Also, I'm assuming this is due to the watch dog timer too.

I'll reply again once I do a bit more testing but I have 2FA and Yubikey both enabled and it's using a MySQL database as well.

error

[21:11:16 WARN]: Could not pass incoming plugin message to MCAuthenticator v2.0.3
java.lang.NullPointerException
        at io.ibj.mcauthenticator.engine.events.PluginMessageEvent.onPluginMessageReceived(PluginMessageEvent.java:28) ~[?:?]
        at org.bukkit.plugin.messaging.StandardMessenger.dispatchIncomingMessage(StandardMessenger.java:427) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.PlayerConnection.a(PlayerConnection.java:2534) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.PacketPlayInCustomPayload.a(SourceFile:58) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.PacketPlayInCustomPayload.a(SourceFile:8) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.PlayerConnectionUtils$1.run(SourceFile:13) [patched_1.11.2.jar:git-Paper-1009]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_111]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_111]
        at net.minecraft.server.v1_11_R1.SystemUtils.a(SourceFile:46) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.MinecraftServer.D(MinecraftServer.java:821) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.DedicatedServer.D(DedicatedServer.java:403) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.MinecraftServer.C(MinecraftServer.java:749) [patched_1.11.2.jar:git-Paper-1009]
        at net.minecraft.server.v1_11_R1.MinecraftServer.run(MinecraftServer.java:648) [patched_1.11.2.jar:git-Paper-1009]
        at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]

Problems with Cloudnet

I want to use the plugin with cloudnet.
I uploaded the plugin at the proxy's plugins-folder and at the other plugins-folders but when I change the server, I need to enter the code again.

How could I fix it so I don't need to enter the code again?

Suggestion

Hello, This plugin is amazing!

But could you add like it gives you a map in the inventory with the code.
And maybe add redis to it, plugin messaging is slow.

Warpdrive isn`t work with MCAuthenticator

Yep, that`s the issue.

Wardprive ships are unable to jump, while MCAuthenticator is installed. When jumping, this message appears:

JumpSequencer/1177801404 '346fb388-5379-4ce1-b709-43ed39366cb7:0a-7046-4d63-a0ae-1c0e9ed57846' @ 'DIM223' (4834 79 4681) #5 Killing jump sequencer... (Ship is entering a protected area at (4833 83 4678)
Not enough space after adjustment, jump aborted!)

NO MATTER if I`m trying to jump in other world, region or area. This happens in every world I have.

Removing MCAuthenticator solved the issue, but this is unacceptable way. It looks like MCAuthenticator offers Warpship to authenticate, because, if the player logs in, he can`t move or do something before he acquires 2FA code. So I think, MCA recognizes Warpdrive fakeplayer as a real one. But these are just my thoughts.

Thank you in advance!

Issue with latest commit

Hello,

I have compiled the plugin from the latest commit and am experiencing an issue.

At least when a player needs to register by the mcauthenticator.lock permission, (the player can still move around and break/place blocks, but I don't know if that's intended behavior) the map doesn't appear in the inventory and the console shows the following error:

Could not pass event PlayerJoinEvent to MCAuthenticator v2.0.5-SNAPSHOT
org.bukkit.event.EventException
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:302) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:78) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:517) [patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:502) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PlayerList.onPlayerJoin(PlayerList.java:314) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PlayerList.a(PlayerList.java:173) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.LoginListener.b(LoginListener.java:144) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.LoginListener.c(LoginListener.java:54) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.NetworkManager.a(NetworkManager.java:231) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.ServerConnection.c(ServerConnection.java:148) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:875) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:378) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:713) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:616) [patched.jar:git-PaperSpigot-"4c7641d"]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_212]
Caused by: java.lang.NoSuchMethodError: org.bukkit.inventory.PlayerInventory.setItemInMainHand(Lorg/bukkit/inventory/ItemStack;)V
at io.ibj.mcauthenticator.auth.RFC6238.sendAndRenderMap(RFC6238.java:127) ~[?:?]
at io.ibj.mcauthenticator.auth.RFC6238.initUser(RFC6238.java:104) ~[?:?]
at io.ibj.mcauthenticator.model.User.init2fa(User.java:109) ~[?:?]
at io.ibj.mcauthenticator.MCAuthenticator.handlePlayer(MCAuthenticator.java:73) ~[?:?]
at io.ibj.mcauthenticator.engine.events.ConnectionEvent.onPlayerConnect(ConnectionEvent.java:48) ~[?:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_212]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_212]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_212]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_212]
at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:300) ~[patched.jar:git-PaperSpigot-"4c7641d"]
... 15 more

I am using Paper 1.8.8 as server software.

If any other information is needed to fix this issue, I'd be glad to help.

Thanks,
-Mathis

Map doesn't show up

Hello!

I tried multiple spigot versions, even server only with MCAuthenticator, but none of them worked - I wasn't able to see the map when enabling 2fa. Please fix!

Feature to disable SSL for MySQL

MCAuthenticator is a great plugin when it comes to 2FA in Minecraft. However one simple feature should be added in the config, the possibility to disable SSL for the MySQL connection. 🙂

MCAuthenticator Version 3 Roadmap

Version 3.0 is a ground up rewrite of MCAuthenticator. MCAuthenticator has accumulated a fair amount of technical debt, and requires an architectural change in order to expand its featureset into a full fledged account authenticator (whether online or offline). In the end, like all great projects, MCAuthenticator will turn into a framework for authentication, with sane defaults and hooks for people to add their own behavior.

Platform Support

  • Bukkit
  • Bungeecord
  • Sponge

Note: Lilypad will have inherent support due to the fact that all control in Lilypad is derived from access to 'backend' servers.

Core Features

  • Plugin API / Emitted events
  • Online / Offline server mode
  • Cross Server Authentication (Authenticate on first server, authenticated through entire session)
  • Javascript (Nashorn) event layer (sane default, however is able to be modified by the user easily)
  • Efficient multilayer internal event routing system (base rules + authentication / mode specific layers)

Authentication Mechanisms

  • RFC6238 (TOTP)
  • Yubikey OTP
  • Plaintext hashed password
  • Custom Javascript (Nashorn) hook
  • Custom Java hook

Datastore Backends

  • MariaDB / MySQL
  • PostgreSQL
  • MongoDB
  • Directory based flatfile
  • Single file flatfile

Licensing

  • GNU GPLv3

You can see the current source code by visiting the v3 branch here

Map ItemStack amount 0

When you give the player the map item stack, you set the amount to 0. That makes them not receive any items. Please update :)

error

[00:14:27 INFO]: UUID of player PotatoKing66 is aa46fd46-27fa-4944-ac4d-ed99e0f358dd
[00:14:27 INFO]: Creating empty config: /root/prison/plugins/Essentials/userdata/159018b3-99d3-3f9f-a9c0-759dbd304821.yml
[00:14:27 INFO]: CH: Running original command on player PotatoKing66 ----> /guidebook
[00:14:27 INFO]: [Essentials] Found new UUID for PotatoKing66. Replacing 159018b3-99d3-3f9f-a9c0-759dbd304821 with aa46fd46-27fa-4944-ac4d-ed99e0f358dd
[00:14:27 ERROR]: Could not pass event PlayerDropItemEvent to MCAuthenticator v2.0.3
org.bukkit.event.EventException
        at org.bukkit.plugin.EventExecutor$1.execute(EventExecutor.java:46) ~[patched_1.11.2.jar:git-Paper-1029]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:78) ~[patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:517) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:502) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.EntityHuman.a(EntityHuman.java:582) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.EntityHuman.drop(EntityHuman.java:540) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.CommandGive.execute(SourceFile:75) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.craftbukkit.v1_11_R1.command.VanillaCommandWrapper.dispatchVanillaCommand(VanillaCommandWrapper.java:109) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.craftbukkit.v1_11_R1.command.VanillaCommandWrapper.execute(VanillaCommandWrapper.java:38) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:151) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.craftbukkit.v1_11_R1.CraftServer.dispatchCommand(CraftServer.java:675) [patched_1.11.2.jar:git-Paper-1029]
        at com.laytonsmith.abstraction.bukkit.BukkitMCServer.dispatchCommand(BukkitMCServer.java:129) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.functions.Meta$sudo.exec(Meta.java:236) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:375) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:344) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1995) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1952) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.run(Script.java:207) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.AliasCore.alias(AliasCore.java:153) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.functions.Meta$call_alias.exec(Meta.java:496) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:375) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:344) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.seval(Script.java:253) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.functions.BasicLogic$_if.execs(BasicLogic.java:85) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:334) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.Script.eval(Script.java:344) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1995) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.MethodScriptCompiler.execute(MethodScriptCompiler.java:1952) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.events.AbstractEvent.execute(AbstractEvent.java:109) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.events.BoundEvent.execute(BoundEvent.java:320) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.events.BoundEvent.trigger(BoundEvent.java:278) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.events.EventUtils.FireListeners(EventUtils.java:253) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.core.events.EventUtils.TriggerListener(EventUtils.java:240) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.laytonsmith.abstraction.bukkit.events.drivers.BukkitPlayerListener.onPlayerJoin(BukkitPlayerListener.java:73) [CommandHelper.jar:3.3.2-SNAPSHOT]
        at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor235.execute(Unknown Source) [?:?]
        at org.bukkit.plugin.EventExecutor$1.execute(EventExecutor.java:44) [patched_1.11.2.jar:git-Paper-1029]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:78) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:517) [patched_1.11.2.jar:git-Paper-1029]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:502) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.PlayerList.onPlayerJoin(PlayerList.java:352) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.PlayerList.a(PlayerList.java:178) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.LoginListener.b(LoginListener.java:153) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.LoginListener.F_(LoginListener.java:57) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.NetworkManager.a(NetworkManager.java:239) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.ServerConnection.c(ServerConnection.java:150) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.MinecraftServer.D(MinecraftServer.java:916) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.DedicatedServer.D(DedicatedServer.java:403) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.MinecraftServer.C(MinecraftServer.java:749) [patched_1.11.2.jar:git-Paper-1029]
        at net.minecraft.server.v1_11_R1.MinecraftServer.run(MinecraftServer.java:648) [patched_1.11.2.jar:git-Paper-1029]
        at java.lang.Thread.run(Thread.java:745) [?:1.8.0_111]
Caused by: java.lang.NullPointerException
        at io.ibj.mcauthenticator.engine.events.InventoryEvent.auth(InventoryEvent.java:61) ~[?:?]
        at io.ibj.mcauthenticator.engine.events.InventoryEvent.onDrop(InventoryEvent.java:52) ~[?:?]
        at com.destroystokyo.paper.event.executor.asm.generated.GeneratedEventExecutor284.execute(Unknown Source) ~[?:?]
        at org.bukkit.plugin.EventExecutor$1.execute(EventExecutor.java:44) ~[patched_1.11.2.jar:git-Paper-1029]
        ... 51 more
[00:14:27 INFO]: [PotatoKing66: Given [§aPrison Information§r] * 1 to PotatoKing66]
[00:14:27 INFO]: PotatoKing66[/121.223.162.150:50293] logged in with entity id 7497 at ([prison]-165.5, 163.0, -30.5)
[00:14:27 INFO]: REMOTE AUTH
[00:14:27 INFO]: Creating empty config: /root/prison/plugins/Essentials/userdata/aa46fd46-27fa-4944-ac4d-ed99e0f358dd.yml

Unable to enter code

For some reason I am unable to enter my 2fa code. My co-owner was able to get hers set up, but when I enter my code, it doesn't say whether or not it's correct or incorrect, it just says "You are not authenticated, please enter your 2fa code!" I've changed AuthMe's configuration to allow the /2fa and /auth commands before login, and as I said my co-owner was able to get hers set up. I use 2FA for a lot of things, so I'm positive I have it set up correctly on my end (I click on the link to get the temporary code, add it to GAuth and enter it). The server time is sync'd via NTP to our national time server here in Canada (time.nrc.ca) so I don't think it's the server clock being off, and anyway it doesn't tell me that the code is wrong.

Would love to get this figured out as I have to leave 2fa disabled if I want to play. I am using the default config file with only the name of our website entered, no other changes. This is Minecraft 1.12.1, Spigot server. Would be happy to provide any other data you need.

The plugin stops working after a server reboot/plugin reload

On Minecraft 1.7.10 after i reboot the server (or reload the plugin) the plugin stops working and then to make it work again i have to reset its save folder.

Here is the log after i start the server:

[18:40:51] [Server thread/INFO]: [MCAuthenticator] Enabling MCAuthenticator v2.0.4
[18:40:51] [Server thread/INFO]: [MCAuthenticator] Using RFC6238 (Google Authenticator 2FA) based authentication.
[18:40:52] [Server thread/ERROR]: Error occurred while enabling MCAuthenticator v2.0.4 (Is it up to date?)
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_OBJECT but was BEGIN_ARRAY at line 1 column 2
	at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:180) ~[?:?]
	at com.google.gson.Gson.fromJson(Gson.java:755) ~[?:?]
	at com.google.gson.Gson.fromJson(Gson.java:694) ~[?:?]
	at io.ibj.mcauthenticator.model.datasource.SingleFileUserDataSource.invalidateCache(SingleFileUserDataSource.java:85) ~[?:?]
	at io.ibj.mcauthenticator.model.datasource.SingleFileUserDataSource.<init>(SingleFileUserDataSource.java:34) ~[?:?]
	at io.ibj.mcauthenticator.Config.<init>(Config.java:73) ~[?:?]
	at io.ibj.mcauthenticator.MCAuthenticator.reload(MCAuthenticator.java:103) ~[?:?]
	at io.ibj.mcauthenticator.MCAuthenticator.onEnable(MCAuthenticator.java:53) ~[?:?]
	at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:316) ~[spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:332) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:412) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at org.bukkit.craftbukkit.v1_7_R4.CraftServer.loadPlugin(CraftServer.java:476) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at org.bukkit.craftbukkit.v1_7_R4.CraftServer.enablePlugins(CraftServer.java:394) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.MinecraftServer.n(MinecraftServer.java:360) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.MinecraftServer.g(MinecraftServer.java:334) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.MinecraftServer.a(MinecraftServer.java:290) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.DedicatedServer.init(DedicatedServer.java:210) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.MinecraftServer.run(MinecraftServer.java:458) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
	at net.minecraft.server.v1_7_R4.ThreadServerApplication.run(SourceFile:628) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
Caused by: java.lang.IllegalStateException: Expected BEGIN_OBJECT but was BEGIN_ARRAY at line 1 column 2
	at com.google.gson.stream.JsonReader.expect(JsonReader.java:339) ~[?:?]
	at com.google.gson.stream.JsonReader.beginObject(JsonReader.java:322) ~[?:?]
	at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:168) ~[?:?]
	... 18 more

Here is the log after i run the command /2fa:

ShonP40 issued server command: /2fa
[18:41:03 ERROR]: null
org.bukkit.command.CommandException: Unhandled exception executing command '2fa' in plugin MCAuthenticator v2.0.4
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46) ~[spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:181) ~[spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at org.bukkit.craftbukkit.v1_7_R4.CraftServer.dispatchCommand(CraftServer.java:767) ~[spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.PlayerConnection.handleCommand(PlayerConnection.java:1043) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.PlayerConnection.a(PlayerConnection.java:880) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.PacketPlayInChat.a(PacketPlayInChat.java:28) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.PacketPlayInChat.handle(PacketPlayInChat.java:65) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.NetworkManager.a(NetworkManager.java:186) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.ServerConnection.c(ServerConnection.java:81) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.MinecraftServer.v(MinecraftServer.java:734) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.DedicatedServer.v(DedicatedServer.java:289) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.MinecraftServer.u(MinecraftServer.java:584) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.MinecraftServer.run(MinecraftServer.java:490) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        at net.minecraft.server.v1_7_R4.ThreadServerApplication.run(SourceFile:628) [spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
Caused by: java.lang.NullPointerException
        at io.ibj.mcauthenticator.engine.CommandHandler.printHelp(CommandHandler.java:78) ~[?:?]
        at io.ibj.mcauthenticator.engine.CommandHandler.onCommand(CommandHandler.java:44) ~[?:?]
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) ~[spigot.jar:git-Spigot-1.7.9-R0.2-208-ge0f2e95]
        ... 13 more

database down prevents chat and commands

as the title says, I recently had an issue where the database for this plugin was unreachable, players were able to log in and build however they could not chat or use commands

Yubikey Auth Doesn't Seem To Work

Tried with the latest source via the repo here (as of now) and set the Yubikey config up.. but it's not working. To make matters worse it won't let me disable it via the console either.

Sadly, no errors to report from the console.. Tested using lastest Spigot 1.9.

found auth error

Says my code from the authenticator app is invalid.

Exact msg: That was not a valid code, You are not yet authenticated.

but it was a valid code. Tried 6 different codes.

NullPointerException in ChatEvent listener

Running version 1.1.2

[13:03:59] [Async Chat Thread - #1/ERROR]: Could not pass event AsyncPlayerChatEvent to MCAuthenticator v1.1.2
org.bukkit.event.EventException
    at com.massivecraft.massivelag.inject.event.MassiveLagEventExecutor.execute(MassiveLagEventExecutor.java:80) ~[?:?]
    at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[patched_1.10.2.jar:git-Paper-842]
    at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:517) [patched_1.10.2.jar:git-Paper-842]
    at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:499) [patched_1.10.2.jar:git-Paper-842]
    at net.minecraft.server.v1_10_R1.PlayerConnection.chat(PlayerConnection.java:1304) [patched_1.10.2.jar:git-Paper-842]
    at net.minecraft.server.v1_10_R1.PlayerConnection.a(PlayerConnection.java:1219) [patched_1.10.2.jar:git-Paper-842]
    at net.minecraft.server.v1_10_R1.PacketPlayInChat$1.run(PacketPlayInChat.java:39) [patched_1.10.2.jar:git-Paper-842]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_91]
    at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_91]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_91]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_91]
    at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91]
Caused by: java.lang.NullPointerException
    at com.aaomidi.mcauthenticator.engine.events.ChatEvent.onPlayerChat(ChatEvent.java:31) ~[?:?]
    at sun.reflect.GeneratedMethodAccessor615.invoke(Unknown Source) ~[?:?]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
    at com.massivecraft.massivelag.inject.event.MassiveLagEventExecutor.execute(MassiveLagEventExecutor.java:63) ~[?:?]
    ... 11 more

Add commands passthrough withelist

Hi!

Could you add a configuration option to let some commands pass through even if the user is not authenticated? Something with regex would be neat.

Thanks a lot

Authentication Code Issues

We are attempting to use McAuthenticator, and are attempting to use Google Authenticator. After entering the passcode, we get "That was not a valid code. Your are not authenticated."

cannot reset a staffs auth

a staff member got a new phone, and I cannot reset their auth, it says they are already in reset mode, but they dont get a new map or link, it just asks for their code

Entering Auth Code Issue

When you enter the six digit code with a space, as it's displayed to you in Google Authenticator, it doesn't authenticate you. Could you fix that? That would be awesome :)

Idea für %player% and %code% and %url%

Hello

I do not now each shortcode and would like to have a information for where %player% and the others could used. As well would i recommand to ad the possibility to vrote a warm welcome message like
Hello %player% Welcome on our Server. You have sucessfully authenticated!

I does not now if that is possible but i would like it.

EDIT:

A URL like goo.gl/asdf1234 would be nice, istat of www.google.com/long-url-from-chat-min-3-lines-long

Greatings,

calgia

Bungeecord Issue

Hi, i'm italian (sorry for my bad english), i tested it in a spigot player and it worked !
Than i deleted from my spigot server, and putted it in the bungee, when i logged in the server i wasn't able to wright anything ... Can you help me? 👍

Login sequence hang when attempting to log in

I am currently running PaperSpigot 1.7 (1.7/1.8 Protocol Hack) and I was unable to test this plugin out. When I was not op, I was able to login and everything would be fine. However, when I op'd myself and tried to log back in, it would show "Downloading Terrain" for a few seconds and then say "Timed out". I tried resetting all my server configs but the issue still persisted.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.