Caching SearXNG

This revision is from 2024/03/17 09:39. You can Restore it.

SearXNG installs itself on /usr/local/searxng/searxng-src, with the main source code in searxng-src directory.

To hack the results, the file is webapp.py in /usr/local/searxng/searxng-src/searx/webapp.py

The function in webapp.py is...

@app.route('/search', methods=[['GET', 'POST']])

def search():

One sqlite3 database. Named: searxng_distributed_cache.db

  1. stores the search terms
  2. stores the urls

Proposed searXNG options:

  • Use cache
  • Update the cache
  • Disclosure to end user

Benefits:

  • Turns searXNG into a full search engine built from caching results.
  • Searches are against a local file, so it speeds up searching significantly
  • Offline searching.

Refactoring def search():

  

📝 📜 ⏱️ ⬆️