Implemented Windows Version fingerprinting

This commit is contained in:
Jakob Friedl
2025-05-21 14:06:04 +02:00
parent c55a9f9443
commit 71336a6fa7
8 changed files with 161 additions and 26 deletions

View File

@@ -101,7 +101,7 @@ proc agentInteract*(cq: Conquest, name: string) =
cq.writeLine(fgYellow, "[+] ", resetStyle, fmt"Started interacting with agent ", fgYellow, agent.name, resetStyle, ". Type 'help' to list available commands.\n")
cq.interactAgent = agent
while command != "exit":
while command != "back":
command = cq.readLine()
cq.withOutput(handleAgentCommand, command)

View File

@@ -13,7 +13,7 @@ var parser = newParser:
command("help"):
nohelpflag()
command("exit"):
command("back"):
nohelpflag()
proc handleAgentCommand*(cq: Conquest, args: varargs[string]) =
@@ -29,7 +29,7 @@ proc handleAgentCommand*(cq: Conquest, args: varargs[string]) =
case opts.command
of "exit": # Exit program
of "back": # Return to management mode
discard
of "help": # Display help menu

View File

@@ -5,7 +5,5 @@ var cq*: Conquest
# Colors
# https://colors.sh/
# TODO Replace all colored output with custom colors
const yellow* = "\e[48;5;232m"
const red* = "\e[210;66;79m"
const resetColor* = "\e[0m"

View File

@@ -75,9 +75,14 @@ proc drawTable*(cq: Conquest, agents: seq[Agent]) =
cq.writeLine(row(headers, widths))
cq.writeLine(border(midLeft, midMid, midRight, widths))
# TODO: Highlight elevated processes
for a in agents:
let row = @[a.name, a.ip, a.username, a.hostname, a.os, a.process, $a.pid]
cq.writeLine(row(row, widths))
# Highlight agents running within elevated processes
if a.elevated:
cq.writeLine(bgRed, fgBlack, row(row, widths))
else:
cq.writeLine(row(row, widths))
cq.writeLine(border(botLeft, botMid, botRight, widths))