CompTIA XK0-006 (CompTIA Linux+) Practice Test 65

Question 640

An interface receives 169.254.x.x but should get a DHCP address on a private subnet. What is the likely issue?

  1. Persistent network-manager profile
  2. Duplicate IP address assignment
  3. Routing metrics and policy routing
  4. Failed DHCP lease acquisition

Explanation

Correct Answer

D:

Link-local IPv4 addressing often indicates no usable DHCP lease. Verify broadcast reachability, client logs and server availability.

Incorrect Answers

A:

Transient ip address commands modify current kernel state but do not necessarily persist across boot; its scope differs from diagnosing an unexpected IPv4 link-local address, so it cannot meet the stated requirement.

B:

Two devices claiming one address can cause unstable ARP resolution and traffic delivery; that is not equivalent to diagnosing an unexpected IPv4 link-local address.

C:

Route selection and source rules determine egress paths, which may become asymmetric; the administrator instead needs diagnosing an unexpected IPv4 link-local address; this option serves a different purpose.

Question 641

A machine receives a warning that a repository's Release file changed identity unexpectedly. What is the safest reaction?

  1. Verify and import the approved repository signing key
  2. Validate repository identity before accepting the change
  3. Repository priority or package pinning
  4. Replace stale repository release URLs

Explanation

Correct Answer

B:

Unexpected metadata identity changes may signal configuration errors or repository compromise. Confirm the change through an authenticated vendor channel.

Incorrect Answers

A:

Package signature trust must be established using a verified key fingerprint; this does not achieve checking unanticipated package repository identity changes on the system described.

C:

Pinning and priorities constrain which sources and versions may satisfy updates; using it would leave checking unanticipated package repository identity changes unresolved.

D:

Package sources must match a supported distribution release or intended archive mirror; the requirement is checking unanticipated package repository identity changes, outside the effect of this choice.

Question 642

After enabling a third-party RPM repository, dnf refuses packages due to an unknown signing key. What should be done?

  1. Validate repository identity before accepting the change
  2. Repository priority or package pinning
  3. Host clock synchronization
  4. Replace stale repository release URLs
  5. Verify and import the approved repository signing key

Explanation

Correct Answer

E:

Package signature trust must be established using a verified key fingerprint. Bypassing GPG checks can admit tampered packages.

Incorrect Answers

A:

Unexpected metadata identity changes may signal configuration errors or repository compromise; the evidence calls for resolving package signature trust safely, not merely this separate operation.

B:

Pinning and priorities constrain which sources and versions may satisfy updates; the task involves resolving package signature trust safely, whereas this addresses another subsystem.

C:

TLS certificate validity depends on an accurate system clock; its scope differs from resolving package signature trust safely, so it cannot meet the stated requirement.

D:

Package sources must match a supported distribution release or intended archive mirror; that is not equivalent to resolving package signature trust safely.

Question 643

A newly deployed web app logs permission denied only when SELinux is enforcing, while Unix permissions appear correct. What should be checked first?

  1. Incorrect inherited or retained SELinux file labels
  2. Full filesystem relabel to policy defaults
  3. Relevant AVC denials and file contexts
  4. Applicable SELinux network-connect boolean

Explanation

Correct Answer

C:

SELinux may reject access independent of traditional permission bits. AVC logs and contexts show whether a policy or label mismatch is responsible.

Incorrect Answers

A:

Moved files can retain labels inconsistent with their new directory policy; it answers a neighboring question rather than distinguishing SELinux policy denial from mode bits.

B:

Files created without labeling enforcement may need contexts rebuilt; that changes a different part of the system; the requested outcome is distinguishing SELinux policy denial from mode bits.

D:

Policies can restrict which processes initiate outbound connections; it will not provide distinguishing SELinux policy denial from mode bits under these conditions.

Question 644

Two repositories publish the same package with incompatible dependencies; upgrades select the wrong source. What control can fix this?

  1. Replace stale repository release URLs
  2. Verify and import the approved repository signing key
  3. Repository priority or package pinning
  4. Validate repository identity before accepting the change

Explanation

Correct Answer

C:

Pinning and priorities constrain which sources and versions may satisfy updates. Changes should be reviewed to avoid holding back security fixes.

Incorrect Answers

A:

Package sources must match a supported distribution release or intended archive mirror; the requirement is selecting the intended package source predictably, outside the effect of this choice.

B:

Package signature trust must be established using a verified key fingerprint; it does not deliver selecting the intended package source predictably, which is decisive in this scenario.

D:

Unexpected metadata identity changes may signal configuration errors or repository compromise; the task involves selecting the intended package source predictably, whereas this addresses another subsystem.

Question 645

apt update fails with certificate verification errors on an HTTPS mirror, while system time is years behind. Which prerequisite should be corrected?

  1. Validate repository identity before accepting the change
  2. Verify and import the approved repository signing key
  3. Host clock synchronization
  4. Replace stale repository release URLs

Explanation

Correct Answer

C:

TLS certificate validity depends on an accurate system clock. Correcting time can restore repository certificate validation.

Incorrect Answers

A:

Unexpected metadata identity changes may signal configuration errors or repository compromise; that is not equivalent to resolving TLS errors caused by invalid system time.

B:

Package signature trust must be established using a verified key fingerprint; the administrator instead needs resolving TLS errors caused by invalid system time; this option serves a different purpose.

D:

Package sources must match a supported distribution release or intended archive mirror; that changes a different part of the system; the requested outcome is resolving TLS errors caused by invalid system time.

Question 646

After changing SELinux from disabled to enforcing, multiple previously unlabeled files cause denials. What recovery step is usually required?

  1. Full filesystem relabel to policy defaults
  2. Persistent semanage fcontext mapping
  3. Relevant AVC denials and file contexts
  4. SELinux type permits reads but not the requested writes

Explanation

Correct Answer

A:

Files created without labeling enforcement may need contexts rebuilt. Plan a controlled relabel and verify service behavior afterward.

Incorrect Answers

B:

chcon changes current labels but a later relabel can restore policy-defined defaults; using it would leave rebuilding labels after enabling SELinux unresolved.

C:

SELinux may reject access independent of traditional permission bits; the requirement is rebuilding labels after enabling SELinux, outside the effect of this choice.

D:

SELinux types distinguish read-only content from writable service data; it does not deliver rebuilding labels after enabling SELinux, which is decisive in this scenario.

Question 647

An HTTP daemon cannot connect to its backend despite open firewall ports, and an AVC reports name_connect denied. What should be reviewed?

  1. Applicable SELinux network-connect boolean
  2. Full filesystem relabel to policy defaults
  3. SELinux type permits reads but not the requested writes
  4. Persistent semanage fcontext mapping

Explanation

Correct Answer

A:

Policies can restrict which processes initiate outbound connections. A suitable boolean may permit the expected behavior without disabling enforcement.

Incorrect Answers

B:

Files created without labeling enforcement may need contexts rebuilt; its scope differs from authorizing outbound web-daemon connections under policy, so it cannot meet the stated requirement.

C:

SELinux types distinguish read-only content from writable service data; that is not equivalent to authorizing outbound web-daemon connections under policy.

D:

chcon changes current labels but a later relabel can restore policy-defined defaults; the administrator instead needs authorizing outbound web-daemon connections under policy; this option serves a different purpose.

Question 648

A named user has ACL rw-, but the ACL display marks effective permissions as r--. Which control is limiting access?

  1. Existing process retained its original group credentials
  2. ACL mask entry
  3. Numeric UID ownership mismatch
  4. Sticky bit on shared directory
  5. Execute/search permission on the directory

Explanation

Correct Answer

B:

The ACL mask caps effective permissions for named users and group-class entries. Extending an individual entry alone may not grant the intended write access.

Incorrect Answers

A:

Group memberships are captured when credentials are established for a process; that changes a different part of the system; the requested outcome is diagnosing an ACL permission-mask limitation.

C:

Filesystems record numeric IDs, so matching usernames alone is not sufficient after restoring data across hosts; it will not provide diagnosing an ACL permission-mask limitation under these conditions.

D:

Write and execute on a directory normally permit removing entries regardless of file ownership; using it would leave diagnosing an ACL permission-mask limitation unresolved.

E:

Directory execute grants traversal and pathname lookup, while read permits listing names; the requirement is diagnosing an ACL permission-mask limitation, outside the effect of this choice.

Question 649

A system service runs as uid 1002 after a migration, but restored files are owned by uid 2002. Why is access unexpectedly denied?

  1. Execute access on each parent directory
  2. Numeric UID ownership mismatch
  3. Execute/search permission on the directory
  4. ACL mask entry

Explanation

Correct Answer

B:

Filesystems record numeric IDs, so matching usernames alone is not sufficient after restoring data across hosts. Align identity mappings or ownership safely.

Incorrect Answers

A:

Path traversal requires search permission on every ancestor component; it does not deliver correcting numeric ownership differences, which is decisive in this scenario.

C:

Directory execute grants traversal and pathname lookup, while read permits listing names; the task involves correcting numeric ownership differences, whereas this addresses another subsystem.

D:

The ACL mask caps effective permissions for named users and group-class entries; its scope differs from correcting numeric ownership differences, so it cannot meet the stated requirement.

Question 650

SSH accepts the server connection but rejects the user's public key; authorized_keys is correct. Which file-protection issue should be checked?

  1. KbdInteractiveAuthentication and PAM settings
  2. Source-restricted SSH firewall policy
  3. Present the intermediate CA chain
  4. Unsafe home or .ssh permissions under StrictModes
  5. Renew and deploy the correct certificate chain
  6. Private CA trust anchor on clients

Explanation

Correct Answer

D:

OpenSSH may refuse key authentication if relevant files or directories are writable by untrusted users. Verify ownership and restrictive permissions.

Incorrect Answers

A:

Disabling PasswordAuthentication alone may leave other interactive authentication methods active; the administrator instead needs fixing SSH key rejection due to unsafe file modes; this option serves a different purpose.

B:

A firewall may drop inbound packets by source or interface; it answers a neighboring question rather than fixing SSH key rejection due to unsafe file modes.

C:

Even a trusted root may not be connected to the leaf without the right intermediate certificates; that changes a different part of the system; the requested outcome is fixing SSH key rejection due to unsafe file modes.

E:

Expiry checks reject otherwise functional TLS services after the validity window ends; it will not provide fixing SSH key rejection due to unsafe file modes under these conditions.

F:

Clients need the internal issuing chain anchored in an approved trust store; using it would leave fixing SSH key rejection due to unsafe file modes unresolved.

CompTIA Linux+ (XK0-006) Practice Tests