Discord2FA icon

Discord2FA -----

Two factor authentication plugin with Discord!



[​IMG]
[​IMG]


Hello!
Discord2FA is a plugin that protect your players from malicious people.
Players added to the verification list are taken into check state when they join the game and plugin sent the auth code to the specified Discord user.

Bot setup
  1. Create a new application at https://discordapp.com/developers/applications/
  2. On the application's page, go to the Bot tab, click Add Bot, and confirm.
  3. Enable the SERVER MEMBERS INTENT option under Privileged Gateway Intents on the bot tab as well.
  4. Click copy button under Token on the bot tab.
  5. Stop your server, and install the plugin then open configuration file.
  6. Paste the bot token you copied earlier into the bot-token value.
  7. Click here and paste your bot's Client ID value to the page.
  8. Done! you're now created & invited a new bot and installed the plugin. You can configurie all settings in configuration file.
Intended usage
Firstly, you need add the player you want to add to the verification list.

How can I add?
  1. You need player's Discord ID.
  2. Use, /discord2fa addToVerifyList <player> <discord id of player>
  3. That's all, when the player join the game, player will have to auth his account with Discord.
Setting directory: User settings/Appearance/Advanced/Developer mode
[​IMG]
[​IMG]
[​IMG]

Tutorial video by ServerMiner


How will the player Auth?
The player must use /auth <code> command for authentication.

How can I remove the player from verification list?
If you want to remove the player from verification list, Use /discord2fa removeFromVerifyList <player>

How can I see verification list?
You can see the verify list with using /discord2fa verifyList

How can I generate back up codes?
You can generate back up codes with using /discord2fa generateBackupCodes <player>
Warning:
If the back up codes generated before, old codes will be deleted.

More than!
  1. AuthMe (value in the config: authme-support)
  2. LoginSecurity (value in the config: loginsecurity-support)

  1. /discord2fa addToVerifyList <player> <discord id of player>
  2. /discord2fa removeFromVerifyList <player> <discord id of player>
  3. /discord2fa generateBackupCodes <player>
  4. /discord2fa verifyList
  5. /discord2fa removeFromCheck <player>
  6. /discord2fa reloadConfig
  7. /auth <code>
  8. /discord2fa enable
  9. /discord2fa disable

Code (YAML):
mysql:
  enabled
: false
  host
: localhost
  port
: 3306
  database
: minecraft
  username
: root
  password
: 1234
  use-ssl
: true

bot-token
: Your token here.

bot-activity
:
  enabled
: false
  type
: DEFAULT
  value
: 'Minecraft'

auth-countdown
: 60
number-of-rights
: 5
rights-reached-console-command
: 'tempban %player% 20m 2FA Failed'
check-for-updates
: true
generate-new-code-always
: true
auto-verification
: true

code-lenght
: 6
code-type
: NUMERIC

authme-support
: true
loginsecurity-support
: false

authentication-for-players
:
  enabled
: false
  confirm-your-account
: '> Hey! ` %player%` is trying to open 2FA! Is this you?%nl%> If you are this player please confirm yourself by pasting the code below into the chat.%nl%> Confirmation code: **%code%**'
  successfully-confirmed
: '> 2FA successfully enabled!'

logs
:
  enabled
: true
  player-authenticated
: '> %player%''s account was authenticated.'
  player-entered-wrong-code
: '> %player% entered wrong code! Left rights: %left%'
  player-reached-limit
: '> %player% reached the right limit!'
  admin-ids
:
   - 324289979188510730

canceled-events
:
  command-use
:
    cancel
: true
    whitelisted-commands
:
     - auth
  item-drop
:
    cancel
: true
    whitelisted-materials
:
     - STONE
  block-break
:
    cancel
: true
    whitelisted-blocks
:
     - STONE
  block-place
:
    cancel
: true
    whitelisted-blocks
:
     - STONE
  chat-use
:
    cancel
: true
    whitelisted-words
:
     - Hello
  inventory-click
:
    cancel
: true
    whitelisted-materials
:
     - STONE
  player-interact
:
    cancel
: true
    whitelisted-actions
:
     - PHYSICAL
  inventory-open
:
    cancel
: true
    whitelisted-inventory-types
:
     - ANVIL

messages
:
  auto-verify-success-message
: '&8&l- &6Automatic verification successful!'
  discord-message
: 'Your auth code : %code%'
  kick-message
: '&cYou are kicked from the server because &fauth countdown time &cis reached! &cLeft rights&8:&f %rights%'
  msg-send-failed
: '&8&l- &6Error while sending message to your Discord!'
  auth-message
:
    format-1
: ' %nl%
    &8&l- &f&lHEY! &6You must be authenticated to connect!
    %nl% %nl%
    &8&l- &6We are sent a code, please check your discord direct messages!.
    %nl%
    &8&l- &6If the code has not been sent,check your direct message settings and try again.
    %nl%
    &8&l- &6/auth <code> &6to authenticate yourself.
    %nl%
    &8&l- &6You have %countdown% seconds!
    %nl%'
    format-2
: ' %nl%
    &8&l- &f&lHEY! &6You must be authenticated to connect!
      %nl% %nl%
    &8&l- &6We are sent a code, please check your discord direct messages!.
    %nl%
    &8&l- &6If the code has not been sent,check your direct message settings and try again.
    %nl%
    &8&l- &6/auth <code> &6to authenticate yourself.
    %nl%
    &8&l- &f %seconds% left!
    %nl%'
  auth-command
:
    help-message
: '&8&l- &6/auth <code>'
    already-verified-message
: '&8&l- &6Your connect already verified!'
    invalid-code-message
: '&8&l- &6Invalid code,Left rights:&f %rights%'
    auth-success-message
: '&8&l- &6Successfully authenticated with your Discord account. Thanks for keeping your account secure.'
    backup-code-used
: '&8&l- &6You have used a backup code!'
  discord2fa-command
:
    help-message
: '
    &8&m --------------------
    %nl%
    &6&lDiscord2FA&8&l -&f&l Help
    %nl% %nl%
    &6Commands
:
    %nl%
    &f/discord2fa enable
    %nl%
    &f/discord2fa disable
    %nl%
    &f/discord2fa addToVerifyList <player> <discord id >
    %nl%
    &f/discord2fa removeFromVerifyList <player> <discord id >
    %nl%
    &f/discord2fa verifyList
    %nl%
    &f/discord2fa removeFromCheck <player >
    %nl%
    &f/discord2fa generateBackupCodes <player >
    %nl%
    &f/discord2fa reloadConfig
    %nl% %nl%
    &8&m --------------------'
    verifyList-message
: ' &6&lVerify List&8 : &f%list% '
    player-auth-enter-discord
: '&8&l- &6Please enter your Discord in the following format &fName #Discrimintator'
    player-auth-confirm-code-sent
: '&8&l- &6Please check your Discord direct messages! (direct messages must be enabled! )'
    player-auth-timeout
: '&8&l- &6Confirmation timeout.'
    player-auth-discord-acc-not-found
: '&8&l- &6We cannot find such a Discord user.'
    player-auth-enabled
: '&8&l- &62FA successfully enabled!'
    player-auth-already-enabled
: '&8&l- &62FA already enabled!'
    player-auth-disabled
: '&8&l- &62FA disabled!'
    player-auth-already-disabled
: '&8&l- &62FA already disabled!'
    invalid-discord-id
: '&8&l- &6Invalid Discord ID.'
    backup-codes-generated
: '&8&l- &6Backup codes was generated for &f %player%&6 Codes: &f%codes%'
    added-to-verifyList-message
: '&8&l- &f %player% &6successfully added to verify list with discord id &f%id%.'
    removed-from-verifyList-message
: '&8&l- &f %player% &6successfully removed from verify list with discord id &f%id%.'
    reload-success
: '&aReload success!'
  event-messages
:
    command-use-message
: '&8&l-&6 Please verify your login firstly for use a command!'
    item-drop-message
: '&8&l-&6 Please verify your login firstly for drop a item!'
    block-break-message
: '&8&l-&6 Please verify your login firstly for break a block!'
    block-place-message
: '&8&l-&6 Please verify your login firstly for place a block!'
    chat-use-message
: '&8&l-&6 Please verify your login firstly for use the chat!'

  1. /discord2fa -> discord2fa.admin
  2. /auth -> No permission, player can use this command when if in the check state.

[​IMG]

[​IMG]
[
[​IMG]

[​IMG]

[​IMG]

[​IMG]
[​IMG]

[​IMG]

[​IMG]
[​IMG]

Servers using Discord2FA
  • SkyCraft: Skycraft.es (Spanish)
Contact
  • Discord: Umut Erarslan#8378
[​IMG]
Resource Information
Author:
----------
Total Downloads: 11,521
First Release: Feb 23, 2020
Last Update: Dec 2, 2023
Category: ---------------
All-Time Rating:
41 ratings
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings