home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1993 #2 / Image.iso / database / acc_sec.zip / ACC-SEC.TXT
Internet Message Format  |  1993-07-06  |  26KB

  1. From ftpmail-request@grasp.insa-lyon.fr Tue Jul  6 10:02:58 1993
  2. Date: Tue, 6 Jul 1993 19:02:31 +0200
  3. From: ftpmail-request@grasp.insa-lyon.fr
  4. To: james.woo@ebu.ericsson.se
  5. Subject: nic.switch.ch:/mirror/win3/uploads/acc-sec.txt (get acc-sec.txt)
  6. Content-Length: 25745
  7. Status: RO
  8. X-Lines: 523
  9.  
  10. File Info for SECURE.TXT
  11.  
  12. Date:  2/11/93
  13. Title: Additional Microsoft Access Security document
  14.  
  15. The purpose of this document is to explain the Microsoft Access security model.  The
  16. hope is that if the user understands the intricacies of security, and is conscientious,
  17. he will be able to safely and successfully use Microsoft Access security in his
  18. database.
  19.  
  20. ===================================================================
  21. DOWNLOADED FROM COMPUSERVE BY NBRINDLE@INDYCMS.IUPUI.EDU on 6/28/93
  22. ===================================================================
  23.  
  24. Microsoft Access Security
  25.  
  26.  
  27. Purpose
  28. -------
  29.  
  30. The purpose of this document is to explain the Microsoft Access security
  31. model.  The hope is that if the user understands the intricacies of
  32. security, and is conscientious, he will be able to safely and successfully
  33. use Microsoft Access security in his databases.
  34.  
  35. Examples of scenarios that have caused difficulty for people in the past
  36. have been set apart under the heading of Gotcha.  These are intended to
  37. give practical examples of common misunderstandings, and to explain why
  38. Microsoft Access security works the way it does.
  39.  
  40.  
  41. Overview
  42. --------
  43.  
  44. Microsoft Access security consists of 2 parts which are stored in different
  45. places.  Information regarding the permissions that users and groups have
  46. on the objects in a database is stored in the database itself.  This way
  47. the permission information travels with the .mdb file in which the objects
  48. exist.  All other security information is stored in system.mda.  This
  49. includes:  which Users & Groups exist;  which Groups each User belongs to;
  50. and User logon passwords.  In Microsoft Access parlance, a system.mda
  51. defines a "Workgroup".
  52.  
  53.  
  54. Logging On
  55. ----------
  56.  
  57. Each User and Group has associated with it a Security ID (SID).  The SID is
  58. a binary string that uniquely identifies the User or Group.  When a user
  59. logs on, Microsoft Access looks in the MSysAccounts table of the system.mda
  60. specified in the user's msaccess.ini for a user of the same name (case-
  61. insensitive).  If a user with the same name is found, it then validates the
  62. password (case-sensitive).  If the password matches, the SID of the user is
  63. retrieved and saved in an internal structure.  The password is only used to
  64. validate the user when he logs on.  Other than validating the identity of
  65. the user when he logs on, it has no effect on security.
  66.  
  67. By default, Microsoft Access first attempts to logon as the user Admin,
  68. with a blank password.  If this logon fails, the user is presented with the
  69. Logon dialog.  If a user name and password were specified on the command
  70. line (using the /USER and /PWD flags), Microsoft Access first tries to
  71. logon using that user name and password.  If this logon fails, the user is
  72. presented with the Logon dialog.  Once logged on, the user's SID is
  73. retrieved.  This SID is used for all subsequent operations within Microsoft
  74. Access.
  75.  
  76.  
  77. Users and Groups
  78. ----------------
  79.  
  80. Each user can be a member of 1 or more groups.  Users & Groups share the
  81. same namespace.  This means that you can't have both a group and user with
  82. the same name.
  83.  
  84. Microsoft Access defines 3 default groups:  Admins, Users, and Guests.
  85. Whenever a user is added to the system.mda, they are automatically given
  86. membership in the group Users, and they cannot be removed from the Users
  87. group.  There is one exception to this rule---the user Guest CAN be removed
  88. from the Users group.  The Admins group must always have at least one
  89. member.
  90.  
  91. Microsoft Access defines 2 users:  Admin and Guest.  The user Admin is a
  92. member of the Admins and Users groups.  The user Guest is a member of the
  93. Guests group (only).
  94.  
  95. The pre-defined groups (Admins, Users, and Guests) cannot be deleted.  The
  96. user Guest cannot be deleted, though the user Admin CAN (and should be to
  97. preserve security) if there is at least one other member of the Admins
  98. group.
  99.  
  100. Each user and group has a SID associated with it.  The SIDs of the Users
  101. and Guests groups, and of the Admin and Guest users, are the same in all
  102. Microsoft Access installations.  The SID of the Admins group, however, is
  103. unique across all Microsoft Access installations.  The SID of the Admins
  104. group is determined when Microsoft Access is installed.  This prevents
  105. someone who is in the Admins group of one system.mda from being able to
  106. have the permissions of any other Admins group.
  107.  
  108. Gotcha:  If you delete the user Admin, and then create another user
  109. named Admin, the SID of the new Admin will NOT be the same as the SID
  110. of the Admin that exists in an unsecure system.  This is because the
  111. Admin user that you create will have a different PIN that the Admin
  112. user that exists in a freshly-installed system.mda.
  113.  
  114. The SID of the Admins group is a function of the Setup disk serial number
  115. and the User and Company names given (case-insensitive).  Therefore, it is
  116. critical that the disks used to install Microsoft Access be kept in a safe
  117. place, and that the User and Company names be recorded.  In the event that
  118. the system.mda has to be recreated, the same installation disks must be
  119. used.
  120.  
  121. The SIDs of users and groups that you create are a function of the user or
  122. group name (case-sensitive) and Personal Identification Number (PIN) that
  123. you specify.  For this reason it is critical that the user and group names
  124. and their PINs be backed up.  If there is ever a need to recreate the
  125. system.mda, you will need the name and PIN of each user and group that was
  126. in the system.mda.  Note that by using different PINs, it possible for
  127. users and groups in different system.mda's to have the same name, but they
  128. will actually be different accounts as far as Microsoft Access security is
  129. concerned because they have different SIDs.
  130.  
  131. Gotcha:  When you setup Microsoft Access, the User and Company names
  132. are written to Disk #1.  If you then give anyone else your disks to
  133. setup from, Microsoft Access doesn't prompt for the User and Company
  134. name.  The Admins group in the system.mda that is created will have
  135. the same SID as the Admins group in your system.mda.  This means that
  136. anyone who uses that new system.mda will have all the permissions that
  137. you do, in any databases that you have permissions.  While this
  138. functionality wasn't intended as a form of copy protection, it is a
  139. good incentive to abide by the License Agreement.
  140.  
  141.  
  142. Permissions
  143. -----------
  144.  
  145. There are 2 types of permissions:  Explicit and Implicit.  Explicit
  146. permissions are those given directly to a user.  When they are granted, no
  147. other users are affected.  Implicit permissions are those granted to a
  148. group.  When they are granted, all users who are members of the group get
  149. the permissions of the group.  Implicit permissions belong to the group,
  150. not the users.  If a user is removed from the group, he no longer has the
  151. permissions of the group.  If the permissions of the group are changed, all
  152. users in the group are affected.
  153.  
  154. When a user attempts to do something, he will get the least restrictive
  155. permissions of:  1) all the groups in which he is a member (his Implicit
  156. permissions), and 2) those given directly to him (his Explicit
  157. permissions.)
  158.  
  159. In the Microsoft Access Permissions dialog, only the Explicit permissions
  160. are displayed.  This is a limitation of v.1.0.  To view implicit
  161. permissions, view the permissions of each group that the user is a member
  162. of.
  163.  
  164. The Admins group of the system.mda in use when the database was created
  165. will always have permission to change permissions on all objects in the
  166. database.  This permission cannot be taken away by anyone!!!  This
  167. permission remains even when all permissions have been revoked from the
  168. Admins group, and isn't displayed in the Permissions dialog.  It should
  169. therefore be obvious that it is very important to know and keep track of
  170. which system.mda was in use when the database was created.  To stress this
  171. point, italics will be used throughout this document where it comes up.
  172.  
  173. The Users group initially has Full permissions on all objects created in
  174. the database.  The Guests group has Read Definition and/or Read Data
  175. permissions on them, as appropriate for the object type.  Basically, Guests
  176. can read all objects and data, but can't change anything.
  177.  
  178. Permissions on an object can be changed by anyone having permissions to do
  179. so.  The following users have this permission:  members of the Admins group
  180. of the system.mda in use when the database was created;  the creator of the
  181. database (it's owner);  the creator of the object (it's owner); and anyone
  182. who has Full permissions on the object, either explicitly or implicitly.
  183.  
  184. Gotcha:  Jane gives Joe a database that she created.  Joe is a member
  185. of the Users group, and no other groups.  He is using a different
  186. system.mda (the SID of the Admins group of his system.mda is different
  187. from the SID of the Admins group in Jane's system.mda).  Jane's
  188. database is "unsecure", meaning that the Users group has Full
  189. permission on all objects.  Joe revokes Full permissions from the
  190. Users group on a Table1.  From that point forward, Joe can no longer
  191. change permissions on that Table1.  If he also revoked Read Data
  192. permissions, he has prevented himself from being able to read Table1,
  193. because he no longer has permission to do so.  For both these cases,
  194. he just revoked his own permissions on the Table1.  Because Joe isn't
  195. a member of the Admins group of the system.mda in use when the
  196. database was created, and because he didn't create Table1, he's
  197. completely locked out of Table1 until Jane (using her own system.mda)
  198. gives him permissions again.
  199.  
  200. All users always have permission to open any database and create objects in
  201. it.  Microsoft Access relies on operating system security to prevent a user
  202. from being able to open a database.
  203.  
  204. Gotcha:  Even if a user doesn't have an account in your system.mda, he
  205. can use any other system.mda in which he has an account to logon to
  206. Microsoft Access.  Then he can open any database that he can get to
  207. through the operating system.  Once the database is open, he can see
  208. which objects exist, and create new objects.  There is no method to
  209. prevent creation of objects.
  210.  
  211. It is possible for a user to have permissions on an object in a database,
  212. and not be able to see those permissions in the Permissions dialog.  This
  213. will happen if the user was assigned permissions in the database and then
  214. was deleted from the system.mda.  The permissions given to the user are
  215. stored in the .mdb, and aren't removed when the user is removed.  The
  216. following steps will show these permissions:
  217.  
  218. 1. Set the Show System Objects option to Yes
  219. 2. Give yourself Read Data permissions on the MSysACEs table
  220.      If you don't have permissions to do this, you're not a member of the
  221.      Admins group of the system.mda in use when the database was created,
  222.      and you didn't create the database.
  223. 3. Attach to or import the MSysAccounts table from the system.mda
  224.      currently in use
  225.      If you don't have permissions to do this, you're not a member of the
  226.      Admins group of the system.mda currently in use.
  227. 4. Run this query:
  228.      SELECT DISTINCTROW MSysObjects.Name AS Object, MSysAccounts.Name As
  229.      UserGroup FROM MSysACEs, MSysAccounts, MSysObjects, MSysACEs LEFT JOIN
  230.      MSysAccounts ON MSysACEs.SID = MSysAccounts.SID, MSysACEs INNER JOIN
  231.      MSysObjects ON MSysACEs.ObjectId = MSysObjects.Id;
  232.  
  233. This will show the names of all users and groups who have permissions on
  234. all objects in the database.  If the UserGroup field is blank, it means
  235. that the user or group doesn't exist in your system.mda, yet still has some
  236. kind of permissions on that object.  Disclaimer:  The query above works
  237. fine in Microsoft Access 1.0.  However, the Microsoft Access system tables
  238. (MSys*) are officially "undocumented", and are subject to change in future
  239. versions.
  240.  
  241.  
  242. Ownership
  243. ---------
  244.  
  245. Ownership is a very important part of Microsoft Access' security model.
  246. The SID of the user who creates a database is considered the "owner" of the
  247. database.  He will always have permission to give himself Full Permission
  248. on any object in the database, regardless of who creates the object, or
  249. what permissions are on the object.  He will therefore also always have
  250. permissions to give anyone else permissions on any object in the database.
  251.  
  252. The SID of the user who creates an object is considered the "owner" of the
  253. object.  He will always have permission to change permissions on the
  254. object, even if the database owner has revoked his permissions on the
  255. object.
  256.  
  257. The Admins group of the system.mda in use when the database was created
  258. will always have permissions to change permissions on any object in that
  259. database.
  260.  
  261. The only way to transfer ownership of a database or object is to recreate
  262. it.  For databases, this means doing a File New Database and importing all
  263. the objects from the old database.  Table relationships will have to be
  264. recreated after importing, as they're not preserved when importing or
  265. exporting.
  266.  
  267. For objects, ownership can be transferred by importing or exporting the
  268. object, or by copying and pasting it.  These operations essentially create
  269. a brand new object, one that is completely unsecured.  Note that for both
  270. of these situations, the person doing the importing/exporting or
  271. copy/pasting must have permission to read the objects in the first place.
  272.  
  273. Gotcha:  As mentioned above, the Admin and Guest users have the same
  274. SID in all system.mda's.  It is therefore critical to security that
  275. the Admin and Guest users NOT create (are the owner of) any objects or
  276. databases.  If they do, anyone who has Microsoft Access and can get to
  277. the database .mdb file can open it and have Full permission on the
  278. objects created by Admin or Guest, and all objects in the database if
  279. either of these users created the database.
  280.  
  281.  
  282. The "Hole"
  283. ----------
  284. By default, the Users and Guests groups have Read Data permissions on the
  285. MSysObjects table.  For various technical reasons, this is necessary to
  286. allow the user to do File Load From Query in the Filter window.
  287.  
  288. The astute reader will see that MSysObjects contains a field named "Owner",
  289. and he will figure out that it contains the SID of the owner of each
  290. object.  The astute reader will also realize that the SID field in the
  291. MSysAccounts table of system.mda contains his own SID.  Because everyone
  292. has Read Data permissions on MSysObjects, it would be possible to read the
  293. SID of the owner of any given object, and replace his SID in MSysAccounts
  294. with it.  The next time he logged on, he would have the SID of the owner of
  295. the object, and all rights associated with it.  He could change permissions
  296. on the objects, and therefore do anything he wanted to with it.
  297.  
  298. SIDs are binary fields.  When MSysObjects is browsed, the binary fields are
  299. truncated at the first null terminator (ASCII 0).  Additionally, any
  300. characters whose ASCII values are below 32 will display as garbage.  All of
  301. this essentially prevents someone from being able to edit or copy and paste
  302. this value directly.  However, it would be a relatively simple matter to
  303. change your own SID using Microsoft Access Basic code or a query.
  304.  
  305. Fortunately, there is a way to patch this security hole:
  306.  
  307. 1.  Make a backup of you database!!!
  308. 2.  Open your database
  309. 3.  Set the Show System Objects option to Yes
  310. 4.  Select Permissions from the Security menu
  311. 5.  Give the Users group Read Definition permissions on MSysObjects
  312. 6.  Revoke Read Definition permissions on MSysObjects from the Users group
  313. 7.  Repeat steps 5 & 6 for the Guests group
  314.  
  315. This will prevent someone from reading the SID from the Owner field and
  316. writing it into his own MSysAccounts table.  The downside is that when
  317. people who aren't in the Admins group (of the system.mda in use when the
  318. database was created) attempt to use the "Load From Query" functionality
  319. while in MyApp.mdb, they will get an error that says "No permission for
  320. 'MSysObjects'".  The only people who will be able to use the "trick" above
  321. are the person who created the database, and anyone who is a member of the
  322. Admins group of the system.mda in use when the database was created.  It is
  323. not recommended that you repeat steps 5 & 6 for them.
  324.  
  325. Needless to say, this hole will be plugged in a future version of Microsoft
  326. Access.  Disclaimer:  Again, the Microsoft Access system tables (MSys*) are
  327. officially "undocumented", and are subject to change in future versions.
  328. Don't count on any information regarding them to be applicable to anything
  329. but Access version 1.0.
  330.  
  331.  
  332. The "Run with Owner's Permissions" Query Property
  333. -------------------------------------------------
  334.  
  335. Microsoft Access queries have an property called "Run with Owner's
  336. Permissions" (RWOP).  This is in the Query Properties dialog.  If this
  337. property is checked, the permissions of the owner of the query are the only
  338. permissions that are considered when attempting to access tables or queries
  339. that the query is dependent on.
  340.  
  341. Gotcha:  Joe has Read Definition permissions on the Salary table, but
  342. not Read Data.  Joe creates Query1, which is based on the Salary
  343. table.  Joe has left RWOP turned on.  Joe is unable to execute the
  344. query, because he doesn't have Read Data permissions on the Salary
  345. table.  This much is intuitive.  Jane created the Salary table, and
  346. has Full permission on it.  Jane tries to execute Query1.  She cannot,
  347. because the RWOP option of Query1 is turned on, and the owner of the
  348. query (Joe) doesn't have Read Data permissions on the Salary table.
  349. While this may not be entirely intuitive, it is correct functionality.
  350.  
  351. Only the owner (creator) of a query may save it if the RWOP property is
  352. turned on.  Even the database owner or members of the Admins group of the
  353. system.mda in use when the database was created can't save a query created
  354. by another user if the RWOP property is turned on.  It would be a security
  355. breach to allow them to.  Note though, that anyone with Modify Definition
  356. permissions on the query can uncheck RWOP and successfully save the query.
  357. This may lead to other complications if other people were using the query
  358. and depending on RWOP being there.
  359.  
  360. This functionality extends to the QueryDef object as well.  Only the owner
  361. of a query can change the query using the "Set Q.SQL = MySQLString$" syntax
  362. if MySQLString$ ends with "WITH OWNER ACCESS OPTION;".
  363. Common Scenarios
  364.  
  365.  
  366. Securing an Existing Database
  367. -----------------------------
  368.  
  369. You've written an application using Microsoft Access---call it MyApp.mdb.
  370. You've created all the objects while you were logged on as Admin (the
  371. default.)  Now you want to "secure" the database.  Here are the steps to
  372. follow to do so:
  373.  
  374. 1.  Make a backup of MyApp.mdb!!!
  375. 2.  Choose Change Password from the security menu and give a password to
  376.         the user Admin.
  377. 3.  Create a new user and add him to the Admins group.  For this
  378.         example, the user is Joe.
  379. 4.  Exit Microsoft Access and restart it, giving Joe as the user when
  380.         the Logon dialog is given.
  381. 5.  Create a new database---call it MyApp2.mdb
  382.         This will establish Joe as the database owner.
  383. 6.  Import all the objects from MyApp.mdb into MyApp2.mdb
  384.         This will establish Joe as owner of all the objects.
  385. 7.  If you had any table relationships, recreate them in MyApp2.mdb
  386. 8.  Revoke Full permissions from the Users group on all objects, leaving
  387.         them with whatever other permissions you like.  You may also want to
  388.         revoke permissions from the Guests group.
  389. 9.  If desired, create any of your own groups and users, and give them
  390.         appropriate permissions on all the objects.
  391. 10.  Rename MyApp.mdb to MyApp.old and rename MyApp2.mdb to MyApp.mdb.
  392.  
  393. Your database is now secure.  The only people who can get into the objects
  394. in MyApp.mdb are those you gave permissions to in steps 8 & 9, and anyone
  395. who is a member of the Admins group of your system.mda.
  396.  
  397.  
  398. Unsecuring a Secured Database
  399. -----------------------------
  400.  
  401. You've followed the steps under Securing an Existing Database, above.  Joe
  402. is the owner of the database and all objects in it.  The Admins group of
  403. Joe's system.mda has permissions to change permissions on any object in the
  404. database.  The goal here is to make the user Admin the owner of the
  405. database and all objects in it, and to give the Users group Full
  406. permissions on all objects.  Remember, the SIDs of the user Admin and the
  407. Users group are constant in all system.mda's, so this will effectively give
  408. everyone Full permissions on all objects in the database, and make them the
  409. database owner as well.
  410.  
  411. 1.  Make a backup of MyApp.mdb!!!
  412. 2.  Boot Microsoft Access as a member of the Admins group of the
  413.         system.mda in use when MyApp.mdb was created.
  414. 3.  Give the Users group Full permissions on all objects in the
  415.         database.
  416. 4.  Edit your msaccess.ini file so that SystemDB points to a
  417.         system.mda in which no users exist.
  418. 5.  Exit Microsoft Access and restart it logging on as the user Admin.
  419.         Note that this Admin MUST be the same Admin that exists in the
  420.         "clean" system.mda that is created when you setup Microsoft Access
  421.         so that the SID is correct.
  422. 6.  Create a new database (call it MyApp2.mdb)
  423. 7.  Import all the objects from MyApp.mdb into MyApp2.mdb
  424.  
  425. Your database is now completely unsecured.  Anyone who can to the
  426. MyApp2.mdb file have Full permissions on all the objects in it.
  427.  
  428.  
  429. Protecting Your Code
  430. --------------------
  431.  
  432. You've written a bunch of Microsoft Access Basic code that you want to
  433. distribute, perhaps as a Library Database, but you don't want anyone to be
  434. able to read your code.  The modules are in MyApp.mdb, and were all created
  435. while you were logged on as Admin.  Assuming that you're starting from a
  436. completely unsecure configuration, here are the steps to secure the code:
  437.  
  438. 1.  Make a backup of MyApp.mdb!!!
  439. 2.  Choose Change Password from the security menu and give a password to
  440.         the user Admin.
  441. 3.  Create a new user and add him to the Admins group.  For this
  442.         example, the user is Joe.
  443. 4.  Exit Microsoft Access and restart it, giving Joe as the user when
  444.         the Logon dialog is given.
  445. 5.  Open MyApp.mdb
  446. 6.  For each module you want secured, do the following:
  447.         a.  Open the module in design mode
  448.         b.  File Save Text to save the module to a text file
  449.         c.  File Close
  450.         d.  Delete the module
  451.         e.  Create a new module
  452.         f.  File Load Text to bring the text file from step b back in
  453.         g.  File Save, giving the original module name
  454.                 This will establish Joe as owner of  the modules.
  455. 7.  Revoke all permissions from the Users and Guests groups on all the
  456.         modules.  All users will still be able to execute the code---there's
  457.         no way to prevent someone from being able to execute code.
  458.  
  459. Your modules are now secured so that nobody except Joe and members of the
  460. Admins group of the system.mda in use when MyApp.mdb was created can read
  461. the modules.
  462.  
  463.  
  464. Moving a Database to Another System.mda
  465. ---------------------------------------
  466.  
  467. You are Joe, and have written MyApp.mdb and want to give it to Jane who is
  468. using a different system.mda.  You want Jane to have complete
  469. administrative authority over your database.  The problem is this:  The
  470. Admins group of Jane's system.mda doesn't have any permissions on anything
  471. in MyApp.mdb.
  472.  
  473. There are 2 variations of this scenario:
  474.  
  475. Variation #1:  MyApp.mdb is completely unsecured (the Users group has
  476. Full permissions on everything).
  477.  
  478. The situation here is as follows...  The user Admin created MyApp.mdb
  479. and all the objects in it, and is therefore the owner of everything.
  480. The Admins group of Joe's system.mda has permissions to change
  481. permissions on all the objects in MyApp.mdb.  The Users group (which
  482. has the same SID in all Microsoft Access installations) has Full
  483. permissions on all objects in MyApp.mdb.  Jane's system.mda is
  484. unsecure (the Admin password is blank, and there are no user accounts
  485. or groups.)
  486.  
  487. To give MyApp.mdb to Jane, and have her get complete administrative
  488. authority over it, follow these steps:
  489.  
  490. 1.  Make a backup of MyApp.mdb!!!
  491. 2.  Boot Microsoft Access using Jane's system.mda.
  492. 3.  Create a new database---call it MyApp2.mdb
  493.         This will establish Admin as the database owner.
  494. 4.  Import all the objects from MyApp.mdb into MyApp2.mdb
  495.         This will establish the user Admin as owner of all the objects, and
  496.         give the Admins group of Jane's system.mda permission to change
  497.         permissions on all objects created in MyApp2.mdb.
  498. 5.  If you had any table relationships, recreate them in MyApp2.mdb
  499. 6.  Rename MyApp.mdb to MyApp.old and rename MyApp2.mdb to MyApp.mdb.
  500.  
  501. Variation #2:  MyApp.mdb is secured using the steps under Securing an
  502. Existing Database.
  503.  
  504. To give MyApp.mdb to Jane, and have the Admins group of her system.mda
  505. get complete administrative authority over it, follow these steps:
  506.  
  507. 1.  Follow the instructions under Unsecuring a Secured Database, above
  508. 2.  Follow the instructions under Variation #1, above.
  509.  
  510. For all intents and purposes, Jane is now the "owner" of MyApp.mdb and all
  511. objects in it, and Joe is just another user.  Under both these scenarios,
  512. you can include steps 1-4 and 8-10 of Securing an Existing Database, above,
  513. as necessary to make the database secured under Jane's system.mda.
  514.  
  515.  
  516. Miscellaneous Tidbits
  517. ---------------------
  518.  
  519. The User() function in Microsoft Access Basic returns the name of the
  520. current user.  This is not the same as the SID.  As mentioned under Users
  521. and Groups, above, it is possible for 2 users in different system.mda's to
  522. have the same name but different SIDs.
  523.  
  524. Gotcha:  This can cause a problem if 2 people that are using different
  525. system.mda's have the same name but different PINs (and therefore
  526. different SIDs).  For example, if you are using the User() function to
  527. log activity, and both are using your database, the activity logging
  528. could be inaccurate.  These are actually 2 different accounts, even
  529. though their user names are the same.
  530.  
  531.  
  532.  
  533.  
  534.