[ADMN/WEB] OKB3 - Bulletin Board Bridge - Now on BukkitDev! [1337]

Discussion in 'Inactive/Unsupported Plugins' started by Kalman Olah, Jun 2, 2011.

  1. Offline

    Kalman Olah

  2. Offline

    NeatMonster

    Many thanks Kalman Olah, and Mike too ;)!

    For sure. Subgroups is the only missing functionality of this plugin.

    Edit: Same timezone :p (I'm French).
    Re-Edit: Yes, you really need to sleep. The config file isn't created properly :D.

    Show Spoiler
    Code:
    enable-old-school-mode: false
    ? '###In old school mode, the server does NOT check a username/password! It just gets
        a rank from your forum DB and sets it as your group###'
    : ''
    ? '###If enable-old-school-mode is set to true, fill in the section labeled ''old-school-mode''
        If not, fill in the section labeled ''normal-mode'''
    : ''
    enable-multiple-tables: false
    '###If enable-multiple-tables is set to false, ''multitable'' parts will not be loaded###': ''
    enable-whitelist: false
    '###If enable-whitelist is set to true, fill in ''whitelist-groups''(''RANK ID'': true)###': ''
    '###Rank-based whitelisting only works when enable-old-school-mode is set to true': ''
    mysql-connection-info:
        mysql-host: localhost
        mysql-user: root
        mysql-password: password
        mysql-database-name: database
    info:
        old-school-mode:
            usertable: user_table
            minecraftname-field: mine_user
            rankfield-in-table: rank_field
            multitable:
                minecraftname-table: mine_table
                useridfield-in-minecraftname-table: user_id_field
                useridfield-in-usertable: user_id_field
        normal-mode:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
            location-of-passgenphp: http://yoursite.com/passgen.php
            '###Encryption types are 1 for MD5,2 for phpBB3, 3 for SMF, 4 for vBulletin 4':
                x:
                    x, 5 for myBB, 6 for XenForo###: ''
            encryption-type-of-forum: '1'
            password-set-in-config-inc-php: 12345pass
            multitable:
                rank-table: rank_table
                useridfield-in-usertable: user_id_field
                useridfield-in-ranktable: user_id_field_in_rank_table
    groups:
        '###''RANKID IN RANKTABLE''=GROUPMANAGER GROUP###': ''
        '1': ExampleGroup1
        '2': ExampleGroup2
    whitelist:
        kick-message: This is the message a user will see if their group isn't whitelisted.
        whitelist-groups:
            '###''''RANKID IN RANKTABLE'': true'' TO ALLOW A RANK TO JOIN###': ''
            '###''''RANKID IN RANKTABLE'': false'' TO NOT ALLOW A RANK TO JOIN###': ''
            '1': 'true'
            '657': 'false'
    

    Re-Re-Edit: System will not work with my XenForo installation because I've three tables. First, the user account name must be verified in the xf_user_identity table (account_name field) and this table will give the user id (user_id field). Then, with the user id (user_id field), BBB must check the password (data or remember_key field) in the xf_user_authentificate table. If the password is good, BBB can check the user group id (user_group_id field) in the xf_user table. I know this is complex. For more difficulty, the subgroups IDs are stocked in the secondary_group_ids.

    Because I'm French and you're Belgian, because I'm speaking English very well and because I think you're speaking French, I'll say it in French too.

    (L'auteur ne parle pas français, déroulez ce spoiler si vous parlez français :p.)
    Français (open)
    Ton système ne fonctionne pas avec mon installation XenForo. En effet, mon système actuel utilise trois tables (xf_user_identity, xf_user_authentificate et xf_user). Pour fonctionner, BBB devrait procéder en trois étapes.
    1. Pour vérifier que le nom d'utilisateur existe, il devrait aller voir dans la table xf_user_identity, où est stocké ce nom d'utilisateur (cette table correspond aux champs de profil spéciaux, en effet XenForo est capable de vérifier que le nom d'utilisateur existe sur Minecraf.net). Le champ à tester se nomme account_name et BBB pour ainsi récupérer l'ID de l'utilisateur, stocké dans le champ user_id ;
    2. Ensuite, il faut vérifier le mot de passe entré par l'utilisateur. Pour cela, la table xf_user_authentificate doit être utilisée. Le mot de passe se vérifie grâce à l'ID de l'utilisateur (user_id) et le mot de passe stocké sur le forum est dans le champ data ou remember_key, je ne sais pas vraiment lequel des deux.
    3. Une fois le mot de passe vérifié, il n'a plus qu'à récupérer l'ID du groupe de l'utilisateur, stocké dans le table xf_user, en se servant de l'ID de l'utilisateur (user_id) et retourné par le champ user_group_id. Il y a encore moyen de faire plus compliqué, les IDs des sous-groupes de l'utilisateur sont stockés dans le champ secondary_group_ids.
    Mais comme les paroles ne suffisent pas, je vais poster dans ce sujet des captures d'écran de phpMyAdmin. Merci d'avance pour ton magnifique travail :).


    Re-Re-Re-Edit: The screenshots are here!
    [​IMG]
    [​IMG]
    [​IMG]
     
  3. Offline

    Jamie Tees

    You were watching ant's thread all the time. You copied the idea, I would proberly guess you copied some of the code too. I'm not accusing you of that but ... Yeah guys use ants plugin, its the original and the best!
     
  4. Offline

    NeatMonster

    Is this forbidden ?

    Yes, he recognizes it.

    He has created this plugin for his server, and he shared it with us. Because of messages like this, some devs aren't sharing their plugins.

    Personal advice. I think this plugin is more updated and has more functionalities.

    One more time, excuse-me for my bad English.
     
  5. Offline

    Kalman Olah

    I copied zero lines of code from Ant59.

    1 - I don't speak French, I speak Dutch.

    2 - The config file is supposed to look like that, because I honestly have no clue how to add proper comments to .YML files.

    3 - In my XenForo test setup, usernames were stored in xf_user, however, I'll give it another look and update the plugin in a minute or ten.
     
  6. Offline

    NeatMonster

    So bad! :p

    Okay, I think it was an error. Sorry!

    Great! I'm waiting :D.
     
  7. Offline

    Kalman Olah

    Small question.

    Why do you need my plugin to verify the forum user's minecraft username too?
    Since the login is done by /bbb sync <forum username> <forum password> ingame, it already verifies that they own both the minecraft account, and the forum account, doesn't it?
     
  8. Offline

    NeatMonster

    I haven't thought at that. For sure you've right. I'll transfert the profile field username to the forum username. First problem solved :). But subgroups is important.
     
  9. Offline

    Kalman Olah

    XenForo in normal mode is not working because I forgot to add it to the plugin earlier :confused: .

    So yeah, go get some sleep or something, because I'm about to rewrite the plugin for the most part for better logging, easier usage and setup and general awesomeness.

    EDIT: and actual XenForo support :p

    (Subgroups feature TBA, I bet it'll be loads and loads of fun figuring subgroups out! :'()
     
  10. Offline

    NeatMonster

    Okay. I'll check this thread tomorrow. Good work, I support you :)!
     
  11. Offline

    Kingadams

    This might sound stupid but any chance on support for permissions?
     
  12. Offline

    Kalman Olah

    I don't think Permissions currently supports changing groups from inside another plugin.

    If you get GroupManager and GroupManagerBridge though, any plugin that only works with Permissions will work with GroupManager too.
     
  13. Offline

    Kingadams

    Nevermind. Ill take a look into this plugin its what we been needing... Also if we manually change someones rank like if they are vip on the forum but you want them admin on MC and you set it will it stay?
     
  14. Offline

    Kalman Olah

    In old-school mode a forum rank change is instantly applied on login, without any verification needed. This means that you can update someone's forum rank, and have the server change their GroupManager rank the next time they log in, automatically. The ranks are checked every time a player logs in.

    In normal mode a player must type the command "/bbb sync <forum username> <forum password>" to initiate their first forum rank-to-GroupManager group update. After this successful sync command, a user will be able to type "/bbb resync" to manually have the server check their forum rank(and change their GroupManager rank if their forum rank got changed) instantly, without providing credentials again. Additionally, once a successful "/bbb sync <forum username> <forum password>" has been executed for a player, their ranks will also be checked by the server on login, automatically.

    EDIT: I totally misread your question.
    Currently Bulletin Board Bridge sets the player's main GroupManager group, this means that if a user is a VIP on a forum, and the plugin is configured to assign the "Donator" GroupManager permissions group to any VIP forum user, a user that's a VIP on the forum and is in the SuperCoolAdminGuy GroupManager group before the plugin updates their ranks/groups will be moved to the "Donator" GroupManager group.
     
  15. Offline

    Kingadams

    Ok one last question

    My SQLdatabase i use for MC is not the same i use for the forums... is that ok? Do i set both database configs in the plugin folder and website to the forums?
     
  16. Offline

    Kalman Olah

    My plugin only connects to your forum database. It has no need to connect to anything else. So yes, set both of them to the forums.

    Hang on for a minute though, I'm uploading v0.3.4 as we speak.

    Updated to v0.3.4.
    Made various improvements, properly added XenForo support.
    This version is still pretty much untested. You have been warned.

    Uploaded v0.3.5.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 16, 2016
  17. Offline

    WNxRev

    So I've installed this all successfully, except when I go to type /bbb sync (forum username) (forum password), I get:

    18:49:28 [INFO] [OKB3] ****'s rank update failed.


    I'm using PHPBB3.0.8
    Latest Bukkit
    Latest version of this plugin
    Online mode
    The plugin has no errors when initializing, just when typing this command.
     
  18. Offline

    TheShadow777

    hey can you make support for woltlab burning board 3.1 !? this would be awesome :)
     
  19. Offline

    Kalman Olah

    Yeah, the latest version is broken, give me half an hour, I'm trying to fix it =).
     
  20. Offline

    WNxRev

    Oh thank god! I was screwing around with the config files for an hour...
     
  21. Offline

    Kalman Olah

    UPDATED TO v0.3.6!

    This is a mandatory update, because the previous two versions don't actually work :p.
    I'm on it.

    If it still doesn't work, post your config.yml
     
  22. Offline

    WNxRev

    Not working (My config)
    Code:
    mode: normal
    '###The mode the plugin will run in, options are ''normal'' or ''old-school''###': ''
    ? '###In old-school mode, the server does NOT check a username/password! It just gets
        a rank from your forum DB and sets it as your group###'
    : ''
    ? '###If enable-old-school-mode is set to true, fill in the section labeled ''old-school-mode''
        If not, fill in the section labeled ''normal-mode'''
    : ''
    mysql-connection-info:
        mysql-host: localhost
        mysql-user: root
        mysql-password: **********
        mysql-database-name: phpbb
    old-school-mode:
        enable-whitelist: 'false'
        '###If enable-whitelist is true, fill in the whitelist section###': ''
        usertable: user_table
        minecraftname-field: mine_user
        rank-field: rank_field
        enable-multiple-tables: false
        '###If enable-multiple-tables is true, fill in the multitable section': ''
        multitable:
            minecraftname-table: mine_table
            useridfield-in-minecraftname-table: user_id_field
            useridfield-in-usertable: user_id_field
    normal-mode:
        type-of-forum: phpbb
        ? '###Current supported forum types md5 for MD5 encryption-based forums,phpbb
            for phpBB3, smf for SMF, vbulletin for vBulletin, mybb for myBB, xenforo for
            XenForo###'
        : ''
        '###Fill in the fields for the forum type that matches your type-of-forum value': ''
        location-of-passgenphp: http://localhost/passgen.php
        password-set-in-config-inc-php: **********
        md5:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
        phpbb:
            usertable: users
            username-field: username
            userpassword-field: user_password
            rank-field: group_id
        smf:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
        vbulletin:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
        mybb:
            usertable: user_table
            username-field: username_field
            userpassword-field: user_pass_field
            rank-field: rank_field
        xenforo:
            usertable: user_table
            rank-field: rank_field
            username-field: username_field
            password-table: pass_table
            password-field: pass_field
            useridfield-in-usertable: user_id_field
            useridfield-in-passtable: user_id_field
    groups:
        '###''RANKID IN RANKTABLE''=GROUPMANAGER GROUP###': ''
        '2': User
        '8': WebAdministrator
        '9': ServerAdministrator
        '10': ServerModerator
        '11': WebModerator
        '13': Donator
        '14': Owner
    whitelist:
        kick-message: This is the message a user will see if their group isn't whitelisted.
        whitelist-groups:
            '###''''RANKID IN RANKTABLE'': true'' TO ALLOW A RANK TO JOIN###': ''
            '###''''RANKID IN RANKTABLE'': false'' TO NOT ALLOW A RANK TO JOIN###': ''
            '1': 'true'
            '657': 'false'
    
    Error on anyone's login
    Code:
    2011-06-06 20:03:15 [SEVERE] Could not pass event PLAYER_PRELOGIN to OKB3
    java.lang.NullPointerException
        at net.genericgaming.kalmanolah.okb3.OKPlayerListener.onPlayerPreLogin(OKPlayerListener.java:21)
        at org.bukkit.plugin.java.JavaPluginLoader$12.execute(JavaPluginLoader.java:320)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:310)
        at net.minecraft.server.ThreadLoginVerifier.run(ThreadLoginVerifier.java:45)
    Error when I execute /bbb sync with the correct parameters
    Code:
    2011-06-06 20:03:56 [WARNING] [OKB3-MYSQL] Error at SQL Query: Table 'phpbb.users' doesn't exist
    2011-06-06 20:03:56 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'bbb' in plugin OKB3 v0.3.6
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:37)
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:128)
        at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:281)
        at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:718)
        at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:684)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:677)
        at net.minecraft.server.Packet3Chat.a(Packet3Chat.java:32)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:217)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
        at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:399)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:309)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    Caused by: java.lang.NullPointerException
        at net.genericgaming.kalmanolah.okb3.OKCmd.onCommand(OKCmd.java:61)
        at org.bukkit.command.PluginCommand.execute(PluginCommand.java:35)
        ... 12 more


    The table prefix is phpbb_
     
  23. Offline

    Kalman Olah

    @xREVOLUT1ONZx
    Code:
        phpbb:         usertable: users         username-field: username         userpassword-field: user_password         rank-field: group_id
    
    Change this to

    Code:
    phpbb:
             usertable: phpbb_users
             username-field: username
             userpassword-field: user_password
             rank-field: user_rank
    
    EDIT: Just going to explain this.
    1 - The $sqlprefix in config.inc.php only applies to the webfiles portion of this plugin. You still need the full table names in the config.yml.
    2 - Rank IDs, not group ID. You can have many groups in phpBB, but only one rank.


    Also, 0.3.7.
     
  24. Offline

    WNxRev

    Thanks so much for the assistance. Everything is working now. :)
     
  25. Offline

    Kalman Olah

    You're welcome. If you need help again, just PM me or post in the thread =).
     
  26. Offline

    NeatMonster

    Any progress with subgroups?
     
  27. Offline

    SpeedKeks

    can you make thies vor WolterLab 3? wbb3?
     
  28. Offline

    Kalman Olah

    On it.
    On it.
    Not yet, but then again, I was busy...sleeping...and...releasing broken plugin versions...
    Hmmm, yeah...I'll check subgroups out tonight, and get back to you with:
    A - a version with subgroups.
    B - a temporary custom version with subgroups, just for you
    C - an estimate on how it long it will take
    D - a reply containing only "nope" if it's impossible

    EDIT: I just ordered a pizza. If you eat any type of fish/pineapple on your pizza, you're obviously scum. :(
     
  29. Offline

    S0mebody

    Hi. I like the sound of this, is there any chance (and no rush required) of support for IPB please?
     
  30. Offline

    NeatMonster

    I take the option B, and a tuna/mango pizza too :p.

    Edit: And please get me a Budweiser Light or two ^^. (See? I'm a real scum.)
     
  31. Offline

    Kalman Olah

    Yeah sure, I'll get that out along with support for WolterLab3(whatever that is), and woltlab burning board 3.1.
    Come to think of it, aren't those two the same thing?

    I forgot to add mango to my scumlist :p
     

Share This Page