Courseiva
mediumMultiple ChoiceObjective-mapped

XK0-006 Practice Question: A security audit reveals that the /var/log…

A security audit reveals that the /var/log directory has permissions 777. Which command should restore secure permissions, assuming the owner is root and group is adm?

⚠ Common exam trap

A common mix-up: candidates choose 750 thinking it is more secure, but the XK0-005 exam expects the standard Linux permission of 755 for /var/log to maintain compatibility with common log-reading utilities and the adm group's intended read access.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

chmod 755 /var/log

/var/log typically contains sensitive system logs, and permissions of 755 (owner: rwx, group: r-x, others: r-x) allow the root owner full access, the adm group read/execute access (needed for log reading tools), and others read-only access without write permissions. This aligns with security best practices where only root should write to /var/log, and the 777 permission from the audit is overly permissive and a security risk.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • chmod 777 /var/log

    Why it's wrong here

    World-writable, which is the current insecure state.

  • chmod 755 /var/log

    Why this is correct

    Sets permissions to rwxr-xr-x, appropriate for a shared log directory.

  • chmod 700 /var/log

    Why it's wrong here

    Only owner has access, too restrictive for system logs.

  • chmod 750 /var/log

    Why it's wrong here

    Denies read access to others, which may break some services.

About these practice questions

Courseiva writes every XK0-006 question from scratch — 979 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This XK0-006 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the XK0-006 exam.