nerdexam
GIAC

GSEC · Question #387

An employee is currently logged into the corporate web server, without permission. You log into the web server as 'admin" and look for the employee's username: "dmaul" using the "who" command. This…

The correct answer is B. The contents of the bash history file has been altered. When a logged-in user does not appear in expected system records, it indicates a log or history file has been tampered with to conceal their activity.

Linux and Cryptography

Question

An employee is currently logged into the corporate web server, without permission. You log into the web server as 'admin" and look for the employee's username: "dmaul" using the "who" command. This is what you get back:

Options

  • AThe contents of the /var/log/messages file has been altered
  • BThe contents of the bash history file has been altered
  • CThe contents of the utmp file has been altered
  • DThe contents of the http logs have been altered

How the community answered

(58 responses)
  • A
    3% (2)
  • B
    74% (43)
  • C
    16% (9)
  • D
    7% (4)

Why each option

When a logged-in user does not appear in expected system records, it indicates a log or history file has been tampered with to conceal their activity.

AThe contents of the /var/log/messages file has been altered

The /var/log/messages file records general system and kernel messages and would not directly reflect or hide an active user session found via the 'who' command.

BThe contents of the bash history file has been alteredCorrect

The bash history file (~/.bash_history) records commands executed by a user in the shell, and an attacker or unauthorized user may alter or clear it to remove evidence of their actions on the system. If the admin observes evidence of a session but finds the bash history empty or missing entries, it indicates the contents were deliberately altered. This is a common anti-forensic technique used to hide unauthorized access and command execution.

CThe contents of the utmp file has been altered

The utmp file is what the 'who' command reads to display currently logged-in users; if utmp were altered, the user would not appear in 'who' output at all, which contradicts the scenario.

DThe contents of the http logs have been altered

HTTP access logs record web requests to the server and are unrelated to recording or concealing an interactive shell session by a logged-in user.

Concept tested: Linux log file tampering and anti-forensic techniques

Source: https://linux.die.net/man/5/utmp

Topics

#bash history#log tampering#Linux forensics#intrusion indicators

Community Discussion

No community discussion yet for this question.

Full GSEC Practice