Skip to content

Add functions to close sessions by privelegies #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

giantpanda9
Copy link

@giantpanda9 giantpanda9 commented Nov 29, 2022

  • Add functions support functions (protected) to provide information about session owner, and user privelegies
  • Add function to get the session items, in order to follow the DRY principle, because session items are required several times and repeating the same steps each time makes the code less-readable
  • Added functions to actually close session by its ID and Type, but the new functions did include checks on user privelegies so that before closing a session we would be able to check if the calling session is allowed to close the requested session or not

End-User-Impact: it is now possible to close
session by its id and type
using busctl, priveligies
being checked using the
caller session ID
Signed-off-by: Nikolay Chegodaev [email protected]

src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.hpp Outdated Show resolved Hide resolved
src/manager.hpp Outdated Show resolved Hide resolved
src/manager.hpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
src/manager.cpp Outdated Show resolved Hide resolved
- Add functions support functions (protected)
  to provide information about session owner,
  and user privelegies
- Add function to get the session items, in
  order to follow the DRY principle, because
  session items are required several times
  and repeating the same steps each time
  makes the code less-readable
- Added functions to actually close session
  by its ID and Type, but the new functions
  did include checks on user privelegies so
  that before closing a session we would be
  able to check if the calling session is
  allowed to close the requested session or
  not

End-User-Impact: it is now possible to close
                 session by its id and type
                 using busctl, priveligies
                 being checked using the
                 caller session ID
Signed-off-by: Nikolay Chegodaev <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants