DorkCraft ๐Ÿ”

August 17, 2026 ยท View on GitHub

Generate advanced Google search operators from plain English โ€” built for OSINT, academic research, and public information discovery.

Live site: https://juandresrodca.github.io/DorkCraft/


What is DorkCraft?

DorkCraft transforms natural language queries into precise Google dork operators. Instead of remembering syntax like filetype:pdf intitle:"linux malware", you just type:

"Find PDF books about Linux malware analysis"

and DorkCraft builds the query for you.

Example inputs โ†’ outputs

You typeDorkCraft generates
Find PDF books about Linux malwarefiletype:pdf intitle:"linux malware"
LinkedIn profiles for SOC analysts in Irelandsite:linkedin.com/in intitle:"soc analyst" "Ireland"
Exposed Apache directory listingsintitle:"index of" "apache" -htm -html
Public GitHub repos about threat intelligencesite:github.com intitle:"threat intelligence"

Stack

LayerTechnology
FrontendAstro + TypeScript
BackendFastAPI (Python 3.9+)
HostingGitHub Pages (frontend)
CI/CDGitHub Actions

Project structure

DorkCraft/
โ”œโ”€โ”€ backend/
โ”‚   โ”œโ”€โ”€ main.py                  # FastAPI app + CORS + routes
โ”‚   โ”œโ”€โ”€ models/
โ”‚   โ”‚   โ””โ”€โ”€ schemas.py           # Pydantic request/response models
โ”‚   โ”œโ”€โ”€ services/
โ”‚   โ”‚   โ””โ”€โ”€ dork_generator.py    # Rule-based dork engine
โ”‚   โ””โ”€โ”€ requirements.txt
โ”‚
โ”œโ”€โ”€ frontend/
โ”‚   โ”œโ”€โ”€ src/
โ”‚   โ”‚   โ”œโ”€โ”€ components/
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ Header.astro
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ Footer.astro
โ”‚   โ”‚   โ”‚   โ”œโ”€โ”€ SearchBox.astro
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ ResultCard.astro
โ”‚   โ”‚   โ”œโ”€โ”€ lib/
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ api.ts           # Typed API client
โ”‚   โ”‚   โ”œโ”€โ”€ pages/
โ”‚   โ”‚   โ”‚   โ””โ”€โ”€ index.astro      # Main page + all client logic
โ”‚   โ”‚   โ””โ”€โ”€ styles/
โ”‚   โ”‚       โ””โ”€โ”€ global.css       # Design system
โ”‚   โ””โ”€โ”€ astro.config.mjs
โ”‚
โ”œโ”€โ”€ .github/
โ”‚   โ””โ”€โ”€ workflows/
โ”‚       โ””โ”€โ”€ deploy.yml           # Auto-deploy to GitHub Pages
โ”‚
โ””โ”€โ”€ README.md

Running locally

Backend

cd backend
pip install -r requirements.txt
uvicorn main:app --reload --port 8000

API docs available at http://localhost:8000/docs

Frontend

cd frontend
npm install
npm run dev

Open http://localhost:4321 โ€” the frontend will call the backend at http://localhost:8000 by default.


Deploying

Frontend (GitHub Pages)

  1. In your repo โ†’ Settings โ†’ Pages โ†’ set source to GitHub Actions.
  2. Push to main. The deploy.yml workflow builds and deploys automatically.
  3. Your site will be live at https://juandresrodca.github.io/DorkCraft/.

Backend (optional)

Deploy the backend/ folder to any Python host:

PlatformNotes
RailwayOne-click Python deploy
RenderFree tier available
Fly.ioGreat for small APIs

After deploying, add the backend URL as a GitHub secret named VITE_API_URL. The Actions workflow injects it at build time via PUBLIC_API_URL.


Safety & ethics

DorkCraft enforces a blocklist of harmful query patterns at the backend level:

  • โŒ Credential or password extraction
  • โŒ Credit card / PII data searches
  • โŒ Malware delivery
  • โŒ Exploit or injection queries
  • โŒ Unauthorised access requests

Blocked queries return {"error": "Unsafe or disallowed query."} โ€” no dork is generated.

You are responsible for how you use the results. Always respect privacy, terms of service, and applicable laws.


Extending DorkCraft (AI-ready)

The DorkGenerator class in backend/services/dork_generator.py is designed to be a clean extension point:

class DorkGenerator:
    def generate(self, query: str) -> dict:
        # Replace this body with an LLM call (Gemini, Claude, OpenAI)
        # The contract (input/output dict) stays the same
        ...

Add new intent categories by extending the CATEGORIES dict. Add new safety rules by extending BLOCKED_PATTERNS.


License

MIT โ€” use freely, contribute back.