1

I am wondering if I can set permissions to allow a program (I am writing) to access a file (. mdb file on a shared network drive), but the user who is running this program does not have permissions to modify that file?

This is on Windows Server 2012 RT

2
  • Could you password protect the MDB file, from the application supply the password. This would be one method to work around access permissions. Otherwise, the application could impersonate another user that does have access while the user that launched the application does not. Aug 16, 2018 at 21:49
  • I want just that other users are not able to damage/delete the database.
    – Greenayman
    Aug 18, 2018 at 6:33

1 Answer 1

0

No.

The Windows security model applies permissions to users, not code. Code always inherits the permissions of the user who executed it.

It sounds like you're developing an Access database. A few points should be noted:

  • It's not possible to delete an Access database while it's in use. Access locks the database file while it's open and as a result Windows will not delete it. This reduces the opportunities users have to delete the DB.
  • Depending on the version of the Access database, you can restrict internal changes with User level security. This feature is not available if the database uses one of the newer .accd* file formats.

Alternately, put the database in something like SQL Server and simply build an Access front end for it. User authentication in SQL Server is granular and instead of granting users access to the entire database, they're only able to access the portions the admin gives them permission to.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .