Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add description of privileges #12021

Merged
merged 5 commits into from
Jun 15, 2022
Merged

Add description of privileges #12021

merged 5 commits into from
Jun 15, 2022

Conversation

x2048
Copy link
Contributor

@x2048 x2048 commented Jan 30, 2022

This PR adds a section about privileges to lua_api.txt, describing how to register and check for privileges and the meaning of the built-in privileges.

This PR is Ready for Review.

@Wuzzy2
Copy link
Contributor

Wuzzy2 commented Jan 30, 2022

Isn't this like super redundant? And even we ignore that, I think this is better put in a separate document.

@lhofhansl
Copy link
Contributor

@Wuzzy2 Redundant with what? Seems fine with me to add it here.

@Wuzzy2
Copy link
Contributor

Wuzzy2 commented Feb 24, 2022

Redundant with /help privs

@Desour
Copy link
Member

Desour commented Feb 24, 2022

The names of all privs (and also chatcommands) defined by the engine (in C++ or builtin) should be listed, with a reference to the output of the help chatcommand, IMO.
Or, actually the ingame help text is not detailed enough, as it doesn't list everything that one can do with a priv, so they should be documented in detail somewhere, I don't care whether here or in another document.

(I didn't know (or forgot) that /help privs existed. Good that I do now, heh.)

This PR is missing some details about privileges in general. Ie.:

  • Who can see what privs a player has?
  • How far one can trust privs (ie. that players can be impersonated while they are on the server).
  • Where the engine checks privs maybe. (Ie. whether a mod has to check the privs in a chatcommand def itself or if it's just for stylistic stuff (well, ok, that's more something for the chatcommand def doc).)
  • Some information about the auth handler maybe.

(I'm probably requesting too much here, sorry.)

@x2048
Copy link
Contributor Author

x2048 commented Feb 24, 2022

@Wuzzy2 The purpose here is to describe privileges as a feature in Minetest engine, just like e.g. drawtypes or texture modifiers.

I'll move the list of the built-in privileges to the end of the section, so that it does not cause confusion.

doc/lua_api.txt Show resolved Hide resolved
doc/lua_api.txt Show resolved Hide resolved
doc/lua_api.txt Outdated Show resolved Hide resolved
doc/lua_api.txt Outdated Show resolved Hide resolved
doc/lua_api.txt Outdated Show resolved Hide resolved
doc/lua_api.txt Outdated Show resolved Hide resolved
x2048 and others added 2 commits June 8, 2022 19:42
@Zughy
Copy link
Member

Zughy commented Jun 12, 2022

@x2048 reminder about other sfan's comments to take care of 👁️

@Zughy Zughy added the Action / change needed Code still needs changes (PR) / more information requested (Issues) label Jun 12, 2022
@x2048
Copy link
Contributor Author

x2048 commented Jun 12, 2022

Not forgotten. Thanks :)

@x2048 x2048 removed the Action / change needed Code still needs changes (PR) / more information requested (Issues) label Jun 14, 2022
@x2048 x2048 merged commit 0530ec1 into minetest:master Jun 15, 2022
@x2048 x2048 deleted the privs branch November 4, 2022 20:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants