Habr•August 13, 2026•🇷🇺Translated from Russian

Building a Minimal Open Source Security Stack for Infrastructure Protection

Full protection of corporate infrastructure today is difficult to achieve without commercial security tools. However, startups, small organizations, and budget-constrained companies often turn to open source solutions as a compromise. This guide focuses on building a minimal security stack that addresses core information security tasks using freely available tools.

A basic stack must cover several key areas: protection of endpoints to detect malware and workstation compromise, network perimeter defense and traffic control, centralized collection and analysis of security events, and user access management through proper authentication and rights separation. The recommendations are intended as a starting point for small infrastructures rather than a complete substitute for enterprise products.

Antivirus Protection

ClamAV is one of the best-known open source antivirus engines with cross-platform support for Linux, Windows, and macOS. On Windows, the graphical frontend ClamWin is available. It is frequently used to scan mail traffic and file repositories in addition to endpoint protection. Other options include the OpenAntiVirus Project and KicomAV.

Installation on Linux uses the commands: apt-get update followed by apt-get install clamav clamav-daemon. Services clamav-freshclam and clamav-daemon handle signature updates and scanning. On Windows, the standard installer is used, and recursive scans are performed with clamscan --recursive.

Network Perimeter Protection

Popular open source firewalls include pfSense, built on FreeBSD with the PF packet filter, its fork OPNsense, and the proxy server Squid. pfSense supports installation of Snort and Suricata for intrusion detection and prevention, as well as Squid for web traffic filtering. Key features encompass multi-WAN load balancing, VPN servers (IPsec, OpenVPN, L2TP, TINC), DHCP services, HAProxy publishing, captive portal support, and log forwarding to external SIEM systems.

Rules for Snort or Suricata can be loaded from ET Open or official VRT feeds. The system can operate in IDS mode for logging only or IPS mode for active blocking. Logs are forwarded via the Status → System Log → Settings section.

Security Event Collection and Analysis

The ELK Stack (Elasticsearch, Logstash, Kibana) enables custom SIEM construction. Logstash and Ingest Pipelines normalize events, while threshold and EQL rules support correlation of authentication failures or suspicious sequences. Wazuh offers a more integrated platform with built-in vulnerability scanning, file integrity monitoring, EDR-like capabilities, and direct mapping to the MITRE ATT&CK framework for threat hunting and IOC enrichment.

Access Management and Authentication

Keycloak provides single sign-on using OAuth2, OIDC, and SAML standards. It authenticates users, issues JWT tokens, and supports integration with LDAP or Telegram. Configuration involves creating an OpenID Connect client, setting valid redirect URIs, and mapping roles in the target application such as Kibana.

These open source components together form a functional baseline for small environments, but they must be tuned to the specific infrastructure, kept updated, and sourced only from active, reputable projects.

Related articles

Habr•Other

AmneziaWG Container for MikroTik Routers Delivers Top Performance Six Months After Launch

A developer released an AmneziaWG container for MikroTik devices in February 2026 and has since added major improvements in speed, protocol support, and stability. The lightweight container leverages the router's native WireGuard implementation for cryptography while handling AmneziaWG obfuscation in software. Performance now reaches 250-350 Mbit/s on models such as Hap Ax3 and RB5009B after switching to C code and increasing buffer sizes with RouterOS 7.24. New features include server mode for connecting multiple MikroTik devices, random port hopping, IPv6 support, dynamic DNS, and offline configuration. The project survived an early GitHub ban caused by test scripts and has grown to over 370 stars while remaining fully offline and privacy-focused.

Habr•Other

Building Resilient DoH Failover on MikroTik RouterOS to Handle Unreachable Cloudflare Responses

A network administrator encountered a persistent issue in a branch office where pages like Tailwind CSS CDN failed to load despite valid DNS responses from Cloudflare DoH. The problem stemmed from unreachable IP addresses such as 8.6.112.0 and 8.47.69.0 returned by the resolver, which RouterOS treated as healthy because it only checked for valid IP types rather than route reachability. RouterOS supports only a single active DoH upstream via the use-doh-server parameter, requiring custom scripting for failover between multiple endpoints like Cloudflare and dns.google. The solution involved static DNS entries for bootstrap addresses, certificate trust anchors including SSL.com TLS ECC Root CA 2022, and a health monitor script that probes using DNS-JSON API calls instead of switching the resolver directly. Multiple iterations addressed issues like cache-based false positives, plain DNS fallback risks from provider spoofing, and clock validation to prevent certificate failures. The final implementation uses thresholds for failure and recovery to avoid flapping and ensures post-switch verification before committing to a backup endpoint.

Habr•Other

NetRuleRouter Alpha Released to Route Traffic Across Multiple Connections Without Disabling VPN

Developer krox1 has released the first public alpha of NetRuleRouter v0.1.0-alpha.1 for Windows and Linux, a local network policy manager that distributes traffic between primary and secondary connections based on domains, IP ranges, applications, and subnets. The tool emerged from practical issues that intensified after Russian authorities discussed VPN restrictions in March 2026, with operators and platforms later prompting users to disable VPN for domestic services. NetRuleRouter sits on top of existing connections rather than acting as a VPN client or proxy, allowing users to keep corporate VPNs, personal VPNs, and direct internet active simultaneously. It supports seven matching methods including exact domains, wildcard subdomains, CIDR ranges, and application paths, with priority rules to resolve overlaps and built-in leak protection that prevents protected destinations from falling back when the secondary connection drops. The alpha includes diagnostic tracing, preset rule sets for Russia and other regions, import/export capabilities, and a first-run wizard that configures the background service and initial bindings. Limitations around DNS, shared IPs, and brief startup windows are documented, and the project explicitly does not protect against account-level blocks by services such as Anthropic.

Habr•Other

Setting Up Nextcloud Talk on TrueNAS with Custom Domain for Private Family Calls

A detailed guide explains how to deploy Nextcloud Talk on a TrueNAS server behind a custom domain to create a self-hosted messaging and calling platform for family use. The author addresses problems with commercial messengers such as VK notifications failing on iOS and Telegram requiring VPN connections. The solution uses HestiaCP on a VPS for reverse proxying, Let's Encrypt SSL certificates, and port forwarding on a home router to reach the TrueNAS instance at 192.168.0.17:30027. Additional steps cover configuring coturn for TURN relay to enable reliable voice and video calls, updating trusted domains in Nextcloud, and disabling router DoS protection. The setup also enables Screen Sharing, reactions, and push notifications while keeping all data under user control.