Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
rag-seguridad — CyberRAG — RAG 100% local (Ollama) sobre apuntes y libros de ciberseguridad: recuperación híbrida, respuestas con citas, asistente de pentest por fases y monitor de reindex. Sin frameworks pesados. | Kitploit
Tools/GitLabGitLab/rdelasierra-uy/rag-seguridad
Vulnerability AnalysisInformation GatheringCTFPenetration TestingPrivacyMachine LearningLearning & EducationCurated ResourcesAI SecurityLabs & Practice
GitLabrdelasierra-uy/rag-seguridad
9213 days agoNot yet reviewed

rag-seguridad

CyberRAG — RAG 100% local (Ollama) sobre apuntes y libros de ciberseguridad: recuperación híbrida, respuestas con citas, asistente de pentest por fases y monitor de reindex. Sin frameworks pesados.

View Repository
Share

CyberRAG local — RAG over your knowledge, 100% Ollama

RAG (Retrieval-Augmented Generation) system to query your cybersecurity notes (Obsidian vault, HTB writeups, notes) with natural language. Everything runs on your machine: embeddings and generation use local Ollama, with no data leaving your network. And no langchain: every piece is your own understandable code.

Complete technical documentation → docs/ARQUITECTURA.md Covers the underlying concepts (RAG, embeddings, hybrid search, fair sharing, rerank), the layered architecture, format extraction, the incremental index, knowledge spaces and compute capacity.

Phased pentest assistant → docs/ASISTENTE-PENTEST.md HTB mentor by phase (Recon / Enumeration / Exploitation / Privesc / Post / Report) and vector (web, SMB, AD, Linux, Windows…), with a help level (empuja / explica / directo) to understand by hand without autopilot, and a machine state field to paste your ports/services. Designed for authorized offensive work + ISO 27001 reporting.

Architecture report (for L2/learner) → docs/INFORME-ARQUITECTURA.md Overview in a single read: what it is, how it's built inside and how it's used, plus a plan to teach it in 20 minutes.

Server runbook → docs/RUNBOOK-SERVIDOR.md Host operation: non-negotiable rules, network/firewall, xRDP/faillock and GPU recovery (Xid 31).

Reindex monitor → web/monitor.py (browser dashboard: progress, rate, ETA, GPU and models live, without touching the GPU).

Why

  • Your pedagogy: you understand every piece (vectors, cosine, chunking) — it's not a black box.
  • Privacy: your writeups and notes never touch the cloud (no Gemini/OpenAI).
  • Zero heavy dependencies: just numpy + the Ollama HTTP API.

Architecture

Tus documentos (.md/.txt/.log)
        │
        ▼
  ┌────────────┐   chunking con solape   ┌──────────────────┐
  │  Chunks    │ ─────────────────────▶  │  Embeddings      │
  │ (pedazos)  │                         │  nomic-embed-text│
  └────────────┘                         └────────┬─────────┘
                                                  ▼
                                           ┌──────────────┐
                                           │  Índice .npz │  (output/indice.npz)
                                           └──────┬───────┘
                          ┌───────────────────────┘
                          ▼
   Pregunta ───▶ vector ──▶ similitud coseno ──▶ top-k chunks
                                                      │
                                                      ▼
   Respuesta ◀── generación con contexto ◀───────────┘
                (qwen2.5-coder / mistral, local)

The 3 pieces of RAG:

  1. Index — you split each document into chunks with overlap: 512 characters (overlap 50) for notes and 3000 (overlap 600) for books. Each chunk is vectorized with a role prefix (search_document: ) that increases the embedding quality in the search.
  2. Retrieve — each chunk is stored as a vector of 768 numbers (embedding from nomic-embed-text, local). When faced with a question (vectorized as search_query: ), you search for the chunks with the highest cosine similarity combined with lexical word matching (hybrid search). Cosine alone is not enough for comparison questions; the lexical component rescues the exact chunk where the terms are.
  3. Generate — you send the top-k chunks as context to the local chat model, which responds ONLY with that (and says "I don't have information" if it's not there).

Requirements

  • Python 3.10+
  • Ollama running on 127.0.0.1:11434
  • nomic-embed-text model (setup.sh downloads it automatically)
  • Local chat model: by default qwen2.5-coder:7b. It is the one that answers theory (citing ISO/books) AND the offensive lab topics (HTB) without refusing. Changeable without touching code with the env var RAG_CHAT_MODEL (e.g. RAG_CHAT_MODEL=llama3.1:8b rag web for fine theoretical prose — although with offensive content it self-restricts; mistral:latest cites well but at times pastes raw context).
  • pdftotext (poppler-utils) if you want to index PDFs

Installation

./setup.sh

Usage

# Indexar los documentos de ejemplo en document[o]s/
python3 rag_ollama.py index

# Indexar otra carpeta (ej.: tu vault de Obsidian) — en vivo, sin copiar
python3 rag_ollama.py --docs-dir ~/vault index

# Preguntar (usá SIEMPRE el mismo --docs-dir que el index)
python3 rag_ollama.py --docs-dir ~/vault ask "¿Qué flag de hashcat crackea un hash ASREProast?"

# Chat continuo contra tu base — sin repetir el comando
python3 rag_ollama.py --docs-dir ~/vault interactive

# Estadísticas del índice
python3 rag_ollama.py stats

On this machine there is also the rag alias, which maintains two knowledge spaces: your notes (vault) and the curated book library (libros).

rag "pregunta sobre tus apuntes"     # espacio vault (default)
rag libros "pregunta sobre libros"   # espacio libros (PDFs curados)
rag --rerank "pregunta"              # con reranker local (reordena fuentes)
rag chat                             # modo interactivo (vault)
rag chat libros                      # modo interactivo (libros)
rag index                            # reindexar VAULT (incremental: rápido)
rag index libros                     # reindexar libros (tarda minutos)
rag stats                            # estado del índice del vault
rag analizar                         # dupes + solapamiento + temas (vault)
rag fuentes "término"                # en qué documentos aparece el término

The two spaces are saved in output/indices/indice_<espacio>.npz and do not overwrite each other.

Web interface (for users without a shell)

rag web        # → http://localhost:8787  (alias local en /etc/hosts)
               #   o: RAG_HOST=0.0.0.0 rag web  para exponerlo a la LAN (con UFW)

The UI (pure Python stdlib server, zero dependencies) offers:

  • Token-by-token streaming chat (Server-Sent Events): the response appears as the model generates it, not all at once at the end.
  • Multi-turn conversation: the chat remembers previous questions and answers from the session (references like "and for users, which one is it?").
  • Sources panel: for each response, the cited .md/.pdf files.
  • Citations with the book's real name: technical PDFs (02-redhat-security-rh342.pdf) are displayed and cited by their human title ("Red Hat RH342 — Security: server hardening"); the prompt asks the model to cite the source of each idea.
  • Space catalog: questions like "what books do you have" or "list the titles" are answered with the full index of the space (without spending inference).
  • Space selector: switch between notes (biblioteca), books (biblioteca-libros) or todo (both combined, the default). In todo mode the search splits the quota between the two indexes — a space with many chunks (~138k books) doesn't crush the small one (581 notes) — and each source is labeled with its origin (📚 book / 📝 note).
  • Reindex with a button and a live progress bar (without killing the chat).
  • "Where does… appear?": a search for which document contains a term.
  • Structure: web/web.py (API + static), web/index.html, web/style.css, web/app.js — all editable live.

Full volume library (space libros)

Download Tool

Most Popular

View all →

Discover the most used tools by our community.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 The ultimate OSINT toolkit: investigation graph, confidence scoring, alias families, map, timeline and reports. 49 modules, 400+ sites, no API keys required.

    911
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock One-Tap Execution App (CVE-2026-43499)

    548
  • 3

    redforge

    cybersecurity91/redforge

    Browser-side red team toolkit with 102 offline tools for recon, payload generation, credential attacks, crypto, encoding and engagement reporting.

    366
  • 4

    ARTEX

    baarai/artex

    LLM multi-agent autonomous penetration testing platform with planner/worker agents, asset and exploration graphs, MITM traffic recording, and vulnerability retesting.

    362
  • 5

    looking-glass

    anonghosty/looking-glass

    CSIRT platform that ingests Shadowserver reports into MongoDB and replays them as interactive maps, analysis, findings, advisories and executive dashboards.

    311
  • 6

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    The system of action for AI-native cybersecurity—where intent becomes governed execution, evidence becomes operational memory, and every operation improves the next.

    287

Explore all tools

Browse our collection of tools

View all tools →