Skip to content

Permissions

HENRY Thibault (Kazź) edited this page Apr 4, 2021 · 19 revisions

Cosmos Logo

Last update: April 4, 2021

What are permissions ?

Permissions are used to determine whether a player can or cannot do a specific action on your server. A permission is structured as case-insensitive string key which is separated in parts using the dot character :

<PluginID>.<MainGroup>.<Subgroup1>...

Sponge provides a complete permission structure for Minecraft that you can use to allow player to use vanilla commands.

Recommanded permissions plugin

Cosmos permission system has been fully tested and approved with Luckperms plugin which is the most used Sponge permission plugin.

However, Cosmos should be working fine with any permission plugins designed for Sponge.

Sponge permissions behavior

Sponge has a quite different behavior for permissions than have Spigot, Paper... Indeed it provides implicit inheritance between differents parts that compose a single permission.

For example, as cosmos permission contains every sub permissions in Cosmos structure (see next section), like cosmos.commands or cosmos.modules. It means that giving this permission to a player will grant him full access to Cosmos plugin without having to use a wildcard like cosmos.*.

With Minecraft example, giving minecraft.command permission will allow player to use every vanilla commands because they all have this root part in permission.

Sponge also gives the ability to negate a permission, by setting it to false.

Cosmos permissions structure

To comprehend Cosmos permissions structure, you can visualize it as a directory explorer where folders represent Cosmos modules and files represents Cosmos commands.

Thus, to grant player access to a specific command, you have to give him access to the corresponding file and to all the upper folder where the file is nested into including the equivalent-level root folder to work.

If you did not get how the magic works, be aware that required permissions for any command are listed in the command section.

Click onto to extend

Cosmos Permissions Graph

Examples :

  • Help command

As the command is stored inside the root module, you do not need an extra access to the equivalent-level root module, because it is the desired module itself. Therefore, to give access to the help command, grant these two permissions:

cosmos.modules.root

cosmos.commands.root.help

  • Border information command

Here, the command is stored inside the border module. You need extra access to the equivalent-level root module. Therefore, to give access to the border information command, grant these three permissions:

cosmos.modules.root

cosmos.modules.border

cosmos.commands.border.information

  • Scoreboard players list command

Here, the command is stored inside the player module, which is nested into the scoreboard module. You need extra access to the equivalent-level root modules of both player and scoreboard modules. Therefore, to give access to the scoreboard players list command, grant these five permissions:

cosmos.modules.root

cosmos.modules.scoreboard

cosmos.modules.scoreboard.root

cosmos.modules.scoreboard.players

cosmos.commands.scoreboard.players.list

  • All commands of time module

Here, the commands are stored inside the time module. You need extra access to the equivalent-level root module. Therefore, to give access to the all commands of the time module, grant these three permissions:

cosmos.modules.root

cosmos.modules.time

cosmos.commands.time (no * wildcard, see Sponge permissions inheritance)

  • All commands of time module without forecast command

As Sponge gives us the possibility to negate a permission, you can deny access to only one (or more) commands. It can be useful to allow almost all commands of a huge module.

Here, the commands are stored inside the time module. You need extra access to the equivalent-level root module. Therefore, to give access to the all commands of the time module without forecast command, grant/revoke these four permissions:

cosmos.modules.roottrue

cosmos.modules.timetrue

cosmos.commands.timetrue

cosmos.commands.time.forecastfalse

Permissions list

The following table contains all the permissions available in Cosmos

Module Permission Description
backup cosmos.commands.backup.delete Allow delete command usage
backup cosmos.commands.backup.list Allow list command usage
backup cosmos.commands.backup.reset Allow reset command usage
backup cosmos.commands.backup.restore Allow restore command usage
backup cosmos.commands.backup.save Allow save command usage
backup cosmos.commands.backup.tag Allow tag command usage
border cosmos.commands.border.center Allow center command usage
border cosmos.commands.border.damageamount Allow damageamount command usage
border cosmos.commands.border.damagethreshold Allow damagethreshold command usage
border cosmos.commands.border.information Allow information command usage
border cosmos.commands.border.operate Allow operate command usage
border cosmos.commands.border.remove Allow remove command usage
border cosmos.commands.border.size Allow size command usage
border cosmos.commands.border.transpose Allow transpose command usage
border cosmos.commands.border.warningdistance Allow warningdistance command usage
border cosmos.commands.border.warningtime Allow warningtime command usage
perworld cosmos.commands.perworld.bypass Allow bypass command usage
perworld cosmos.commands.perworld.group Allow group command usage
perworld cosmos.commands.perworld.information Allow information command usage
perworld cosmos.commands.perworld.toggle Allow toggle command usage
properties cosmos.commands.properties.allowcommandblocks Allow allowcommandblocks command usage
properties cosmos.commands.properties.difficulty Allow difficulty command usage
properties cosmos.commands.properties.enablestructures Allow enablestructures command usage
properties cosmos.commands.properties.gamemode Allow gamemode command usage
properties cosmos.commands.properties.generatespawnonload Allow generatespawnonload command usage
properties cosmos.commands.properties.generatortype Allow generatortype command usage
properties cosmos.commands.properties.hardcore Allow hardcore command usage
properties cosmos.commands.properties.keepspawnloaded Allow keepspawnloaded command usage
properties cosmos.commands.properties.loadonstartup Allow loadonstartup command usage
properties cosmos.commands.properties.pvp Allow pvp command usage
properties cosmos.commands.properties.rules Allow rules command usage
properties cosmos.commands.properties.seed Allow seed command usage
properties cosmos.commands.properties.spawnposition Allow spawnposition command usage
root cosmos.commands.root.delete Allow delete command usage
root cosmos.commands.root.disable Allow disable command usage
root cosmos.commands.root.duplicate Allow duplicate command usage
root cosmos.commands.root.enable Allow enable command usage
root cosmos.commands.root.help Allow help command usage
root cosmos.commands.root.import Allow import command usage
root cosmos.commands.root.information Allow information command usage
root cosmos.commands.root.list Allow list command usage
root cosmos.commands.root.load Allow load command usage
root cosmos.commands.root.move Allow move command usage
root cosmos.commands.root.moveto Allow moveto command usage
root cosmos.commands.root.new Allow new command usage
root cosmos.commands.root.perworld Allow perworld command usage (removed in 1.1.0)
root cosmos.commands.root.position Allow position command usage
root cosmos.commands.root.rename Allow rename command usage
root cosmos.commands.root.unload Allow unload command usage
root cosmos.commands.root.viewdistance Allow viewdistance command usage
objectives cosmos.commands.scoreboard.objectives.add Allow add command usage
objectives cosmos.commands.scoreboard.objectives.list Allow list command usage
objectives cosmos.commands.scoreboard.objectives.modify Allow modify command usage
objectives cosmos.commands.scoreboard.objectives.remove Allow remove command usage
objectives cosmos.commands.scoreboard.objectives.setdisplay Allow setdisplay command usage
players cosmos.commands.scoreboard.players.add Allow add command usage
players cosmos.commands.scoreboard.players.get Allow get command usage
players cosmos.commands.scoreboard.players.list Allow list command usage
players cosmos.commands.scoreboard.players.operation Allow operation command usage
players cosmos.commands.scoreboard.players.random Allow random command usage
players cosmos.commands.scoreboard.players.remove Allow remove command usage
players cosmos.commands.scoreboard.players.reset Allow reset command usage
players cosmos.commands.scoreboard.players.set Allow set command usage
players cosmos.commands.scoreboard.players.test Allow test command usage
teams cosmos.commands.scoreboard.teams.add Allow add command usage
teams cosmos.commands.scoreboard.teams.empty Allow empty command usage
teams cosmos.commands.scoreboard.teams.join Allow join command usage
teams cosmos.commands.scoreboard.teams.leave Allow leave command usage
teams cosmos.commands.scoreboard.teams.list Allow list command usage
teams cosmos.commands.scoreboard.teams.option Allow option command usage
teams cosmos.commands.scoreboard.teams.remove Allow remove command usage
time cosmos.commands.time.calendar Allow calendar command usage
time cosmos.commands.time.dawn Allow dawn command usage
time cosmos.commands.time.dusk Allow dusk command usage
time cosmos.commands.time.ignoreplayerssleeping Allow ignoreplayerssleeping command usage
time cosmos.commands.time.midday Allow midday command usage
time cosmos.commands.time.midnight Allow midnight command usage
time cosmos.commands.time.realtime Allow realtime command usage
time cosmos.commands.time.set Allow set command usage
time cosmos.commands.time.tomorrow Allow tomorrow command usage
weather cosmos.commands.weather.forecast Allow forecast command usage
weather cosmos.commands.weather.rain Allow rain command usage
weather cosmos.commands.weather.sun Allow sun command usage
weather cosmos.commands.weather.thunder Allow thunder command usage
cosmos.modules.backup Allow access to backup module
cosmos.modules.border Allow access to border module
cosmos.modules.perworld Allow access to perworld module
cosmos.modules.properties Allow access to properties module
cosmos.modules.root Allow access to root module
cosmos.modules.scoreboard Allow access to scoreboard module
cosmos.modules.scoreboard.objectives Allow access to objectives module
cosmos.modules.scoreboard.players Allow access to players module
cosmos.modules.scoreboard.players.root Allow access to players root module
cosmos.modules.scoreboard.root Allow access to scoreboard root module
cosmos.modules.scoreboard.teams Allow access to teams module
cosmos.modules.time Allow access to time module
cosmos.modules.weather Allow access to weather module