Skip to content

armgit / xerj

Public Imported from GitHub
0

AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory and RAG. Elasticsearch-compatible API; Corpus Hub serves hundreds of reference memory corpora.

3.6 KB
Raw Blame
{"type":"result","subtype":"success","is_error":false,"api_error_status":null,"duration_ms":3268391,"duration_api_ms":4305477,"ttft_ms":3065,"ttft_stream_ms":3064,"time_to_request_ms":288,"num_turns":80,"result":"Both deliverables are written: `/root/ab-run-p1/out/findings.json` (10 findings) and `/root/ab-run-p1/out/method.md`.\n\n## What I found\n\nFive of the ten findings were **confirmed at runtime against the prebuilt binary**, not just read from source:\n\n| ID | Defect | Measured |\n|---|---|---|\n| F1 | `?force_synthetic_source=true` → `insert_nested` recurses per dot in a stored field name | node abort at 50k dots; survived 40k |\n| F2 | `expand_pipeline_processors` backtracks its `seen` set → 2^N expansion | 49.6 GB RSS, still climbing, host-threatening |\n| F3 | Term suggester `O(m·n)` Levenshtein per term, twice, no caps | 84.9 s for 1 MB × 2000 terms |\n| F4 | `.dv` sidecar trusts a u64 `payload_len` | `memory allocation of 281474976710656 bytes failed`, node dead |\n| F5 | `merge_dotted_property` recurses per dot in a `PUT _mapping` key | node abort |\n| F6 | git `rev` spliced into argv | `--upload-pack=/tmp/pwn` executed under git 2.39.5 |\n\n`panic = \"abort\"` in the release profile means every one of the recursion/OOB findings is a whole-node kill, not a 500.\n\n## Ranking logic\n\nF1 and F3 are first because they need only `Privilege::ReadIndex` — and `_search` is explicitly on the share-guest allow-list, so an **external unauthenticated-adjacent guest who claimed a share link** can fire them. F1 is also persistent: the poisoned document survives restart, so it re-kills indefinitely.\n\nF2 is second despite needing an unscoped key because it exhausts the *host*, not just the process.\n\nF6/F7 (corpus-provider RCE / arbitrary write+`remove_dir_all`) are ranked below the remote DoS chain only because they require the operator to run a command on an untrusted file.\n\n## Things I checked and deliberately did not report\n\nCORS is restrictive by default; the `/_share/claim` rate limiters, Argon2 passcode hashing, and SHA-256 share-id storage are sound; console sessions are CSPRNG + HMAC-signed with server-side revocation; autoindex has real zip-slip and XXE defenses; the SPA serves only compile-time-embedded assets with a segment check; and the painless interpreter has genuinely tight fuel/deadline/depth limits.\n\nOne caveat worth flagging: F8 (console data-sources proxy has no role scoping) is admitted in the crate's own test file — the fix that test pins covers only the reserved `.xerj-memory-*` namespace, leaving ordinary user indices open to any `viewer`.","stop_reason":"end_turn","session_id":"230d854c-d93a-473f-b853-728c7f20de1d","total_cost_usd":20.742549999999987,"usage":{"input_tokens":131833,"cache_creation_input_tokens":0,"cache_read_input_tokens":6920320,"output_tokens":28808,"server_tool_use":{"web_search_requests":0,"web_fetch_requests":0},"service_tier":"standard","cache_creation":{"ephemeral_1h_input_tokens":0,"ephemeral_5m_input_tokens":0},"inference_geo":"","iterations":[],"speed":"standard"},"modelUsage":{"glm-5.3":{"inputTokens":131833,"outputTokens":28808,"cacheReadInputTokens":6920320,"cacheCreationInputTokens":0,"webSearchRequests":0,"costUSD":4.839525000000001,"contextWindow":200000,"maxOutputTokens":32000},"glm-5.3-flash":{"inputTokens":698433,"outputTokens":120076,"cacheReadInputTokens":18817920,"cacheCreationInputTokens":0,"webSearchRequests":0,"costUSD":15.90302499999999,"contextWindow":200000,"maxOutputTokens":32000}},"permission_denials":[],"terminal_reason":"completed","fast_mode_state":"off","uuid":"062d32c1-bc6e-4a52-bc0d-b3471efc48f9"}