Disable user from seeing other users folders - windows permissions - windows

I have a data server where users login with there credentials \\myserver.me.com\users\ and then inside it there is a folder for each user e.g Tom-Hanks-user1 is a folder for a user Maggie-Bryan-user2 is another folder for another user and so on. Now when a user login they have access to only their folder but they can still view and see the other users folders but cannot access it. I wonder how I can make the logged in user only see his folder without even seeing the other users folders?
I have a group for my users named my.users and the permissions of this group to the parent folder "users" is shown below:
And below is the permissions for the user Tom Hanks to his folder Tom-Hanks-user1:
But now when user Tom Hanks logins in he have full access to his folder but he can view a folder named Maggie-Bryan-user2 under the users folder, and I wonder how I can disable this where he can view and have access to only his folder and other users folders will not be visible to him?

Related

Prevent user from changing permissions of a directory created by your Cocoa app

We are looking to prevent users from accessing a directory we create from our non-sandboxed app via:
FileManager.createDirectory(atPath:withIntermediateDirectories:attributes:) //where path is ~/Library/Application Support/our.bundle.identifier/ourdir
To do this, we have set no permissions for this directory, thus ensuring they cannot open it via:
fileManager.setAttributes([.posixPermissions: 00000], ofItemAtPath: path) //no permissions
However, users can simply right click it, choose Get Info, and change it from No Access for everyone to Read & Write to gain access.
But this isn't the case for other directories I have found. For example, Desktop located at /Users/Guest/ (or any other user account you’re not logged into) also has No Access for everyone, and when you try to change it you’ll get an error:
The operation can’t be completed because you don’t have the necessary permission.
Another difference I see is the Locked checkbox is disabled for that directory, but enabled for the directory our app created.
This is exactly what we need for a directory created by our app. How can we ensure the user does not have permission to change permissions of this directory?
The reason certain folders can't be access is because they're owned by a different user, and the logged-in user doesn't have permissions. But neither will your app given it's running under the user's account. Admin users (which the default macOS account is one) can always change folder ownership and permissions so you're not going to prevent a folder from ever being accessed.

EWS Managed API - How to find out if the user is the owner of calendar

I am trying to figure out what permissions user have to certain calendar folder. I am checking Permissions property, but it usually contains only 2 permissions - for default and anonymous standard users (no permissions for the owner of the calendar).
How can I check if the user is the owner and can edit events inside this calendar? Some of the calendars User have access are the shared ones so not all of them can be edited but Permissions are the same for all of them (only default and anonymous users permissions). I guess there must be some other property to check if the user can edit events inside the calendar or not.

Create Roles and Users in magento but as a non admin

My client wants the access to create users and roles in magento, i have already given him a limited users created by myself, in that users there is not permission to add users and roles.
My question: Is there any way i can give him permissions to add users and roles but, all the menus that i have made hidden should stay hidden.
What i Want to achieve
I want to give access of creating roles and users to my client, but i don't to revel some menu like "System" to him
In Magento 1.X:
System->Permission->Roles->(Role Name)->Roles Resources->Custom
In Magneto 2.X:
System->User Roles->(Role Name)->Roles Resources->Custom
To give the access for "Roles and User" you have to reveal the
"system" menu to the user as it's the parent of "Roles and User". But, you can disable other inner menus by unchecking them.
You have to only check the System > Permission > Roles > User Bosex from Roles Resouce Tree and it will only allow the user to access the Roles and User.

Deleting roaming profile AppData folder in vbscript

I have a machine, where different users can login with their credentials.
I have an application which gets installed on this machine. Different users login to this application using their individual credentials. As a result, under each users (UserName)\AppData\Roaming a new folder gets created by name DummyData.
When the admin uninstalls this application, I need to delete the DummyData folder created under different logins, if I use %APPDATA% I end up getting current logged in users' AppData folder. Is there a way, I can end up obtaining all the logged in users and if any DummyData folder created under AppData folder so that I can delete all of them.
thanks

How do I access a NAS through my ASP.NET MVC Application?

I'd like to access a Fileserver (NAS) through my ASP.NET MVC Application and can't find a way to do that in a correct way.
What I've done so far is:
Created a User with Read/Write permissions on a directory on my NAS
Created a virtual directory on my IIS Server that is connected to the nas directory with the previously defined usercredentials
Now if I navigate to my virtual directory (AppliCationIPAdress/NAS) I get automaticaly redirected to \NASIPAdress\My\Directory. On the NAS loginnotifications I get the info, that somewone connected to my directory with the given credentials => That is how it should be
But if I access the NAS directory trough my MVC application (no matter if i use the UNC or the virtual directory redirection) i get an access denied erromessage and in the NAS loginnotifications there is not listed my prepared useraccount but my webserver as user who tried to login.
var dirName = Server.MapPath("~/NAS/Dir/");
ViewBag.Message = System.IO.Directory.GetFiles(dirName );
Could someone please explain why that is happening and what I have to do if i want to access files on a fileservice throuh my mvc application?
You have to give the service account rights to access the filearea, or run the app with a user that has rights
What worked for was:
Have same user account and password in NAS and IIS Server.
Create an application pool for your web app or use the default app pool and change the user account to the same mentioned before. Steps:
Go To IIS Manager
Click on Application Pools
Right click on the app pool assigned to your web app and select Advanced settings...
In section Process Model change the Identity field to the user account mentioned above.
Click on the 3 dots button located at the right of the field
Select Custom account and click on Set... button
Set username, password and password confirmation (same user account mentioned above.
Hope it helps!
FranciscoG

Resources