RAGFlow is a retrieval-augmented generation engine that concentrates on the part most RAG tools skip: getting clean text out of messy documents. Its DeepDoc layer runs layout analysis and OCR over PDFs, scans, slides, spreadsheets and Word files, recognizes tables and figures, and then chunks the result with templates suited to the document type (papers, manuals, contracts, Q&A sheets). You can see each chunk and fix it by hand, and every answer comes back with citations to the passages it used.
Around that it has grown into a full platform: knowledge bases, an agent canvas with MCP and a code-execution sandbox, a memory feature, sync from Confluence, S3, Notion and Google Drive, and chat channels such as Telegram and Discord. It is Apache 2.0, built by InfiniFlow, and mid-migration: Go is now the largest language in the repository, ahead of the original Python. It is also heavy, a stack of containers that wants a real server.
- Repository: github.com/infiniflow/ragflow
- Licence: Apache-2.0 (Apache License 2.0)
- Language: Go. Stars: 91.3K. Forks: 10.8K. Last push: Sep 26, 2026.
- Scan: safe, Sep 24, 2026, commit 313ca90
Who it is for
Teams building question answering over contracts, manuals, research papers or scanned archives where parsing quality decides everything, and self-hosters with a spare x86 server who want citations they can check.
Getting started
1. Raise the Linux memory-map limit that the search engine needs
sudo sysctl -w vm.max_map_count=2621442. Clone the repository and check out the release matching the Docker image
git clone https://github.com/infiniflow/ragflow.git && cd ragflow/docker && git checkout v0.27.23. Start the stack, then open http://localhost and add a model provider
docker compose -f docker-compose.yml up -dPlan for at least 4 CPU cores, 16 GB of RAM and 50 GB of disk. The prebuilt images are x86 only; on ARM, including Apple Silicon, the docs explain how to build your own. The code-execution sandbox additionally needs gVisor.
Safety scan
We cloned infiniflow/ragflow at commit 313ca90 on Sep 24, 2026 and ran the checks described on the GitHub Tools page: credential patterns, decode-and-execute code, install-time scripts, committed binaries, risky CI workflows, every host the code talks to, known vulnerabilities in pinned dependencies, and project hygiene. A person read every hit. This is what we found.
- Four secret hits, all sample SSH private keys in internal/agent/sandbox/ssh_test.go. No self-decoding code. The bare-IP URLs are SSRF tests for the agent tools and data connectors, checking which addresses are blocked.
- Three pattern hits: the Dockerfile installs Node.js with NodeSource's curl | bash setup script at build time, a Telegram URL sits in a test, and the reverse-shell regex belongs to the skill hub's security scanner, which looks for exactly that.
- tools/scripts/install.sh installs the optional ragflow-cli binary from GitHub releases into /usr/local/bin, downloads a SHA256SUMS file alongside it, and asks for sudo only if that folder is not writable. The server itself installs through Docker. No npm hooks, no committed binaries.
- Known advisories: 210 across 2,905 packages in nine lockfiles. The one critical (shell-quote) and 72 highs are in the web front end's npm build. The main uv.lock has 8 highs among 697 packages, and the Python SDK's lockfile 13 highs among 26.
- Only three workflows. The scanner's pull_request_target hit in sep-tests.yml is the name appearing in comments and conditions: the workflow is triggered by plain pull_request and runs only when a maintainer adds the ci label. Neither third-party action is pinned. Security policy and licence present; no Dependabot, CodeQL or contributing guide.
- docker/.env ships default passwords (infini_rag_flow and variants) for Elasticsearch, MySQL, MinIO and the rest, under a warning at the top of the file to change them before any non-local deployment.
What the scanner counted
| Check | Result |
|---|---|
| Secrets | 4 candidates found and read; see the notes above. |
| Suspicious code | 3 pattern hits found and read; every one is listed under the raw findings. |
| Install-time code | 6 installer scripts (one can call sudo) |
| Committed binaries | None. |
| CI workflows | 3 workflows. 1 uses pull_request_target, none check out the pull request head. 2 of 2 third-party actions pinned to a tag rather than a commit. |
| Network hosts | 40 distinct hosts referenced from source; most often www.apache.org, ragflow.io, github.com, storybook.js.org. 6 URLs to a bare IP address, listed under the raw findings. |
| Known vulnerabilities | 210 advisories across 2,905 pinned packages: 1 critical, 99 high, 88 moderate, 14 low, 8 unrated. admin/client/uv.lock: 16 packages, 4 advisories; agent/sandbox/sandbox_base_image/nodejs/package-lock.json: 27 packages, 1 advisories; agent/sandbox/uv.lock: 28 packages, 8 advisories; api/channels/whatsapp/gateway-node/package-lock.json: 124 packages, 1 advisories; go.mod: 258 packages, 12 advisories; sdk/python/uv.lock: 26 packages, 23 advisories; tools/es-to-oceanbase-migration/uv.lock: 40 packages, 4 advisories; uv.lock: 697 packages, 21 advisories; web/package-lock.json: 2,046 packages, 148 advisories. |
| Project hygiene | Has security policy, licence file. Missing automated dependency updates, CodeQL, contributing guide. |
| OpenSSF Scorecard | Not scored: the project is not in Scorecard's weekly index. |
The raw findings
Every hit the scanner wrote out, with a link to the exact line at the scanned commit. Secrets candidates are redacted.
Secret candidates (4, redacted)
| Where | Rule | Match |
|---|---|---|
| internal/agent/sandbox/ssh_test.go:90 | private-key | -----B…--- (31 chars) |
| internal/agent/sandbox/ssh_test.go:103 | private-key | -----B…--- (31 chars) |
| internal/agent/sandbox/ssh_test.go:115 | private-key | -----B…--- (31 chars) |
| internal/agent/sandbox/ssh_test.go:137 | private-key | -----B…--- (35 chars) |
Pattern hits (3)
| Where | Rule | Match |
|---|---|---|
| Dockerfile:126 | download-piped-to-shell | curl -fsSL https://deb.nodesource.com/setup_22.x | bash - && \ |
| internal/channels/telegram_test.go:132 | exfil-host | URL: "https://api.telegram.org/bot" + token + "/sendMessage", |
| internal/cli/filesystem/skill_hub/security/patterns.go:195 | raw-socket-shell | Pattern: `/bin/(ba)?sh\s+-i\s+.*>/dev/tcp/`, |
URLs to bare IP addresses (6)
| Where | Rule | Match |
|---|---|---|
| internal/agent/component/invoke_test.go:420 | ip-literal-url | if r.RequestURI != "http://8.8.8.8/api" { |
| internal/agent/component/invoke_test.go:458 | ip-literal-url | "url": "http://8.8.8.8/api", |
| internal/agent/tool/ssrf_test.go:35 | ip-literal-url | {"http_public", "http://1.1.1.1/", false}, |
| internal/agent/tool/ssrf_test.go:49 | ip-literal-url | {"multicast", "http://224.0.0.1/", true}, |
| internal/agent/tool/ssrf_test.go:89 | ip-literal-url | host, ip, err := ResolveAndValidate("https://1.1.1.1/foo") |
| internal/syncer/connector/ssrf_test.go:50 | ip-literal-url | {name: "public literal ip", url: "http://8.8.8.8/x", want: true}, |
Installer scripts (6)
- agent/sandbox/scripts/start.sh, 73 lines; talks to www.apache.org
- internal/deepdoc/native/run.sh, 36 lines
- run_go_tests.sh, 31 lines
- tools/scripts/install.ps1, 233 lines; talks to api.github.com, github.com, www.apache.org
- tools/scripts/install.sh, 275 lines, uses sudo; talks to github.com, www.apache.org
- tools/scripts/run_migrations.sh, 62 lines
Worst known vulnerabilities (24 of 210)
| Advisory | Severity | Package | Summary |
|---|---|---|---|
| GHSA-w7jw-789q-3m8p | critical | shell-quote@1.8.3 | shell-quote quote() does not escape newlines in object .op values |
| GHSA-hmw2-7cc7-3qxx | high | form-data@4.0.5 | form-data: CRLF injection in form-data via unescaped multipart field names and filenames |
| GHSA-47fr-3ffg-hgmw | high | click@8.1.8 | |
| GHSA-82w8-qh3p-5jfq | high | starlette@0.50.0 | Starlette: request.form() limits silently ignored for application/x-www-form-urlencoded enable DoS |
| GHSA-wqp7-x3pw-xc5r | high | starlette@0.50.0 | Starlette: SSRF and NTLM credential theft via UNC paths in StaticFiles on Windows |
| GHSA-rgj7-g3m4-5g8c | high | sharp@0.35.2 | sharp: Vulnerabilities in libheif: GHSA-g89c-p67h-r497 and GHSA-2jg2-4ch7-h545 |
| GHSA-8wv5-x4w7-5gww | high | github.com/apache/thrift@0.23.0 | Apache Thrift Python, Go, PHP and Java bindings have an Infinite Loop |
| GHSA-2v4p-qf9q-27wj | high | google.golang.org/grpc@1.83.1 | gRPC-Go xDS servers: Denial of Service (DoS) via crash due to missing `:authority` and `Host` headers |
| GHSA-45hq-cxwh-f6vc | high | pillow@12.0.0 | Pillow `BdfFontFile`: `Image.new()` called without `_decompression_bomb_check()` - bomb protection bypass via font loadi… |
| GHSA-5x94-69rx-g8h2 | high | pillow@12.0.0 | Pillow: `FontFile.compile()`: `Image.new()` called without `_decompression_bomb_check()` |
| GHSA-62p4-gmf7-7g93 | high | pillow@12.0.0 | Pillow: Out-of-bounds read via attacker-controlled row stride on Pillow's mmap path (McIdas AREA files) |
| GHSA-6r8x-57c9-28j4 | high | pillow@12.0.0 | Pillow: Heap out-of-bounds write `Image.paste()` / `Image.crop()` via signed coordinate overflow |
| GHSA-8v84-f9pq-wr9x | high | pillow@12.0.0 | Pillow `PcfFontFile._load_bitmaps()`: `Image.frombytes()` called without `_decompression_bomb_check()` - bomb protection… |
| GHSA-9hw9-ch79-4vh6 | high | pillow@12.0.0 | Pillow: Controlled heap out-of-bounds write in Pillow `ImageCmsTransform.apply()` via output mode mismatch |
| GHSA-cfh3-3jmp-rvhc | high | pillow@12.0.0 | Pillow affected by out-of-bounds write when loading PSD images |
| GHSA-jjj6-mw9f-p565 | high | pillow@12.0.0 | Pillow: Decompression Bomb DoS via PdfParser.PdfStream.decode() |
| GHSA-phj9-mv4w-65pm | high | pillow@12.0.0 | Pillow `GdImageFile._open()`: image dimensions accepted without `_decompression_bomb_check()` |
| GHSA-pwv6-vv43-88gr | high | pillow@12.0.0 | Pillow has an OOB Write with Invalid PSD Tile Extents (Integer Overflow) |
| GHSA-vjc4-5qp5-m44j | high | pillow@12.0.0 | Pillow JPEG2000 tiled decode retains a growing scratch buffer and can be used for denial of service |
| GHSA-whj4-6x5x-4v2j | high | pillow@12.0.0 | FITS GZIP decompression bomb in Pillow |
| GHSA-xj96-63gp-2gmr | high | pillow@12.0.0 | Pillow: Heap out-of-bounds write in `ImageFilter.RankFilter` via integer overflow in `ImagingExpand` |
| GHSA-47fr-3ffg-hgmw | high | click@8.3.1 | |
| GHSA-537c-gmf6-5ccf | high | cryptography@46.0.7 | Vulnerable OpenSSL included in cryptography wheels |
| GHSA-g6cj-pr64-35w5 | high | cryptography@46.0.7 | cryptography: PKCS#7 EnvelopedData decryption exposes a Bleichenbacher oracle through distinguishable errors and timing |
Workflows worth a look
- .github/workflows/sep-tests.yml: pull_request_target
By the numbers
| Stars | 91.3K |
|---|---|
| Forks | 10.8K |
| Contributors | 846 |
| Commits | 9,681 |
| Open issues | 1,167 |
| Open pull requests | 360 |
| Releases | 55 |
| Latest release | v0.27.2 |
| Licence | Apache-2.0 |
| Main language | Go |
| Project age | 2 years |
| Last push | Sep 26, 2026 |
| Tracked files | 6,381 |
| Lines of code | 1.8M |
| Checkout size | 73 MB |
Lines by language: Go 856K, Python 422.8K, TypeScript 257.9K, JSON 125.9K, Markdown 45.4K, C++ 44.5K.
Questions
Is RAGFlow free?
Yes. RAGFlow is Apache 2.0, so self-hosting, modifying and commercial use are all allowed without a fee. InfiniFlow also runs a hosted version at cloud.ragflow.io for people who do not want to operate the stack. Either way you supply the language and embedding models, hosted or local.
What hardware does RAGFlow need?
The README asks for at least 4 CPU cores, 16 GB of RAM, 50 GB of disk and Docker 24 or later, because the stack runs a search engine, a database, object storage and the parsing service side by side. The prebuilt images are x86 only. A GPU is optional and speeds up document parsing.
How is RAGFlow different from Dify or AnythingLLM?
All three do retrieval over your documents. RAGFlow puts most of its effort into parsing: layout analysis, OCR, table recognition and chunk templates, with the chunks visible and editable. Dify is a broader app builder and AnythingLLM a lighter desktop chat. If answers depend on complex PDFs or scans, RAGFlow is usually the stronger choice.
This post is part of GitHub Tools, where every repository is cloned and scanned before it is written up. The scan is a snapshot of one commit on one day; the repository has moved on since, so check it before you install.
