Inside Wardline: Building an In-House SIEM

Arbias Hajdari
3 Dec 2026 — 13 min read

Share

How Siri’s Cache Exposed Contact Data Without Permission

Albin Haliti investigates CVE-2026-86984: how Siri inference databases exposed contact metadata outside macOS Contacts consent, and how Apple addressed the privacy gap.

Cyber Academy

Silver biomechanical sentinel beetle on a black background, illustrating Wardline SIEM threat detection. Technical Blog by Arbias Hajdari.

Introduction

An alert from Wardline on one of the company laptops led to a process that was mining cryptocurrency in the background, using the machine’s processor for someone else’s profit. The laptop’s owner had not noticed it. Wardline is a SIEM (security information and event management system): it gathers security events from every machine into one place and turns the suspicious ones into alerts. It was designed and built in-house by Cyber Academy student Arbias Hajdari and runs in production at the company where he works.

The company runs on bring-your-own-device (BYOD): every employee works from a personal macOS or Windows laptop. Before Wardline, there was no central record of logins, process launches or network activity on those laptops, no alert when one of them was compromised, and no baseline to tell an ordinary day from an attack. The commercial platforms that were evaluated would have closed part of that gap, but only by sending telemetry from employees’ personal devices to an outside service whose detection logic could not be inspected. Wardline was built to close those gaps on the company’s own terms: monitoring only while a laptop is at the office, with all collected data stored on a server the company runs.

This article covers the constraints that make personal laptops hard to monitor, how Wardline’s agent, detection engine and console are built, and how its detections work, using production rules for password brute force and cryptomining tested against the real engine. It then shows how the same data exposes vulnerable software before attackers find it, and how offensive training shaped the detections.

What makes monitoring personal laptops hard

Three kinds of constraint shaped Wardline’s design.

Technical: no single point of visibility

Personal laptops have no device-management profile, no standard image and no shared configuration. macOS and Windows expose security events through entirely different interfaces, and neither records what a SIEM needs out of the box. On macOS, process launches with their full command lines come from Apple’s Endpoint Security framework, which only works after the user grants Full Disk Access. On Windows, process creation (event 4688) is not logged at all until the matching audit policy is enabled. Laptops also sleep, change networks and drop offline in the middle of the day, so events have to survive gaps in connectivity. With traffic split between home networks, cafés and the office, no single network sensor sees everything.

Operational: nobody watching full-time

There is no security operations centre and no analyst on shift. Every alert has to be worth reading, because a queue full of noise is quickly ignored. Response has to work remotely and safely: isolating a laptop must not lock out the people trying to fix it, and a response channel into employees’ devices must never become a remote shell for whoever compromises the server. Agent updates have to be trustworthy, because they run on machines the company does not own.

Privacy: the devices belong to employees

Monitoring a personal laptop around the clock would mean monitoring its owner’s private life. Data-protection law points the same way: the purpose-limitation and data-minimisation principles in Article 5 of the GDPR, the model for most European data-protection laws, limit collection to a clear purpose and to the data that purpose needs, which rules out recording what an employee does at home. The same laptop holds private messages, documents and photos next to company work, so even at the office the collection has to stay narrow: security events such as logins, process launches and network connections, never the content of files or messages. A boundary like this holds only if the system itself enforces it, and the agent described below is built to do so.

When building a SIEM beats buying one

For most organisations, buying is the right answer: a commercial platform brings years of detection content, vendor support and someone else to maintain it. Building only wins when all four conditions in Table 1 hold, as they did here.

Table 1: When building a SIEM in-house makes sense
ConditionWhat it means in practice
The environment is well understoodA known set of operating systems, cloud tenants and network devices that one engineer can model completely.
Transparency matters more than breadthEvery detection is a readable file that can be reviewed, tested and changed in minutes.
Data has to stay in-houseTelemetry from personal devices never leaves infrastructure the company controls.
Someone will own itMaintenance and detection quality rest with the people who built the system.

How Wardline is built: agents, engine and console

Wardline has three layers: agents that collect events, an engine that decides what is suspicious, and a console where people work. Figure 1 shows how they connect.

Architecture diagram: laptops with Go agents, cloud accounts and network devices send events to the detection engine; the engine sends alerts to the console and triggers response playbooks, which act back on the laptops.
Figure 1: Wardline’s architecture: events flow into the detection engine, alerts go to the console, and playbooks act back on the laptops.

The agent

The agent is written in Go and runs on macOS, Windows and Linux. Before collecting anything, it checks where it is. It identifies the office by the MAC address of the default gateway, read from the ARP table, instead of Wi-Fi names or IP ranges that thousands of home routers share. The check fails closed: any doubt counts as “not in the office”, and outside the office the agent collects nothing. The server enforces the same rule and tells an agent to stop if it reports from elsewhere. Table 2 lists what the agent collects once the check passes.

Table 2: What the agent collects on each platform
PlatformSourceExamples
macOSEndpoint Security via eslogger (with ps polling until Full Disk Access is granted) and the unified logEvery process launch with full arguments; logins, sudo and SSH
WindowsSecurity, System and Defender event logs; the agent backs up the audit policy, then enables the subcategories it needsLogons 4624/4625, process creation 4688, account and group changes 4720/4732, log clearing 1102/104, new services 7045, Defender 1116/1117/5001
AllThe agent’s own checksFile integrity, USB devices, listening ports, local administrators, software inventory, 26 configuration checks

Transport is built to survive a hostile network. Connections use TLS 1.2 or later, pinned to the server’s certificate or public key, so a fake server on the office network cannot impersonate Wardline. An agent enrols with a one-time token or an enrolment secret that is compared in constant time and rate-limited; it then receives its own key, which the server stores only as a hash. Events wait in a queue of up to 5,000 and are sent every 5 seconds in batches of up to 500. A heartbeat goes out every 30 seconds, and the agent asks for pending response actions every 10. Agent updates are signed with Ed25519; the agent installs one only if the signature verifies and the build is exactly the newer version offered, so an old signed build cannot be replayed.

The agent also plants two hidden decoy documents in each user’s Documents and Desktop folders, named so they sort first, where ransomware tends to start encrypting. They are checked every 3 seconds. If one is modified or renamed, or two disappear within a minute, the agent raises a critical event and can isolate the laptop on its own, without waiting for the server.

The detection engine

The server is a Python (FastAPI) application. Incoming events enter a bounded queue, and a single worker stores each one and runs detection on it. Every event is normalised into one schema: time, host, user, source and destination address, category, action, and event-specific fields under data. Storage is SQLite in write-ahead-log mode, so searches run on read-only connections beside ingestion. Events are kept for 30 days and alerts for 180 by default.

The rule engine loads 113 YAML rules mapped to MITRE ATT&CK v20. A rule can match fields exactly, by substring, prefix, suffix or regular expression, by numeric or network range, or by whether a field exists; count events or distinct values inside a time window; fire only after another alert on the same laptop and account; flag a value seen for the first time; and merge repeats inside a suppression window. Around the rules sit three further layers. Threat-intelligence indicators (addresses, networks, domains and file hashes) are checked against every event. A risk score accumulates per device, user and address, weighted by how critical the device is, and raises RISK-001 past a threshold. Behavioural analytics (UEBA) keeps 14-day baselines per user and device, such as login hours, event rate, process names and DNS domains; a deviation of 2.5 standard deviations scores 1.0, an alert needs 0.75, and nothing is scored before 15 samples exist.

Laptops are not the only source. Firewall, DNS and IDS logs arrive over syslog (RFC 3164 and 5424), accepted only from listed senders. Microsoft 365 and Google Workspace sign-ins are pulled by a separate collector and pushed inward, because the server itself never connects out. The server also listens on canary ports for FTP, Telnet, RDP, MSSQL and WinRM. Nothing legitimate in the office uses them, so any connection means someone is scanning the network from the inside.

Responding without a remote shell

An administrator can isolate a laptop, stop a process, quarantine a file or run a Defender scan, re-entering their password to confirm. The agent picks the action up within about 10 seconds. Isolation cuts every connection except to the Wardline server, the router and the loopback interface, using a pf anchor on macOS and the firewall profiles on Windows, and existing connections are dropped so an open remote shell dies with them. There is deliberately no remote shell in Wardline itself: the agent checks every action against lists of things it never touches, such as system processes, system folders and the agent itself, so even a compromised server cannot turn the response channel into remote code execution. Playbooks chain these actions with notifications and case creation, and destructive steps can be set to wait for approval.

The console

The console is a single-page web application in Albanian and English. Its search language, RQL, reads like Splunk and compiles into parameterised SQL, so a query such as category=auth action=login_failed | stats count by user can never inject into the database. The incident queue ranks alerts by urgency, which is the rule’s severity raised or lowered by how critical the device is. Access is split into viewer, analyst and administrator roles with two-factor authentication.

The screenshots come from a demonstration instance with sample data and fictional names.

Wardline home view showing an alert timeline by severity over 30 days, urgent incidents, event count, top risk scores, a configuration score and incidents waiting for triage.
Figure 2: The home view over the last 30 days, from the demonstration instance.

Detecting password brute force

The first rule counts failed logins for the same account on the same laptop. Five inside two minutes raise an alert mapped to MITRE ATT&CK T1110.001 (Password Guessing).

- id: AUTH-001
  name: "Brute force: many failed logins"
  description: "{count} failed attempts for '{user}' on {host} (from {src_ip}) within 2 minutes."
  severity: 7
  mitre: [T1110.001]
  match: {category: auth, action: login_failed}
  threshold: {count: 5, window: 120, group_by: [host, user]}  # per laptop and account

Failed logins on their own are mostly noise: a forgotten password, a phone still trying old credentials. A success straight after a burst of failures is the moment a guessing attack becomes a compromised account, so the second rule watches for exactly that and carries the maximum severity of 10.

- id: AUTH-003
  name: Successful login after brute force
  description: "'{user}' logged in successfully on {host} shortly after a brute-force attack. Check immediately."
  severity: 10
  mitre: [T1110]
  match: {category: auth, action: login_success}
  after_alert: {rule: AUTH-001, within: 900, group_by: [host, user]}  # within 15 minutes

Against the production engine with all 113 rules loaded, the pair behaves as intended: four failed logins produce nothing, the fifth raises AUTH-001, and a successful login afterwards escalates to AUTH-003. A brute-force attack staged against one of the laptops during testing followed the same path and landed in the incident queue with the laptop, the account and the source address already filled in.

MITRE ATT&CK matrix in Wardline, with covered techniques marked in green and detected techniques highlighted, including T1110 Brute Force.
Figure 3: The MITRE ATT&CK matrix: a green edge marks a technique covered by a rule, and coloured cells were detected in the period, including T1110 Brute Force.
Wardline incident review queue listing repeated brute-force alerts against one laptop, a threat-indicator match and behavioural anomalies, sorted by urgency.
Figure 4: The incident queue, where repeated brute-force alerts against one laptop wait for triage.

Detecting cryptominers

A miner nobody had noticed

The cryptominer in the opening was not a test: Wardline raised the alert in production, and the investigation found a miner running in the background without the owner’s knowledge. The miner was removed and the laptop cleaned. MITRE ATT&CK T1496 (Resource Hijacking) covers this activity: an attacker’s software consuming someone else’s computing power for profit.

How miners avoid attention

Miners are hard to spot because the software itself is often legitimate. XMRig, common in cryptojacking cases, is an open-source program; what makes it malicious is where it runs and for whom. Its own manual page documents the options attackers rely on: -c loads the pool address and settings from a JSON file, keeping them off the command line; -B runs the miner in the background; --cpu-priority 0 runs it at idle priority; and --cpu-max-threads-hint caps how much of the processor it takes, so the fan stays quiet and the owner notices nothing. Add a renamed binary in a hidden folder, and a single detection method is easy to slip past.

Two independent layers: process launches and DNS

On the laptop, IMP-003 inspects the command line of every process launch for a mining-pool URL, a known miner binary or XMRig’s donation flag, which ordinary business software never uses. It is shown here with its English labels.

- id: IMP-003
  name: Cryptocurrency miner
  severity: 8
  mitre: [T1496]
  match:  # a pool URL, a known miner binary, or XMRig's donation flag
    category: [process, auth]
    action: [process_start, sudo]
    data.cmdline|re: 'stratum\+(tcp|ssl|tls)://|(^|[\\/\s"])(xmrig|xmr-stak|minerd|cpuminer|cgminer|bfgminer|nbminer|t-rex|lolminer|phoenixminer|ethminer|gminer)(\.exe)?(\s|"|$)|--donate-level\b'
  group_by: [host]
  suppress: 3600

On the network, DNS-003 reads the office DNS logs and flags lookups of known mining pools. It needs no agent at all, and it does not care what the miner binary is called or where its settings live, because the miner still has to find its pool.

- id: DNS-003
  name: Connection to a cryptocurrency mining pool
  severity: 7
  mitre: [T1496]
  match:  # the pool's domain or any subdomain of it
    category: dns
    data.domain|re: '(^|\.)(minexmr\.com|supportxmr\.com|nanopool\.org|2miners\.com|f2pool\.com|moneroocean\.stream|hashvault\.pro|xmrpool\.eu|minergate\.com|nicehash\.com|herominers\.com|c3pool\.com|unmineable\.com|ethermine\.org|p2pool\.io|kryptex\.network)$'
  group_by: [src_ip]
  suppress: 3600

What each layer catches

Table 3 shows how the endpoint rules handle common disguises, each tested separately against the full production rule set.

Table 3: Endpoint rules against common miner disguises (production rule set)
DisguiseAlerts raised
Binary renamed to kworkerd in a temporary folder, pool URL on the command lineIMP-003 (miner) and DEF-013 (system name in the wrong folder)
xmrig with its pool settings moved into a config fileIMP-003, from the binary name
Only the --donate-level flag visibleIMP-003
Renamed to kworkerd, settings in a config fileDEF-013 only
Renamed to an ordinary-looking name, settings in a config fileNone on the endpoint
An ordinary process (control case)None

The fifth row is the honest limit of command-line matching, and it is why the second layer exists. In testing, DNS-003 fired for three different pools and stayed silent for a Microsoft 365 domain. UEBA adds a third check: it keeps the set of process names seen on each laptop and scores a new one against that baseline. A miner that reaches its pool through a raw IP address or a private proxy avoids the DNS list as well; once that address is known, adding it to the threat-intelligence indicators closes the gap. Once a miner is found, the response is to stop the process, quarantine the binary, and check persistence, which rule PER-001 watches on macOS through new LaunchAgents and LaunchDaemons.

Finding vulnerable software before attackers do

Detection covers what attackers do; vulnerability management covers what they could do. Wardline compares each laptop’s software inventory against a catalogue of minimum safe versions, end-of-life operating systems and remote-access tools. The catalogue is maintained inside Wardline, so no inventory leaves the company.

In Figure 5, an outdated WinRAR is flagged as critical because versions before 6.23 are affected by CVE-2023-38831, a flaw that lets a crafted archive run code when the user opens what looks like an ordinary file. It was exploited in the wild in 2023 and appears in CISA’s Known Exploited Vulnerabilities catalog. A list ranked by severity, with the CVE behind each entry, tells the team which update cannot wait.

Wardline vulnerability view listing outdated programs by severity, with the version found, the safe version, affected laptops and the related CVE, led by a critical WinRAR entry.
Figure 5: The vulnerability view, led by an outdated WinRAR linked to CVE-2023-38831.

How offensive training shaped the detections

A defensive rule is only as precise as its author’s understanding of the attack. Many of Wardline’s detections trace back to techniques first studied from the attacker’s side in Cyber Academy’s red-team curriculum: password guessing, credential theft, masquerading, persistence, resource hijacking. The brute-force rules exist as a pair because the person running a guessing tool cares only about the attempt that works, and the miner rules come in layers because the person deploying a miner expects the first one to be checked.

Key Takeaways

Monitoring employees’ personal laptops is hard for technical, operational and privacy reasons, and the commercial platforms evaluated would have helped only by sending their telemetry to an outside service. Wardline solves it in-house: an agent that collects only on the office network, a rule engine mapped to MITRE ATT&CK with risk scoring and behavioural baselines, and response actions that a compromised server cannot turn into remote code execution. It caught a staged brute-force attack and a real cryptominer, and testing shows exactly where each rule stops and the next layer takes over. The strongest detections pair a noisy signal with the event that confirms it, and layer endpoint, network and behavioural checks so that one disguise does not defeat them all. Teams considering the same approach should check the four conditions in Table 1 first, then build detections as short, tested rules and verify their limits case by case.

SIEM · Detection Engineering · BYOD Security · MITRE ATT&CK · Brute Force Detection · Cryptojacking · UEBA · Endpoint Telemetry