I know this is possible by switching to root or using 'sudo' but I just want to know if there is any other way. Assume the user doesn't have root privileges.
Scenario: While playing a CTF challenge, I gained reverse shell access to the www-data user using Netcat. I also have the credentials for another user, but when I tried to switch to that user , I was not allowed to do so. Additionally, the current user does not have root privileges, so I have this doubt
as user68186 suggested this answer Share a Folder between two Local Users but it didn't resolve my issue. The suggested answers involve changing the group name or using sudo, but I don't have the necessary permissions for those actions.