Home Pricing FAQ About

End-to-End Setup Guide

From zero to NIS2-compliant in 15 minutes. Backend, frontend, and infrastructure.

Prerequisites

Python 3.8+

For Django backend

Node.js 18+

For React frontend

Docker & Compose

For infrastructure

1

Backend: Django NIS2 Shield

Security middleware with forensic logging

Terminal
# Install the package
pip install django-nis2-shield

# In settings.py, add the middleware
MIDDLEWARE = [
    'django.middleware.security.SecurityMiddleware',
    'django_nis2_shield.middleware.Nis2GuardMiddleware',
    # ... other middleware
]

# Configure NIS2 Shield
NIS2_SHIELD = {
    'LOG_FORMAT': 'JSON',
    'ANONYMIZE_IPS': True,
    'ENFORCE_MFA_ROUTES': ['/admin/'],
}

# Run the audit command
python manage.py check_nis2
Now your Django app has forensic logging, rate limiting, and NIS2 audit
2

Frontend: React NIS2 Guard

Client-side security and telemetry

Terminal
# Install the package
npm install @nis2shield/react-guard

# In your App.tsx
import { Nis2Provider, SessionWatchdog, AuditBoundary } from '@nis2shield/react-guard';

function App() {
  return (
    <Nis2Provider config={{ auditEndpoint: '/api/nis2/telemetry/' }}>
      <SessionWatchdog idleTimeout={15} />
      <AuditBoundary>
        <YourApp />
      </AuditBoundary>
    </Nis2Provider>
  );
}
Now your React app sends security telemetry to Django
3

Infrastructure: Docker Stack

Hardened containers, log segregation, backups

Terminal
# Clone the infrastructure repo
git clone https://github.com/nis2shield/infrastructure.git
cd infrastructure

# Configure environment
cp .env.example .env
nano .env  # Set your passwords

# Start the base stack
docker-compose up -d

# Or with ELK observability
./scripts/elk-setup.sh

# Or with Prometheus/Grafana
./scripts/monitoring-setup.sh

# Test disaster recovery
./scripts/restore-test.sh
Now your infrastructure is hardened with logging and backups

Complete Architecture

🌐 React Frontend

@nis2shield/react-guard • Session, Storage, Telemetry

🐍 Django Backend

django-nis2-shield • Logging, Rate Limiting, Audit

🐳 Docker Infrastructure

Fluent Bit → SIEM • Backups • Prometheus/Grafana

What's Next?