Skip to content
This repository was archived by the owner on Aug 13, 2026. It is now read-only.

Repository files navigation

ZeGuard (arşivlenmiş prototip / archived prototype)

Important

Türkçe — Bu depo arşivlenmiş bir prototiptir ve tarihsel kayıt olarak saklanmaktadır. Geliştirme, sıfırdan yazılan Rust sürümünde devam ediyor: kocaemre/zeguard-core. Bu yeni depo henüz herkese açık değil, dolayısıyla bağlantı bugün ziyaretçilerin çoğu için açılmayacaktır.

English — This repository is an archived prototype, kept as a historical record. Development continues as a ground-up Rust rewrite at kocaemre/zeguard-core. That repository is not yet public, so the link will not open for most visitors today.

Gizli prompt injection dedektörü. PDF, DOCX ve PPTX dosyalarına gömülmüş gizli prompt injection tekniklerini tespit eden, tamamen tarayıcıda çalışan açık kaynak güvenlik aracıydı.

Tüm analiz client-side gerçekleşirdi; hiçbir veri sunucuya gönderilmezdi.

Demo: docguard.zepatrol.xyz — şu an yayında değil. Aşağıdaki kurulum adımlarıyla projeyi lokalde kolayca çalıştırabilirsiniz.

ZeGuard arayüzü

Ne Yapar?

AI sistemlerine dosya yüklediğinizde, belgeye gizlenmiş talimatlar LLM'i manipüle edebilir. ZeGuard bu teknikleri otomatik olarak tespit eder.

Tespit Edilen Saldırı Teknikleri

Teknik Açıklama
Invisible Font Font rengi ≈ arka plan rengi (Delta-E ≤ 10) kontrolü
Tiny Font 4pt altı metin — gözle görünmez, LLM okur
Hidden Text DOCX w:vanish ve w:webHidden XML tag'leri
Unicode Invisible 8 farklı görünmez Unicode karakteri (özellikle 3+ ardışık)
Metadata Injection docProps/core.xml ve custom.xml içindeki injection pattern'ları
Pattern Matching 50+ Türkçe ve İngilizce prompt injection pattern veritabanı

Gizlilik

Tüm analiz tarayıcıda gerçekleşir. Yüklediğiniz dosya hiçbir sunucuya gönderilmez.

Teknoloji

  • React 18 + TypeScript
  • Vite — build tool
  • Tailwind CSS — stil
  • pdf.js — PDF parsing
  • mammoth.js — DOCX parsing
  • PptxGenJS — PPTX parsing

Kurulum

git clone https://github.com/kocaemre/zeguard.git
cd zeguard
npm install
npm run dev

Build

npm run build
# dist/ klasörü oluşur, herhangi bir static hosting'e deploy edilebilir

Proje Yapısı

zeguard/
├── src/
│   ├── analyzers/        # Analiz modülleri
│   │   ├── color-analyzer.ts     # Invisible font tespiti
│   │   ├── font-analyzer.ts      # Tiny font tespiti
│   │   ├── metadata-analyzer.ts  # Metadata injection
│   │   ├── pattern-analyzer.ts   # Pattern matching
│   │   └── unicode-analyzer.ts   # Invisible unicode
│   ├── parsers/          # Dosya ayrıştırıcıları
│   │   ├── pdf-parser.ts
│   │   ├── docx-parser.ts
│   │   └── pptx-parser.ts
│   ├── ui/               # React bileşenleri
│   │   ├── DropZone.tsx
│   │   ├── ResultsPanel.tsx
│   │   ├── FindingCard.tsx
│   │   ├── ScanProgress.tsx
│   │   └── AttacksPage.tsx
│   ├── patterns/
│   │   ├── tr.json       # Türkçe injection pattern'ları
│   │   └── en.json       # İngilizce injection pattern'ları
│   ├── reporter/
│   │   └── report-builder.ts
│   └── App.tsx
├── public/
├── index.html
└── vite.config.ts

Geliştirici

Emre Koca — 0xemrek

Lisans

MIT

About

Superseded by https://github.com/kocaemre/zeguard-core — browser-based prototype, kept as reference only.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages