Lecture on Discretionary Access Control covering the access control matrix, ACLs vs. capability lists, owner-granted permissions, and deny/revoke handling.
Key Takeaways
- DAC lets resource owners decide who gets access to their resources, within system rules.
- The access control matrix is sparse, so it is decomposed into ACLs (by column) or capability lists (by row).
- ACLs answer 'who can access this object?' while capability lists answer 'what can this subject access?'.
- Permissions are dynamic and must be granted, revoked, or denied with appropriate auditing.
What the video covers
- Introduces Discretionary Access Control (DAC), where resource owners may grant or revoke permissions subject to system rules.
- Explains the access control matrix with subjects as rows, objects as columns, and cells holding permissions; notes it is sparse and inefficient.
- Describes decomposing the matrix by columns into Access Control Lists (ACLs), where each object stores its subjects and permissions.
- Describes decomposing by rows into capability lists (tickets), where each subject holds the objects it can access and its access modes.
- Compares ACLs (easy to see who can access an object, hard to list one user's permissions) with capability lists (easy to see a user's permissions, harder to audit an object).
- Discusses default public entries and general permissions applied to users not explicitly listed.
- Covers dynamic permission changes, including grant, revoke, and deny operations, and the need to alert on unauthorized access attempts.
- Explains authorization rules, including the copy flag and asterisk mechanisms that allow permissions to be passed to other subjects.
- Introduces protection domains, where processes operate under different permission sets depending on their needs.
- Touches on kernel-level control and how the operating system enforces access, including ending processes via the task manager.
Chapters
- 00:00Introduction to Discretionary Access Control
- 01:37Access Control Matrix and Sparsity
- 04:25Decomposing into Access Control Lists
- 05:51Capability Lists and Tickets
- 07:07ACL vs. Capability List Trade-offs
- 12:00Grant, Revoke, and Deny Operations
- 16:40Authorization Rules and Copy Flags
- 22:01Protection Domains and Kernel Control
Full Transcript — Download SRT & Markdown
Speaker A
The Merciful. Welcome to the third lecture, chapter four. In this lecture, we will discuss Discretionary Access Control. Or discretionary access control. In this lecture, we will discuss the access control matrix. We will discuss the access control list.
Speaker A
We will discuss authorization, replication, state, owner control, and copy flags. Finally, we will discuss protection modes, users, and the kernel . So, what does Discretionary Access Control mean? Discretionary Access Control allows a user with specific permissions. Or certain privileges. To
Speaker A
grant these permissions to another person. So they can gain access. Or reach the resources we have. Meaning, if you are a user who has permission for file A, okay. You can grant permission for this file to whom? To
Speaker A
people other than yourself. If you possess the right of authorization. To grant other people, who is who? The permission, in case you are the file owner, you are the owner and your resource is who? The file; you can
Speaker A
grant access permission to whom? To another colleague of yours in the organization; okay, the right to access depends on the identity of the requester; I don't just give it to a group, or I might give it to a group or
Speaker A
a specific person, so I grant it based on the fact that person A has permission to access the file, person B has no permission, person C has permission to write, person D has permission to read, and so on. Okay. It
Speaker A
says resource owners may grant or revoke permissions subject to system rules. Okay. The file owner can, who is the resource owner. Okay. The file or the resource can be a file. And what can it be? It can be anything: a file,
Speaker A
records. Okay. To grant the permission or revoke the permission from whom? From specific people according to the system rules we have. Okay.
Speaker A
Traditionally, it has always been linked to what we call an access control list. Which is the access control matrix. The access control matrix. Okay. The access control matrix , our access control list. The access control list contains rows, columns,
Speaker A
and cells. The row represents who for us? The row represents the people, or users, or user groups. Okay. This is for whom regarding the rows. Meaning, here is our row. The first row represents user A. The second row
Speaker A
represents. User B. The third row represents user C. This is for the rows . As for the columns, okay. As for the columns, they represent the objects.
Speaker A
What is meant by objects? Files or records. Meaning, here is the first file. Or if talking about the database records, here is the file. The first, second, third. Each one of them represents for us. Which is that each
Speaker A
column represents the permissions granted to users on this file. Okay, the cells; each cell represents a specific user's permission on a specific file or resource. Okay, it tells me here in the access control.
Speaker A
Matrix is sparse. What does sparse mean ? Sparse means scattered. It's sparse, meaning it has many empty cells in it.
Speaker A
Here, it was just a matrix for three files. If we take it for all system files and all system users. We will discover that our matrix is what?
Speaker A
Sparse. Meaning it has many empty cells . And this is an unfavorable format. So we will see later what the solution to this is. Well, the basic idea. Is that I want to define in the access control matrix what permissions each person has
Speaker A
on the files, whether read, write, or if they have no permission on the file at all. Okay, this person might authorize, for example, read permission to another user, or read or write to someone else, okay? Regarding the access control list, it tells me that
Speaker A
to be able to use it, I won't keep it in this complete form; I will decompose it into something. Why? Because, as we said, it is sparse. And since it is sparse, we decompose it. So that it becomes something non-sparse. Or what I
Speaker A
call dense, okay. So it tells me we will divide it in two ways. The first way, if I make it an access control list, is to divide it by columns. Take each column separately. Consequently, each object stores a list of subjects
Speaker A
and their permissions. Meaning I will take this first column by itself, you see it? I will come and say, this subject, okay. Here is the subject, file one. User A will have read and write permission. Here, user B has read
Speaker A
permission. User C has read and write permission, okay. This is what we call. Decomposed by columns. Each column takes in its objects a list of subjects and their permissions. Each subject and what is, who is, their permissions on
Speaker A
whom. On the file we have or the object , okay. Who can access this object. So, simply, I will ask my question. File number one, who can access it? It will tell me user A with read and write
Speaker A
permission. And it performs, user B with read permission. User C has read and write permission, okay. The second method of decomposition I call capability lists or tickets. Which are lists of capabilities and tickets. I decompose by whom? I divide by rows, so
Speaker A
for every subject. As long as I said rows, here are the rows. Each row represents a subject. Each subject will have tickets with them. The first ticket is that he is able to read file A. Or is able to write to file A. Or he
Speaker A
is the owner of file B A. The second ticket, I don't mention file two in it.
Speaker A
File 3 comes with read and write permission. And that the owner is user B, for example, or user C, for example.
Speaker A
Has read and write permission on, what, on file one. And has read permission on file two. So I have a ticket. The first ticket is reading file one. The second ticket is read/write file one. The third ticket is reading for whom? For
Speaker A
file two. So we have two methods of decomposition to get rid of the sparse issue. The first method is the access control list. The second method is the capability list. Regarding the access control list, I decompose by column,
Speaker A
okay. Each object stores a list, which is. Meaning each file stores a list of which people or users. Who have the permissions to access it. As for the capability list method, I perform a row-based split. Therefore, every object, every subject, and every actor.
Speaker A
Stores or possesses tickets, alright, for whom? For the things they are able to access, the files or resources they can reach. Okay. Well, this is, for example, an Access Control List. Which is the first method, decomposition by column. I come and say the first file.
Speaker A
Okay. What about file one? User A can perform read and write on it. User B performs read on it. User C performs read and write on it. What about the rest of the people? No access. Do I have an empty cell here? I do not have
Speaker A
an empty cell. Okay. And thus, we solved the issue of. Can object. This object we have. I am able to easily know who are the people who can reach them. A group here, maybe user A, B, C.
Speaker A
Or I can give it to whom? To a group of users. Okay. Default public entries, which are the others. These can define general permissions. I can give other people general permission. Here I said to it, no access. Or I could, for
Speaker A
example, give it read permission, depending on what I want. Is that clear ? Well, the disadvantages or limitations. It tells me if I want to retrieve all permissions for one user.
Speaker A
I am forced to do what? Go through all access control lists for all the resources I have. To tell you that user A has these permissions. Okay. And thus , this is a problem. So what is the solution for us? It said to perform
Speaker A
decomposition with the second method. Which is the capability list. In the capability list, I define for each object or subject, which is each user, what objects they can reach. Able to reach. I mean, I come and say. For user
Speaker A
A, okay. Able to reach file one, read and write. File three, read and write.
Speaker A
File five, read, okay. The files that they cannot reach, I do not mention them in the list below, okay. Its advantages: easy to determine which objects a user can access. Which is, which objects the user can access.
Speaker A
Provides a subject-oriented view of permissions. What does that mean? It tells me I am displaying permissions from the viewpoint of whom, which is the subject. I mean, the first one was from the viewpoint of the object, which is the files, resources, and others.
Speaker A
Here, it is from the viewpoint of the users, okay. Well, what security concerns do we have? It told me this consists of tickets. Anyone could come, take the tickets, and leave, okay. Any user could transfer the ticket to other
Speaker A
people, and that creates a problem for me. And thus, it tells me I want the operating system to be the one protecting this ticket or capability list. And do what? By using it, whether in the storage process or using
Speaker A
something I call unforgeable tokens. Okay, tokens that cannot be forged. So that not just any person who happens upon these tickets can reach and log in , okay. If we make a quick comparison between the Access Control List and the
Speaker A
capability list, okay. Regarding the access control list, I am doing decomposition by column, okay. And it relates to whom? To the object. Meaning , who can access each file, okay. The management process is done, or what are our security concerns and
Speaker A
considerations? It tells me this: It correctly manages whom? The object permissions. Okay. So, I want to do what? Manage object permissions exactly . So that the management process is secure. Well, for example, it tells me a guest list. What does that mean? For
Speaker A
example, it tells me, if we want to simulate it in reality. I have a hall.
Speaker A
This hall is my resource. At the door, as soon as the visitor list comes, the first user arrives. I tell him I have a list. You are allowed to enter. The second one is not allowed. The third is
Speaker A
allowed. And the fourth is not allowed. And so on, okay. Well, let's talk about the capability list. It tells me, no, it is by rows. Okay. The first thing we do by rows is related to whom? To the
Speaker A
subjects. Which is the actor, or the users, or whom? The groups, okay. Each user, what are the resources they can access? Okay. I want...we have security concerns, I must protect the capability list from forgery or misuse. Who will
Speaker A
do this? We said the OS, okay. It is similar to what? Tickets, okay. Meaning , I have a large hall, which is, for example, a theater or an auditorium.
Speaker A
Every person comes with a ticket. They have a specific place in the hall. If you have the ticket, you enter. I am not going to check who the users entering are. No, have a ticket, enter.
Speaker A
No ticket, you are not allowed to enter our system, okay. Authorization tables, these tables were what? Another representation. We said this is also the first one, the access control matrix. Because it had the sparse problem. And when I did the
Speaker A
decomposition. We had security concerns , in the story of someone forging the ticket or others. Okay. So we said we have another method. Which is the authorization table, or in Arabic, authorization tables. It is another way to represent what? Permissions in the
Speaker A
system. It is a data structure that is what? First thing, sparse. The access control matrix was what? Sparse. This one is not sparse like the access control matrix. More concise. And it is more conservative than the access control list and the capability list.
Speaker A
And therefore, it solves the security concerns we have. It tells you every line, okay. Every line, each entry, what is it? It contains the subject, which is the file, okay. Or the subject , which is the user, and what is the
Speaker A
permission. The access mode. And what is the object they are able to access? Which is file one, file two, file three . Okay. It tells me if I did an arrangement by the subject, which is whom? The users. Then I am talking
Speaker A
about what? About the capability list view. If I did an arrangement by the object. Okay. Meaning, if I arranged in the first one by the subject. It will be the first people, the first thing for the subject A, B. I am currently
Speaker A
talking about the capability list. Everything is bundled within it. Now, what if I organize it by objects? I am essentially stating the permissions for each file. This gave me the...It gave me two ways to display it. Either by
Speaker A
user or by object. But without whom? Without performing table decomposition. Therefore, it is easy to store in a relational database. Which is, who? In an SQL database. I can store it in an SQL database. Why? Because I have
Speaker A
columns, three columns displayed as a table. So, there are no empty columns. Thus, it is easy to store in a relational database. How do I protect files in Discretionary Access Control?
Speaker A
It says the protection state is a set of information. Describing for each subject, meaning each user. What permissions they have on each resource or object at any given moment. Why?
Speaker A
Because permissions can change. Moment. Because permissions change. You have permission today, but five minutes later, it might be revoked. Don't we have grant and revoke? If I say revoke a permission, it means I have taken it away from you. Therefore, the
Speaker A
protection state is information that describes the permissions each person has on a specific object at a specific moment in time. Why? Permissions can be granted or revoked from any user at any time. Thus, any Discretionary Access Control model must represent three
Speaker A
things. I must have a representation of the current protection state. It must force me to only exercise the permissions I actually have. Any file I don't have permission for, I am forbidden from accessing. It also gives me the ability to modify. Since we said
Speaker A
at any particular moment, it means we have modify [capabilities]. Thus, the state can change via the operations available to me. So, every request is mediated. It says every request must pass through the enforcement controller . That is it; it says every request
Speaker A
must pass through the controller. How will this process work? First, there is a person or user who will request access to the file. For example, User A requests to write to File 1. In this case, it is a request. Then, I must
Speaker A
check: does this user actually have write permission for this file in the access control matrix? If they have permission, I say "fine, go ahead." If they don't have permission, I say " denied, you cannot write to this file."
Speaker A
Now, suppose I did what? I told them they don't have this permission. Do I just stay quiet and that's it? It says in this case, if I have a system or want to build a strong security system, I must send an alert to the
Speaker A
administrator or the system. There’s a person who, let's say, requested to write to a file. But they don’t have authorization to write to that file.
Speaker A
Consequently, I need to alert the system that I blocked a person from writing to the file because that person ...Because that person doesn't have the authorization to access the file. The protection state describes the set of information that defines what rights or
Speaker A
permissions a user has on a specific file or resource. At that exact moment, okay. By its name, it consists of three things. I have a representation of what permissions each person holds. We have enforcement; I must strictly constrain
Speaker A
the person. Always force the system, or have the system force the person, to only use the permissions they have. And you can give me modify, to change the permissions at another time. Okay, since we have enforcement, Since we
Speaker A
have enforcement, we say that for every request, the user must first request permission to access. If I check and find they have access permission, I tell them it's fine to write. If they don't have access permission, I tell
Speaker A
them, "Deny," okay. In the case that I say "deny," I must alert the system that an unauthorized access attempt to one of my resources has occurred. So, how can we modify the access control state? How can we modify it in
Speaker A
discretionary access control? First, there are the rights. As an owner, I can transfer rights to someone else, or grant a portion of these rights. Or, what else do I do? It mentions delete rights, remove an access right, to
Speaker A
delete the right. Meaning, I had previously granted you—which is revocation here. I had given you write permission, and now I want to remove it from you. Or read protection state, to be able to read the permission status I
Speaker A
have. I, as an owner, am one of the people who holds the right to access, read, or write to the existing file.
Speaker A
Now, regarding objects, they are the columns. I can create a new object, meaning I...I can create a new file and assign permissions to it. A file I wrote, I created it simply. I can delete the file. Once I delete the file
Speaker A
, I delete all permissions associated with it. From where? From the matrix table, from the access matrix. Okay, good. Actors or subjects: I, as a system administrator, can create a new subject, which is a new user. And assign their permissions. Consequently,
Speaker A
I have created a new row. Or perhaps I remove all permissions from this user.
Speaker A
And thus, remove the subject and its entries from where? From the table. So, we have control over access rights on three levels. The first level is rights . I, as the owner of the file, a file.
Speaker A
Okay, I can transfer my full permissions to someone else. I can grant them a portion of the permissions , like giving them read or write access , or revoke one of their permissions.
Speaker A
...like revoking read or write rights, and I also have access to know who has read or write permissions for the file I created, okay? Regarding the objects or entities or files I have. What are they? They are the files I have. They
Speaker A
are objects. Okay. I can create a new object and a new file. And grant permissions on it. Or delete the file.
Speaker A
And delete the permissions existing on it. As for subjects, I can create a new user. And grant them permissions. Or delete the user. Or suspend the user and remove all their permissions. Okay.
Speaker A
Of course, all this that we mentioned above, what about it? What is it governed by? By authorization rules.
Speaker A
What are the controls? Or what are the conditions I have set on whom? On the authorization I have in the system.
Speaker A
Okay. Well, Owner's Control and Copy Flags. I am the owner of the file. Okay . The system allows me to give other people permissions for this file. Since we are talking about, who?
Speaker A
Discretionary Access Control. So, what is the control? I can give authority to another person to read or write. Or I can give them permission to delete the file, naturally. Okay. Now, let's move on to the copy flags. Let's say, for
Speaker A
example, Read. I can give you Read in this format. Okay. Or give it to you with an asterisk next to it. In case I gave it to you with the asterisk, it means that as the file owner, when I
Speaker A
gave you this access control, I gave you the right to grant this access control to other people. It is transferable. Okay. You, as a person, can grant Read permission to other people just to read. Or you could also
Speaker A
let them read and let them give it to others. Is that clear? Meaning, if I, User A, have the right to read and pass the read right for the file, why? I have the asterisk. I gave it to User B.
Speaker A
But without the access, without the asterisk we have here. So, what happened to B? They are able to read the file, but they cannot grant the permission to whom? To C, they cannot grant permission to C, and therefore,
Speaker A
it reverses. Having the right to read the file does not mean I have the right to grant the read right to whom? To other people. Now let's talk about the Protection Domain. Okay, I have a set of objects, such as a database and a
Speaker A
file together, they have permission. That is, the ability to reach the objects. They have rights. Meaning, this group of files has one permission.
Speaker A
To access them. An access matrix row can represent a protection domain. The subject can represent a protection domain. In the case that we are talking about groups, okay. A process may operate with a subset of user permissions. The permission, it is
Speaker A
possible that if I have a process running, it might only have part of the permissions the user has. Different processes can be assigned different.
Speaker A
Domains, it is possible that a specific process or operations are, okay. Different operations have different permissions. Depending on what they need to access. And what are the resources it needs to control. The process domain might change, okay. The
Speaker A
scope of a process's authority can change based on what? Based on the operations it needs to perform.
Speaker A
Examples we have of protection domains. User mode and system mode or kernel mode. This protection domain, okay, allows me or helps me apply the principle of least privilege, so I can perform specific tasks on files? Okay.
Speaker A
Consequently, when we compare user mode and kernel mode, what does user mode run? Regular applications, okay. It has limitations on memory access, okay. And it cannot control others 'memory.
Speaker A
Prevent certain privileged instructions , okay. It prevents, okay, certain privileges from running. Or certain operations from running, okay. Between kernel mode and user mode, or OS mode as it's sometimes called, or system mode. What does it run? It runs
Speaker A
privileged operating system code, okay. It runs. For whom? Not for user applications. No, for operating system code, or sometimes I call it a system call. Okay. It can access protected memory as authorized. Okay. It can reach memory and delete someone, or
Speaker A
stop a file's execution. Like when I end a task from the Task Manager. Okay.
Speaker A
When I go to Task Manager, say I'm running a program, like Chrome. Normally, no other program can terminate the Chrome program. So, who can terminate the Chrome program? That would be the kernel mode. When I end Chrome from the Task Manager, it makes
Speaker A
a system call. To terminate the Chrome program. Okay. So, user program mode. Mode. Okay. My program in user mode is located in a protected area of memory.
Speaker A
Such that only specific entities can work on it. Or that only the authorized person can work on it. Any other use of this memory space, no one can reach it.
Speaker A
However, in kernel mode, when do we enter kernel mode? If my application calls a system code, the application enters kernel mode. As long as it is in kernel mode, I can access protected memory and I have the authority to do
Speaker A
whatever I want as a system or kernel mode; I must perform separation between operations. Okay, thank you.
Topics:discretionary access controlaccess control matrixaccess control listcapability listauthorizationprotection domainscopy flagoperating system securityrevoke permissionsfile permissions











