From 93917f92375f25b02bbba71f70ee99b7e81eceb0 Mon Sep 17 00:00:00 2001 From: pdontthink Date: Wed, 29 Aug 2007 23:48:30 +0000 Subject: [PATCH] Added smtp_auth hook git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@12628 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- ChangeLog | 1 + functions/auth.php | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/ChangeLog b/ChangeLog index a2aefb4b..88fc5b09 100644 --- a/ChangeLog +++ b/ChangeLog @@ -214,6 +214,7 @@ Version 1.5.2 - SVN - No longer store all message composition sessions in the PHP session, since it was not made use of and in rare cases, made sessions too big - Composition restoration functionality now correctly restores attachments + - Added smtp_auth hook Version 1.5.1 (branched on 2006-02-12) -------------------------------------- diff --git a/functions/auth.php b/functions/auth.php index 11a484fe..b7d57452 100644 --- a/functions/auth.php +++ b/functions/auth.php @@ -277,4 +277,10 @@ function get_smtp_user(&$user, &$pass) { $user = $username; $pass = sqauth_read_password(); } + + // plugin authors note: override $user or $pass by + // directly changing the arguments array contents + // in your plugin e.g., $args[0] = 'new_username'; + // + do_hook('smtp_auth', $temp=array(&$user, &$pass)); } -- 2.25.1