We can use the Linux command, see harsh mod or change more to change permissions of the file or folder.
Uh, this is the common thing that people use in this next year when a root user or the files owner
can change permissions.
In this lecture, we use a C judgment to change permission on hash.
Get that he's seen that start using two different methods versus using numerical representation of permissions.
And then we use a symbolic representation.
Changing permissions with decimal notation, we can use a shortcut to refer now to permission by using
a symbol, a single number to represent one, our double helix set of permissions.
So like everything underlying the operating system, the permissions are represented in binary.
So on and off switches are represented by one and zero, respectively.
You can think of the RW X permissions on a string on off switches.
So when all the emissions are granted, this equates in a one on one in binary and binary sit like this
is them, then easily represented as one digit by converting it into a octal and each digit number system
that starts with zero and ensuites seven.
So and this represents a set of three binary digits, meaning we can represent an entire W P R W, except
with one just the one digit.
Uh, this can be zero one two three four five six seven eight seven, actually.
Lastly, 7.8.
So um.
Here I will create a table here for a better understanding here.
So in binary and here this is the binary here.
Uh, octal, octal.
And I will show you here is our W X.
Our top picks.
So the binary is zero, if binary zero zero zero octal is zero smell and RW, it's not read on or write
nor execute yet.
So if binary zero zero one here okodili, there's going to be one.
And this can be not really.
It's not right, but execute executable here.
If binary is zero one zero and octal is two, then this means this is them not readable but readable
and not executable here.
And if binary zero one one and octal is three, then this means.
This is not readable, but rewritable here and executable, if binary is one zero zero.
And this man in octal for.
So.
This means this is not treated, is sexual readable, not rewritable, nor executable.
And if there is one zero one, this means in Oakdale is five here and this is readable.
Um, this is readable.
Not right.
Bill and executable here.
And so readable.
Not readable and executable.
And here we have six and seven.
Lastly, one one zero equals just six in October by a system here, and this is the readable writable
executable here.
But if the binary is one three one one one one, and this means in Oakdale, we have seven here.
Um, and this is readable, right?
Well and executable as well.
So using this information, let's go through some examples.
First, if you want to set only the read permission, we called off the table and look at the value
for it.
For example, this is the read permission.
And this is the fourth.
We can declare this using four or just read, write, execute, or we can declare it in binary.
Next, if we want to set permission to write and execute, we could use the same methodology and look
for what's said and what sets the W and what system is which is executable and write about.
So as you can see here, no, we have our W X here.
So we want just write about the exhibit unexcusable.
And as you can see in Oakdale, this is them.
Three.
So the binary zero one one.
So.
Now we can, um, pass an argument here is a very short comment.
Come in.
So for example, let's, uh, create a new file or fear here of the Cuban section.
OK.
Uh, for example.
Torch here, uh, it's um.
Oh, what's?
Polls while.
Unless there, as you can see here, we create except for.
While this is not enough.
This has not incited any thing.
There's just a file with zero lights here.
So let's declare Ellis L.A. As you can see here, we have example file here, which is created by county.
So let's cheng this permission to, uh uh, let's see how much seven seven four hash, actually.
Example file.
Unless L.A. and as you can see here, we changed these permissions it.
So.
Uh, you shall see R W here, R W X R W E S R e r on the left side of the this example file.
So this confirms that that is, uh, see how someone can successfully change permission on the file
to give the both the owner and the group ability to execute the file.
So Europe's use of permission to protect users or groups files and directories from other users in the
system can be used for offensive and defensive purposes.
Little no, no.
Now know how to manage these permissions and how to exploit weak points in the security system.
In particular, Estudiantes guided.