Add rspamd symbol descriptions from embedded/API lookup
Embed rspamd-symbols.json in the binary to provide human-readable descriptions for rspamd symbols in reports. Optionally fetch fresh symbols from a configurable rspamd API URL (--rspamd-api-url flag), falling back to the embedded list on error. Update the frontend to display descriptions alongside symbol names and scores.
This commit is contained in:
parent
5c104f3c99
commit
7d3009d7d0
12 changed files with 6816 additions and 20 deletions
21
pkg/analyzer/rspamd-symbols-README.md
Normal file
21
pkg/analyzer/rspamd-symbols-README.md
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
# rspamd-symbols.json
|
||||
|
||||
This file contains rspamd symbol descriptions, embedded into the binary at compile time as a fallback when no rspamd API URL is configured.
|
||||
|
||||
## How to update
|
||||
|
||||
Fetch the latest symbols from a running rspamd instance:
|
||||
|
||||
```sh
|
||||
curl http://127.0.0.1:11334/symbols > rspamd-symbols.json
|
||||
```
|
||||
|
||||
Or with docker:
|
||||
|
||||
```sh
|
||||
docker run --rm --name rspamd --pull always rspamd/rspamd
|
||||
docker exec -u 0 rspamd apt install -y curl
|
||||
docker exec rspamd curl http://127.0.0.1:11334/symbols > rspamd-symbols.json
|
||||
```
|
||||
|
||||
Then rebuild the project.
|
||||
Loading…
Add table
Add a link
Reference in a new issue