Added monarch agent
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import terminal, strformat, strutils, tables
|
||||
import ./commands
|
||||
import ./interact
|
||||
import ../[types, globals, utils]
|
||||
import ../db/database
|
||||
|
||||
@@ -131,11 +131,4 @@ proc register*(agent: Agent): bool =
|
||||
cq.add(agent)
|
||||
cq.writeLine(fgYellow, styleBright, fmt"[{agent.firstCheckin}] ", resetStyle, "Agent ", fgYellow, styleBright, agent.name, resetStyle, " connected to listener ", fgGreen, styleBright, agent.listener, resetStyle, ": ", fgYellow, styleBright, fmt"{agent.username}@{agent.hostname}", "\n")
|
||||
|
||||
return true
|
||||
|
||||
#[
|
||||
Agent interaction mode
|
||||
When interacting with a agent, the following functions are called:
|
||||
- addTask, to add a new tasks to the agents task queue
|
||||
- getTaskResult, get the result for the task from the agent
|
||||
]#
|
||||
return true
|
||||
@@ -2,7 +2,7 @@ import argparse, times, strformat, terminal
|
||||
import ../[types]
|
||||
|
||||
#[
|
||||
Agnet Argument parsing
|
||||
Agent Argument parsing
|
||||
]#
|
||||
var parser = newParser:
|
||||
help("Conquest Command & Control")
|
||||
@@ -44,4 +44,11 @@ proc handleAgentCommand*(cq: Conquest, args: varargs[string]) =
|
||||
except UsageError:
|
||||
cq.writeLine(fgRed, styleBright, "[-] ", getCurrentExceptionMsg())
|
||||
|
||||
cq.writeLine("")
|
||||
cq.writeLine("")
|
||||
|
||||
proc createTask*(args: varargs[string]): Task =
|
||||
discard
|
||||
|
||||
proc addTask*(cq: Conquest, agent: Agent, task: Task) =
|
||||
discard
|
||||
|
||||
Reference in New Issue
Block a user