Shell History

Overview

Evidence: Shell History Description: Collect Shell History Category: System Platform: Linux Short Name: shellhis Is Parsed: Yes Sent to Investigation Hub: Yes Collect File(s): No

Background

Linux shell history provides records of executed commands and user activities. This data is essential for understanding user behavior, detecting malicious command execution, and investigating command-based security incidents.

Data Collected

This collector gathers structured data about shell history.

Shell History Data

Field
Description
Example

ID

Primary key (auto-increment)

1

Command

Executed command

ls -la

HistoryFile

History file path

/home/user/.bash_history

UserId

User ID who executed command

1000

Timestamp

Command execution timestamp

2023-10-15 14:30:25

Collection Method

This collector parses the necessary data from the shell_history table.

This collector collects files from the following locations:

  • ~/.bash_history

  • ~/.zsh_history

  • ~/.sh_history

Usage

This evidence is crucial for forensic investigations as it provides command execution information. It helps investigators understand user activities, detect malicious command execution, and investigate command-based attacks. The data can reveal executed commands, user behavior, and potential security incidents. Analysts can use this information to identify command compromises, trace user activities, and assess command security posture.

Notes

This data may contain sensitive information that should be handled according to data protection requirements. Ensure proper chain of custody is maintained during collection and analysis.

Last updated

Was this helpful?