Project

General

Profile

Actions

Feature #14337

closed

Allow SMTP notifications from non-root processes

Added by Denny Page over 1 year ago. Updated about 1 year ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Notifications
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
23.09
Release Notes:
Default

Description

The changes to address #14031 removed the ability for non root processes to send notifications. This one line change restores that functionality:

--- notices.inc.old    2023-04-23 09:44:28.161806000 -0700
+++ notices.inc    2023-05-02 09:36:47.548761000 -0700
@@ -356,7 +356,7 @@

     /* Store last message sent to avoid spamming */
     @file_put_contents("/var/db/notices_lastmsg.txt", $message);
-    if (!$force) {
+    if ($force == false && posix_geteuid() == 0) {
         notify_via_queue_add($message, 'mail');
         $ret = true;
     } else {
Actions

Also available in: Atom PDF