{"id":20122827,"url":"https://github.com/freaky/imserious","last_synced_at":"2026-06-09T15:04:07.417Z","repository":{"id":57679653,"uuid":"487304514","full_name":"Freaky/IMSErious","owner":"Freaky","description":"Execute commands in response to Dovecot's Internet Message Store Event notifications","archived":false,"fork":false,"pushed_at":"2023-08-12T03:16:16.000Z","size":135,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-28T11:46:27.111Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Freaky.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-04-30T14:54:03.000Z","updated_at":"2022-05-16T03:20:35.000Z","dependencies_parsed_at":"2024-11-13T19:51:33.076Z","dependency_job_id":null,"html_url":"https://github.com/Freaky/IMSErious","commit_stats":{"total_commits":68,"total_committers":1,"mean_commits":68.0,"dds":0.0,"last_synced_commit":"01a1ae36eeb61bd9293dcc594c74ba338579c4b4"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Freaky%2FIMSErious","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Freaky%2FIMSErious/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Freaky%2FIMSErious/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Freaky%2FIMSErious/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Freaky","download_url":"https://codeload.github.com/Freaky/IMSErious/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241566163,"owners_count":19983258,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-13T19:41:20.555Z","updated_at":"2026-06-09T15:04:07.411Z","avatar_url":"https://github.com/Freaky.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# IMSErious\n\nExecute commands in response to Dovecot [Internet Message Store Events][rfc5423].\n\n## Synopsis\n\n```\nimserious [-t] [-c file]\nimserious [--test] [--config file]\nimserious [-hv]\nimserious [--help] [--version]\n```\n\n```\nOptional arguments:\n  -h, --help           print help message\n  -v, --version        print program version\n  -t, --test           test configuration\n  -c, --config CONFIG  path to configuration\n```\n\n## Summary\n\nIMSErious is a service that listens for Dovecot push notification events,\nas sent by its [OX (Open-Xchange) driver][OX], and executes commands in response.\nThis allows, for example, waking up an [MRA] or issuing desktop notifications\non new messages.\n\n## Configuration\n\nIMSErious is configured from a [TOML] file specified as the first argument,\ndefaulting to `/usr/local/etc/imserious.toml`:\n\n```toml\nlisten = \"10.0.0.1:12525\"  # listen address, default 127.0.0.1:12525\nallow = [ \"10.0.0.2/32\" ]  # allowed notification IP ranges, default all\nendpoint = \"/notify\"       # path to API endpoint, default /notify\nmax_connections = 8        # connection limit, default 8\ntimeout = \"5s\"             # request timeout, default 5s\n\n# optional Basic auth\n[auth]\nuser = \"foo\"\npass = \"bar\"\n\n# optional TLS\n[tls]\ncert = \"/etc/ssl/foo.example.com.crt\"\nkey = \"/etc/ssl/foo.example.com.key\"\nperiodic_reload = \"1d\" # optionally reload keys periodically, no default\n\n# optional stdout logging\n[log]\nmax_level = \"info\"    # One of error, warn, info (default), debug, trace\n                      # May be overridden by setting IMSERIOUS_LOG env var\nformat = \"compact\"    # One of full (default), compact, pretty, json\nansi = false          # Format \"pretty\" with ANSI codes, default false\ntimestamp = false     # Display a timestamp, default false\ntarget = false        # Display the log target, default false\nlevel = false         # Display the log level, default false\n\n[[handler]]\nip = [ \"10.0.0.2/32\" ] # allowed handler IP ranges, default all\nuser = \"freaky\"        # Username, required\nevent = \"MessageNew\"   # Event type, optional, default MessageNew\n                       # Note this is currently the only type supported by Dovecot's OX driver\ndelay = \"5s\"           # Delay execution this long after initial event, optional, default none\nlimit_period = \"30s\"   # Rate limit executions over this interval, optional, default 30s\nlimit_burst = 1        # Allow this many executions per interval, optional, default 1\nperiodic = \"300s\"      # Execute unconditionally after this long, optional, default none\ncommand = \"/usr/local/bin/fdm -a eda -l fetch\"\n```\n\n## Handlers\n\nA handler is a command to execute in response to a specific event/user pair.  Multiple\nhandlers for the same event and user may be specified to trigger different commands\nwith their own rate limits, periodic configuration, etc.\n\nCommands only support basic shell word splitting and quoting - if shell metacharacters\nare required they should be provided by executing via a shell such as with `/bin/sh -c`.\n\nEvent fields will be exposed in `IMSE_*` env vars if available - only `IMSE_USER`\nand `IMSE_EVENT`are guaranteed to be set if `periodic` execution is specified.\n\n* `IMSE_USER` - user being notified\n* `IMSE_EVENT` - event name\n* `IMSE_REMOTE_IP` - notifying IP address\n* `IMSE_REMOTE_PORT` - notifying TCP port\n* `IMSE_UNSEEN` - number of unseen messages\n* `IMSE_FOLDER` - IMAP folder name\n* `IMSE_FROM` - `From:` address of a new email (if any)\n* `IMSE_SNIPPET` - a sample of the body of a new email (if any)\n\n## Security\n\nIt should not need to be said that there are potentially serious security implications\nfrom allowing remote clients to trigger commands on your server.  While every effort\nhas been made to limit the potential for harm, it is your responsibility not to use\nthis program unsafely.\n\nIt is strongly discouraged to run an open instance of IMSErious on a public network,\nor as a privileged user.\n\n[rfc5423]: https://www.rfc-editor.org/rfc/rfc5423.html\n[OX]: https://doc.dovecot.org/configuration_manual/push_notification/\n[MRA]: https://en.wikipedia.org/wiki/Mail_retrieval_agent\n[TOML]: https://toml.io\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreaky%2Fimserious","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffreaky%2Fimserious","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreaky%2Fimserious/lists"}