exam questions

Exam XK0-005 All Questions

View all questions & answers for the XK0-005 exam

Exam XK0-005 topic 1 question 60 discussion

Actual exam question from CompTIA's XK0-005
Question #: 60
Topic #: 1
[All XK0-005 Questions]

Based on an organization’s new cybersecurity policies, an administrator has been instructed to ensure that, by default, all new users and groups that are created fall within the specified values below.

To which of the following configuration files will the required changes need to be made?

  • A. /etc/login.defs
  • B. /etc/security/limits.conf
  • C. /etc/default/useradd
  • D. /etc/profile
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
TheRealManish
Highly Voted 2 years, 1 month ago
Selected Answer: A
This answer is wrong, cat out your /etc/login.defs file. those values are in there
upvoted 6 times
...
BryanSME
Most Recent 12 months ago
linux_admin has it right: A is definitely correct, it's all right here, a quick look into the file shows below: cat /etc/login.defs yields: ... # Min/max values for automatic uid selection in useradd # UID_MIN 1000 UID_MAX 60000 # System accounts SYS_UID_MIN 201 SYS_UID_MAX 999 # # Min/max values for automatic gid selection in groupadd # GID_MIN 1000 GID_MAX 60000 # System accounts SYS_GID_MIN 201 SYS_GID_MAX 999
upvoted 2 times
...
Tricee
1 year, 1 month ago
I can definitely understand why etc/default/useradd would be the answer. The question specifically stated that the users and groups were added "by default".
upvoted 1 times
...
linux_admin
1 year, 10 months ago
Selected Answer: A
The /etc/login.defs file is used to set default system-wide settings for new users and groups. This file contains information about user and group creation, such as the default home directory, the default shell, the minimum and maximum UIDs and GIDs, and so on. If the administrator needs to set default values for new users and groups that are created, they would need to make the required changes in the /etc/login.defs file. For example, to set the default home directory for new users to /home/users/, the administrator would add the following line to the file:
upvoted 3 times
linux_admin
1 year, 10 months ago
HOME /home/users/ The /etc/login.defs file is the correct configuration file to make changes to the default values for new users and groups. Other configuration files, such as /etc/security/limits.conf (used to set limits on resource utilization), /etc/default/useradd (used to set default options for the useradd command), or /etc/profile (used to set environment variables for users), are not used for this purpose.
upvoted 3 times
...
...
alimakkaya
1 year, 11 months ago
Selected Answer: C
Question asks about newly created users . The file to be edited should be /etc/adduser.conf. And below is the section to be edited. # FIRST_[GU]ID to LAST_[GU]ID inclusive is the range of UIDs of dynamically # allocated user accounts/groups. FIRST_UID=1000 LAST_UID=29999 FIRST_GID=1000 LAST_GID=29999
upvoted 1 times
alimakkaya
1 year, 11 months ago
never mind . just delete the post, I got it wrong.
upvoted 1 times
...
...
Nvoid
2 years ago
Selected Answer: A
It's A.
upvoted 1 times
Nvoid
2 years ago
Mod plz update the answer its A.
upvoted 2 times
Nvoid
2 years ago
mods still need to update!
upvoted 2 times
...
...
...
MrGykz
2 years, 1 month ago
Selected Answer: A
https://man7.org/linux/man-pages/man5/login.defs.5.html reading default page for login.defs u can find these values written up : " SYS_UID_MAX (number), SYS_UID_MIN (number) Range of user IDs used for the creation of system users by useradd or newusers. "
upvoted 1 times
...
Veteran903
2 years, 1 month ago
I dont understand how this can be wrong, correct answer is A, please fix it!
upvoted 2 times
...
MissAllen
2 years, 1 month ago
Sorry, I agree with answer A, /etc/login.defs.
upvoted 3 times
...
MissAllen
2 years, 1 month ago
Agreed, answer C.
upvoted 1 times
Nvoid
2 years ago
it is not C, it's A!
upvoted 1 times
...
...
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.

SaveCancel
Loading ...