diff options
author | Luke Bratch <luke@bratch.co.uk> | 2024-11-09 23:50:46 +0000 |
---|---|---|
committer | Luke Bratch <luke@bratch.co.uk> | 2024-11-09 23:50:46 +0000 |
commit | f55160af3f25fff17d3af4dde50a606c2c78f79b (patch) | |
tree | bc0eb6a581a33d3b81d5b1cf1becf40418c8e9ed /config.c | |
parent | 59addf47eca6a0be54e3b07c4ed2b156a8431376 (diff) |
Make NOTICE alerts about client (dis)connection and authentication events optional.
New configuration options added:
- alertconnect
- alertauthfail
- alertauthsuccess
- alertunautheddisconnect
- alertautheddisconnect
Diffstat (limited to 'config.c')
-rw-r--r-- | config.c | 17 |
1 files changed, 16 insertions, 1 deletions
@@ -419,7 +419,22 @@ int createconfigfile(char *filename) { "debug = \"2\"\n" "\n" "# Number of debug logs to keep\n" - "debugkeep = \"5\"\n"; + "debugkeep = \"5\"\n" + "\n" + "# Send NOTICE to all other clients upon new client connections (\"1\" for yes or \"0\" for no)\n" + "alertconnect = \"1\"\n" + "\n" + "# Send NOTICE to all other clients upon clients failing to authenticate (\"1\" for yes or \"0\" for no)\n" + "alertauthfail = \"1\"\n" + "\n" + "# Send NOTICE to all other clients upon clients succesfully authenticating (\"1\" for yes or \"0\" for no)\n" + "alertauthsuccess = \"1\"\n" + "\n" + "# Send NOTICE to all other clients upon unauthenticated client disconnections (\"1\" for yes or \"0\" for no)\n" + "alertunautheddisconnect = \"1\"\n" + "\n" + "# Send NOTICE to all other clients upon authenticated client disconnections (\"1\" for yes or \"0\" for no)\n" + "alertautheddisconnect = \"1\"\n"; // Write complete string to file if ((fprintf(fp, "%s", string)) < 0) { |