Skip to content

feedback: Access control | Tarantool #5070

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

Open
TarantoolBot opened this issue Apr 9, 2025 · 0 comments
Open

feedback: Access control | Tarantool #5070

TarantoolBot opened this issue Apr 9, 2025 · 0 comments

Comments

@TarantoolBot
Copy link
Collaborator

TarantoolBot commented Apr 9, 2025

<…>ox.schema.user.grant('testuser', 'write', 'space', '_priv')

**|Executing code
To let testuser execute Lua code, grant the execute privilege to the lua_eval object:
box.schema.user.grant('testuser','execute','lua_eval')

Similarly, executing an arbitrary SQL expression requires the execute privilege to the sql object:
box.schema.user.grant('testuser','execute','sql')

|Example**
In the example below, the created Lua function is execut<…>

https://www.tarantool.io/en/doc/latest/admin/access_control/

Please mention explicitly that only 'admin' user can grant 'execute' privilege on 'lua_eval', 'lua_call', 'sql', 'universe'.

Generally speaking, any non-admin user, even the one having a 'super' privilege, cannot grant any privilege for an object that this user doesn't own. No one, except admin, "owns" 'lua_eval', 'lua_call', 'sql', 'universe' and so on.

This also means non-admin 'super' user cannot grant access to spaces (or functions or any other type of object) he hasn't created:

tarantool> _ = box.schema.space.create('test')
---
...

tarantool> box.schema.user.create('tester')
---
...

tarantool> box.schema.user.grant('tester', 'super')
---
...

tarantool> box.session.su('tester')
---
...

tarantool> box.schema.user.grant('guest', 'read', 'space', 'test')
---
- error: Grant access to space 'test' is denied for user 'tester'
...

tarantool> 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant