(A) chmod go-rwx
Removing the rwx permissions for groups and owners (go) would make it so ONLY the root user can modify and execute the script.
*running "chmod u=rwx" would change nothing and script's permissions would STILL be 777.
Ignore last
777
Which of the following is the MOST appropriate command to ensure only the root user can modify and execute the script?
A. chmod go-rwx
B. chmod u=rwx
C. chmod u+wx
D. chmod g-rwx
chmod go-rwx: This command would remove read, write, and execute permissions for group and others but would leave the owner's permissions unchanged. If the owner is not root, this does not achieve the desired outcome.
B. chmod u=rwx
This command sets the permissions for the user (owner) to read, write, and execute (rwx) while removing all permissions for the group and others. After executing this command, the permissions would be changed from 777 to 700, meaning only the root user can access and modify the script.
A. chmod go-rwx
"chmod" is the command used to change the file's mode bits.
"go-rwx" specifies that both group (g) and others (o) should have read (r), write (w), and execute (x) permissions removed (-).
This command removes the read, write, and execute permissions from both the group and others, leaving only the user (assuming the root is the owner) with the ability to read, write, and execute the script. This makes the script's permissions 700 in octal notation, ensuring that only the root user (assuming root owns the file) can modify and execute the script.
But we don't have the g=,o= in the available options. Using just "u=rwx" is not going to remove the permissions from group and the others therefore we should remove it with the A: chmod go-rwx
The octal notation "777" represents full permissions (read, write, and execute) for the owner, group, and others. To ensure only the root user can modify and execute the script, we need to remove write and execute permissions for group and others while keeping the same permissions for the owner. Therefore, the most appropriate command would be:
B. chmod u=rwx,g=,o= script_file
This command sets the owner's permissions to read, write, and execute (u=rwx) while removing all permissions for the group (g=) and others (o=), effectively restricting modification and execution to the root user only.
Nope, it's A which removes read write and execute from group and others.
upvoted 1 times
...
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Stache
1 week, 2 days agocj207800
1 week, 3 days agocj207800
1 week, 4 days agocj207800
1 week, 4 days agosurfuganda
10 months agoK1lroy
1 year, 4 months agocomptiaboy
1 year, 8 months agoMareo
1 year, 9 months agoccoli
5 months, 2 weeks ago