Skip to content

Cato Networks Webapp - Dashboard per gestione SD-WAN Cato Networks

License

Notifications You must be signed in to change notification settings

mmereu/cato-webapp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cato Networks Webapp

Dashboard web per la gestione di siti SD-WAN Cato Networks tramite le API GraphQL ufficiali.

Web dashboard for managing Cato Networks SD-WAN sites via the official GraphQL API.


Funzionalita / Features

  • Creazione siti con wizard multi-step (info, rete nativa, VLANs, riepilogo)
  • Lista siti esistenti con refresh real-time
  • Gestione VLANs con DHCP configurabile per ogni VLAN
  • Validazione CIDR, IP, range privati in real-time
  • Supporto Socket fisici (X1500/X1600/X1700) e virtuali (AWS/Azure/GCP/ESXi)

  • Site creation with multi-step wizard (info, native network, VLANs, summary)
  • Site listing with real-time refresh
  • VLAN management with configurable DHCP per VLAN
  • Real-time validation for CIDR, IP, private ranges
  • Socket support for physical (X1500/X1600/X1700) and virtual (AWS/Azure/GCP/ESXi)

Architettura / Architecture

Frontend (React + MUI + TypeScript)  -->  Nginx (:8080)
                                              |
                                         /api proxy
                                              |
Backend (Express + GraphQL)            -->  Node (:3001)
                                              |
                                     Cato Networks API
                              (api.catonetworks.com/api/v1/graphql2)

Requisiti / Requirements

  • Docker + Docker Compose
  • Cato Networks API Key (dal portale Cato Management Application)
  • Cato Account ID

Setup

1. Clona il repository / Clone the repo

git clone https://github.com/mmereu/cato-webapp.git
cd cato-webapp

2. Configura le variabili d'ambiente / Configure environment variables

cp backend/.env.example backend/.env

Modifica backend/.env con le tue credenziali Cato:

Edit backend/.env with your Cato credentials:

CATO_API_KEY=your_api_key_here
CATO_ACCOUNT_ID=your_account_id
CATO_ENDPOINT=https://api.catonetworks.com/api/v1/graphql2
PORT=3001
NODE_ENV=production
CORS_ORIGINS=http://localhost:8080,http://localhost

3. Avvia con Docker Compose / Start with Docker Compose

docker compose up -d --build

L'app sara disponibile su http://localhost:8080.

The app will be available at http://localhost:8080.

Sviluppo locale / Local development

Backend:

cd backend
npm install
npm run dev

Frontend:

cd frontend
npm install
npm run dev

Il frontend in dev usa il proxy Vite verso localhost:3001.

The frontend dev server proxies API calls to localhost:3001 via Vite.

API Endpoints

Method Path Descrizione
GET /api/health Health check
GET /api/sites Lista tutti i siti
POST /api/sites Crea un sito base
POST /api/sites/create-complete Crea sito + VLANs (orchestrato)
GET /api/sites/:id/lan-interface Ottieni LAN interface ID
POST /api/sites/:id/network-ranges Aggiungi VLAN/network range
GET /api/locations Cerca location (paese, timezone)

Sicurezza / Security

  • Le credenziali API vanno SOLO nel file .env (mai nel codice)
  • Il backend usa helmet per gli header HTTP di sicurezza
  • Rate limiting: max 100 richieste per 15 minuti per IP
  • CORS configurabile via variabile d'ambiente

  • API credentials belong ONLY in the .env file (never in code)
  • Backend uses helmet for secure HTTP headers
  • Rate limiting: max 100 requests per 15 minutes per IP
  • CORS configurable via environment variable

Tech Stack

  • Frontend: React 18, TypeScript, Material UI 5, Vite 5, Axios
  • Backend: Node.js 20, Express 4, graphql-request
  • Deploy: Docker, Nginx reverse proxy
  • API: Cato Networks GraphQL API v1

License

MIT - vedi LICENSE

About

Cato Networks Webapp - Dashboard per gestione SD-WAN Cato Networks

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published