Prompt
Analyze a custom application login event log to help us understand user behavior.
login.log256.1KB
Walk-Through
This challenge involves analyzing a custom application log format that uses tab-delineated columns. The tab-delineated format is well-suited for the cut
tool to extract specific columns from the log. cut
can be used combination with several other Linux command line utilities to obtain the answers to the questions.
Questions
Q1. How many total login attempts were made in this log?
cat login.log | wc -l
Q2. How many unique usernames appear in this log?
cat login.log | cut -f 3 | sort | uniq | wc -l
Q3. What is the username with the most login attempts?
cat login.log | cut -f 3 | sort | uniq -c |sort -n
Q4. How many attempts were made for the username with the most login attempts?
Use the same command as the question above
Q5. What is the date with the most login attempts?
cat login.log | cut -f 1 | cut -d " " -f 1 | sort | uniq -c | sort -n
Q6. What is the username that had logins from the most unique IP addresses?
cat login.log | cut -f 2,3 | sort | uniq | cut -f 2 | sort | uniq -c | sort -n
©️ 2024 Cyber Skyline. All Rights Reserved. Unauthorized reproduction or distribution of this copyrighted work is illegal.