Analyzing auth.log and Playing with Grok Filters - HTB Sherlocks - Brutus

IppSec · Beginner ·🛡️ AI Safety & Ethics ·1y ago
00:00 - Introduction 02:10 - Going over the wtmp file, showing utmpdump and last 04:30 - Start of talking about the auth.log, grabbing all the programs (ssh, cron, etc) so we know what is in the log 08:15 - Question 1: Identify the bruteforce use grep with oP to extract all IP Addresses with login failures 11:50 - Question 2: Looking at successful logins and seeing the malicious IP logged into root 12:45 - Question 3: Looking at login/logoff times, getting the login time from wtmp as it is 1 second after the login 15:15 - Question 4: Grabbing the session number from logins which is part of sys…
Watch on YouTube ↗ (saves to browser)

Chapters (20)

Introduction
2:10 Going over the wtmp file, showing utmpdump and last
4:30 Start of talking about the auth.log, grabbing all the programs (ssh, cron, etc
8:15 Question 1: Identify the bruteforce use grep with oP to extract all IP Address
11:50 Question 2: Looking at successful logins and seeing the malicious IP logged in
12:45 Question 3: Looking at login/logoff times, getting the login time from wtmp as
15:15 Question 4: Grabbing the session number from logins which is part of systemd-l
18:00 Question 5: Finding the useradd line in the auth.log file
19:00 Question 6: Looking at the MITRE Attack Framework and getting the ID-related t
20:10 Question 7: Using Last to look at how long a session was active for
21:25 Question 8: Sudo is the only program in auth.log showing commands being ran,
23:10 BEYOND ROOT: Talking about how we can create grok filters to convert this log
27:30 Using an online Grok Debugger to manually create a Grok Rule, this is like reg
32:00 Showing how to do an "Optional Match" so we can match lines that are mostly al
33:20 Start of creating our program, showing how to add patterns and definitions
42:50 Adding SSH_AUTH to our program
44:40 Adding the New/Remove session lines to a grok filter
53:30 Reading the auth.log in our golang program so we can parse all the lines we cr
54:40 Using JQ to do some searches and create the desired output
1:02:30 Doing some lazy searching with JQ and grep

Playlist

Uploads from IppSec · IppSec · 0 of 60

← Previous Next →
1 HHC2016 - Dungeon
HHC2016 - Dungeon
IppSec
2 HHC2016 - Terminal Speedrun
HHC2016 - Terminal Speedrun
IppSec
3 HHC2016 - Ads
HHC2016 - Ads
IppSec
4 HHC2016 - Debug
HHC2016 - Debug
IppSec
5 HHC2016 - Exception
HHC2016 - Exception
IppSec
6 HHC2016 - Analytics
HHC2016 - Analytics
IppSec
7 HHC2016 - Getting Coins
HHC2016 - Getting Coins
IppSec
8 HackTheBox - Popcorn
HackTheBox - Popcorn
IppSec
9 HackTheBox - October
HackTheBox - October
IppSec
10 HackTheBox - Arctic
HackTheBox - Arctic
IppSec
11 HackTheBox  - Tenten
HackTheBox - Tenten
IppSec
12 HackTheBox - CronOS
HackTheBox - CronOS
IppSec
13 HackTheBox - Brainfuck
HackTheBox - Brainfuck
IppSec
14 HackTheBox - Beep
HackTheBox - Beep
IppSec
15 HackTheBox - Bastard
HackTheBox - Bastard
IppSec
16 HackTheBox - Bank
HackTheBox - Bank
IppSec
17 HackTheBox - Joker
HackTheBox - Joker
IppSec
18 HackTheBox - Haircut
HackTheBox - Haircut
IppSec
19 HackTheBox - Lazy
HackTheBox - Lazy
IppSec
20 Camp CTF 2015 - Bitterman
Camp CTF 2015 - Bitterman
IppSec
21 HackTheBox - Devel
HackTheBox - Devel
IppSec
22 Reversing Malicious Office Document (Macro) Emotet(?)
Reversing Malicious Office Document (Macro) Emotet(?)
IppSec
23 HackTheBox - Granny and Grandpa
HackTheBox - Granny and Grandpa
IppSec
24 HackTheBox - Pivoting Update: Granny and Grandpa
HackTheBox - Pivoting Update: Granny and Grandpa
IppSec
25 HackTheBox - Optimum
HackTheBox - Optimum
IppSec
26 HackTheBox - Charon
HackTheBox - Charon
IppSec
27 HackTheBox - Sneaky
HackTheBox - Sneaky
IppSec
28 HackTheBox - Holiday
HackTheBox - Holiday
IppSec
29 HackTheBox - Apocalyst
HackTheBox - Apocalyst
IppSec
30 HackTheBox - Europa
HackTheBox - Europa
IppSec
31 Introduction to tmux
Introduction to tmux
IppSec
32 HackTheBox - Blocky
HackTheBox - Blocky
IppSec
33 HackTheBox - Nineveh
HackTheBox - Nineveh
IppSec
34 HackTheBox - Jail
HackTheBox - Jail
IppSec
35 HackTheBox - Blue
HackTheBox - Blue
IppSec
36 HackTheBox - Calamity
HackTheBox - Calamity
IppSec
37 HackTheBox - SolidState
HackTheBox - SolidState
IppSec
38 HackTheBox - Shrek
HackTheBox - Shrek
IppSec
39 HackTheBox - Mirai
HackTheBox - Mirai
IppSec
40 HackTheBox - Shocker
HackTheBox - Shocker
IppSec
41 HackTheBox - Mantis
HackTheBox - Mantis
IppSec
42 HackTheBox - Node
HackTheBox - Node
IppSec
43 HackTheBox - Kotarak
HackTheBox - Kotarak
IppSec
44 HackTheBox - Enterprise
HackTheBox - Enterprise
IppSec
45 HackTheBox - Sense
HackTheBox - Sense
IppSec
46 HackTheBox - Minion
HackTheBox - Minion
IppSec
47 VulnHub - Sokar
VulnHub - Sokar
IppSec
48 VulnHub - Pinkys Palace v2
VulnHub - Pinkys Palace v2
IppSec
49 HackTheBox - Inception
HackTheBox - Inception
IppSec
50 Vulnhub - Trollcave 1.2
Vulnhub - Trollcave 1.2
IppSec
51 HackTheBox - Ariekei
HackTheBox - Ariekei
IppSec
52 HackTheBox - Bashed
HackTheBox - Bashed
IppSec
53 HackTheBox - Flux Capacitor
HackTheBox - Flux Capacitor
IppSec
54 HackTheBox - Jeeves
HackTheBox - Jeeves
IppSec
55 HackTheBox - Tally
HackTheBox - Tally
IppSec
56 HackTheBox - CrimeStoppers
HackTheBox - CrimeStoppers
IppSec
57 HackTheBox - Fulcrum
HackTheBox - Fulcrum
IppSec
58 HackTheBox - Chatterbox
HackTheBox - Chatterbox
IppSec
59 HackTheBox - Falafel
HackTheBox - Falafel
IppSec
60 HackTheBox - Nibbles
HackTheBox - Nibbles
IppSec
Why You’re Still Better Than AI at Editing Documents - CS50 Tech Talk
Next Up
Why You’re Still Better Than AI at Editing Documents - CS50 Tech Talk
CS50 (Harvard)