Privileges
Privileges
Privileges seeks to be a familiar face for Permissions, and uses the Permissions 2.x format of lists of nodes for users. It offers inheritance, multi-world permissions, and promotion tracks.
This plugin is designed to implement Super perms (Bukkit Permissions). It does not provide an extensible API for permissions handler hooking, except in the form of getGroup().
by krinsdeath
Pages
- Configuration / groups.yml
- Configuration / config.yml
- Example Setup
- Commands
- Jenkins / Github 5.1. Use of the plugin builds from Jenkins is unofficial, unsupported and unapproved by BukkitDev Staff!
Features
- Multi-world compatible permissions management, with a familiar interface.
- Easy-to-use, powerful, and accurate inheritance.
- Promotion ladders and tracks through group ranks.
- Anti-build with permissions nodes
privileges.build
andprivileges.interact
. - Expanded anti-build permissions with
privileges.interact.[block id]
, to prevent interaction on a block-by-block basis. - Extremely powerful command system!
- Incredibly light-weight registration of players. Thousands of nodes can be applied in only a few millionths of a second.
- Plugin Metrics! Privileges reports the total number of groups and users registered in its config files to mcstats.org. This data is 100% anonymous and is only used for informational purposes. You can disable this in config.yml by changing
plugin.metrics: false
Commands
- /priv - Top level command. Does nothing.
- /priv check [player] [node] - Checks the specified node for the specified player. If player is omitted, checks your own nodes.
- /priv list [player] [page] - Lists the specified player's permissions nodes. If player is omitted, lists your own nodes. 7 nodes are listed per page.
- /priv reload - Saves Privileges' currently loaded configuration to disk and reloads all files.
- /priv save - Saves Privileges' currently loaded configuration to disk.
- /priv load - Unloads current configurations and loads from the disk - used to pick up external file changes.
- /priv backup [name] - Creates a configuration snapshot including users and groups, and saves it to a directory: privbackup/[name].
- /priv restore [name] - Restores the specified configuration snapshot.
- /priv version - Shows Privileges' current version and build numbers.
- /priv group [option] - Top level 'group' command
- * /priv group create [name] [rank] - Creates a group with the specified name and rank. If your current rank is equal to or lower than the rank you specify, the command will fail.
- * /priv group remove [name] [--safe] - Removes the specified group. If your rank is lower than the target group's rank, the command fails. If --safe is specified, the command will attempt to remove all references to the group from all users (and set them to your default group), and remove the group from all inheritance references as well.
- * /priv group set [player] [group] - Attempts to set the specified player's group to the specified group. If the target group's rank is equal to or higher than the command sender's rank, the command fails.
- * /priv group show [player] - Shows the sender the specified player's group.
- * /priv group list - Lists the available groups and their ranks.
- * /priv group perm - Top level 'group permission' command
- * * /priv group perm set [group] [node] [true|false] - Attempts to set the specified node to the specified value for the specified group. Fails if you don't have a higher rank setting than the target group.
- * * /priv group perm remove [group] [node] - Attempts to remove the node specified from the group. Fails if your rank is not higher than the target group.
- /priv user perm [option] - Top level 'user permission' command
- * /priv user perm remove [player] [node] - Removes the node specified from the target player.
- * /priv user perm set [player] [node] [true|false] - Sets the specified node to the value for the target player.
- * /priv user reset [player] - Resets the specified user to the default group and erases any individual permissions.
more commands will be added as I think of them
Permissions
- privileges.interact (defaults true) - Allows the player to interact with objects like buttons and switches
- privileges.build (defaults true) - Allows the player to break/place blocks
- Base commands
- * privileges.reload - /priv reload
- * privileges.save - /priv save
- * privileges.load - /priv load
- * privileges.backup - /priv backup [name]
- * privileges.restore - /priv restore [name]
- * privileges.version - /priv version
- * privileges.debug - /priv debug
- Administrative
- * privileges.promote - /promote [player]
- * privileges.demote - /demote [player]
- * privileges.check - /pc [player] [node]
- * privileges.list - /priv list [player] [page]
- * privileges.info - /priv info [player]
- Group base commands
- * privileges.group.create - /pgc [group] [rank]
- * privileges.group.remove - /pgr [group] [--safe]
- * privileges.group.set - /pgs [player] [group]
- * privileges.group.show - /pg show [player]
- * privileges.group.list - /pg list
- Group permissions commands
- * privileges.group.perm.set - /pgps [group] [node] [true|false]
- * privileges.group.perm.remove - /pgpr [group] [node]
- User permissions commands
- * privileges.user.perm.remove - /pupr [player] [node]
- * privileges.user.perm.set - /pups [player] [node] [true|false]
- * privileges.user.reset - /pur [player]
Special thanks
- gravypod - Small performance tweaks and optimizations. Thanks a bunch!
- Wolvereness - Massive improvement to node registration performance through templating. Keep on keepin' on!
nhadobas:
/pgs user group
will set that user's group to the specified group and assign all permissions associated with the group.The command you listed
/pups user permission.node
is used to assign a specific (single) node to a specific (single) user. The equivalent command for a group is/pgps group permission.node
.@krinsdeath
Does doing /priv user perm set {user} rank.{rank} give them the permissions for that rank?
None of my plugins should break between versions of Minecraft anymore. If there are bugs, report them to me on my ticket tracker, and I can investigate. An error log, the version of Bukkit, the version of the plugin, and what you were doing when the error occurred are all necessary for me to find and fix the issues.
@jaredfam
Yes. Download the latest build from jenkins.
Does it work with 1.6.2?
@rosten99
The default group is the group that people are automatically set to when they first join. You need to go to config.yml and set "default_group:" to a group that exists in your groups.yml. This is my config as an example. It sets brand new players to a group called "Guest" that exists in the group.yml.
Ok so i figured out how to promote people but when i try it says "An invalid default group is defined in config.yml." whats wrong? Please Help
I know this is a stupid question but how do i add people to a group i looked through everything but i cant figure it out i went into the user.yml file and did what i think was correct but it still doesnt work PLEASE HELP!
Anyone knows a good chat plugin that works with towny together? And that adds prefixes/suffixes? I can't find one that is really compatible to towny chat.
@krinsdeath
Thank you, done :) I also grabbed the copy off your jenkins and it seems to work fine!
@jack588
You add those using another plugin that uses prefix/suffix. A perms plugin adding prefix/suffix isn't the standard anymore nowadays and most chat plugins are able to do it.
how to add prefix and suffix with townychat as chat manager?
Brottweiler: I'm currently using LWC's jenkins, and he's doing some migrations to new file systems and such. In lieu of his jenkins absence and the fact that I'm a no-good moocher, I'm migrating to my own machine: http://ci.krincraft.net/
Thyrin: I have two weeks of holiday, so I'll try to get some feature requests done over the break. Can you put in a ticket on my tracker (for changelog purposes)?
@krinsdeath
The config flag would be very much appreciated. I run a big server network and the amount of users can ramp up quickly (and unnecessarily) :).
You know your Jenkins page 404's right?
@LordKainzo
Maybe because multiple groups is not supported? it is quite a pain to do that.
@krinsdeath
I cant say for sure why it's happening at all. Is there any planned support for a user having multiple groups? I tried setting multiple groups but it didnt work at all.
Thanks for this plugin!!!! Works perfect!, seriously, this saved me 5 bucks i was going to offer to someone who fix my permissions, but then i find this and voilĂ , i tried with PEX, Bpermissions, PermissionsBukkit, GroupManager, YAPP, the list goes on....
I couldn't find a donation link, but sure would worth it.
Keep the good job ;)
EDawg878 & Puremin0rez: I'll work on making a config flag to set whether or not to persist default users. I did this because other plugins often do not, and I saw a lot of comments on those plugins about "how do I format a user's groups?" and questions like that. This fixes that problem. I don't have time to answer questions like that. :P
Anyway, I'll add a config flag.
@EDawg878
I agree, my entire file consists of nothing but default which seems a little pointless.
krinsdeath,
I have been using Privileges on my server for a while now. My plugins natively interact with Privileges but there has been a problem where the server stalls for a few seconds after using privs.saveUsers() and then privs.reload() for the new permissions to take effect. This occurs even with the new async feature in your most recent build. I realize that my users file is huge since I am running a 500+ player server there are over 20,000 lines (1.5 MB) this is even with the users_cleanup option enabled. I am wondering why Privileges needs to save the users in the default group with no special permissons. Most of my users file is filled up with the following:
I see no reason why this information must be stored in the file, is it possible for you to implement a cleanup feature for default users like this? Any suggestions?
EDIT: Okay I've realized that a custom solution is better in my case. I ended up making my own permissions plugin instead, thanks though.