MCPcopy Create free account
hub / github.com/OpenVPN/openvpn3-linux / MoveToOwner

Method MoveToOwner

src/sessionmgr/sessionmgr-session.cpp:683–691  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

681
682
683void Session::MoveToOwner(const uid_t from_uid, const uid_t to_uid)
684{
685 object_acl->TransferOwnership(to_uid);
686 object_acl->GrantAccess(from_uid);
687 restrict_log_access = false; // The previous owner can receive log events
688 sig_session->LogInfo("Ownership changed from " + lookup_username(from_uid)
689 + " to " + lookup_username(to_uid)
690 + " on " + GetPath());
691}
692
693
694void Session::method_ready(DBus::Object::Method::Arguments::Ptr args)

Callers 1

process_registrationMethod · 0.80

Calls 4

lookup_usernameFunction · 0.85
GrantAccessMethod · 0.80
TransferOwnershipMethod · 0.45
LogInfoMethod · 0.45

Tested by

no test coverage detected