[Tickets #14228] Driver "Ingo_Script_I" cannot be loaded due to variable type confusion

noreply at bugs.horde.org noreply at bugs.horde.org
Sun Jan 24 02:55:29 UTC 2016


BITTE NICHT AUF DIESE NACHRICHT ANTWORTEN. NACHRICHTEN AN DIESE  
E-MAIL-ADRESSE WERDEN NICHT GELESEN.

Ticket-URL: https://bugs.horde.org/ticket/14228
------------------------------------------------------------------------------
  Ticket           | 14228
  Erstellt Von     | max.grobecker at ml.grobecker.info
  Zusammenfassung  | Driver "Ingo_Script_I" cannot be loaded due to variable
                   | type confusion
  Warteschlange    | Ingo
  Version          | 3.2.7
  Typ              | Bug
  Status           | Unconfirmed
  Priorität        | 2. Medium
  Milestone        |
  Patch            |
  Zuständige       |
------------------------------------------------------------------------------


max.grobecker at ml.grobecker.info (2016-01-24 02:55) hat geschrieben:

Hello,

After upgrading to Horde 5.2.11 from 5.1.x Ingo stopped working at  
several points.
One of these points is, that I can't add new filter rules by clicking  
on an e-mail address in a received mail and create a filter of it.
It appears an error message that the driver "Ingo_Script_I" cannot be loaded.

The most likely reason seems to be that in  
/ingo/lib/Factory/Script.php seems to be some confusion of variable  
contents.
It seems to be expected, that $scripts needs to be an array:

---------------
    public function create($rule)
    {
           ......

         if ($rule != Ingo::RULE_ALL && isset($scripts[$rule])) {
             $script = $scripts[$rule];
             $skip = array_diff(
                 array(Ingo::RULE_FILTER, Ingo::RULE_BLACKLIST,
                       Ingo::RULE_WHITELIST, Ingo::RULE_VACATION,
                       Ingo::RULE_FORWARD, Ingo::RULE_SPAM),
                 array($rule)
             );
         } else {
             $script = $scripts[Ingo::RULE_ALL];
             $skip = array_keys($scripts);
         }
---------------

But in my case, $scripts has the value (string) "sieve".

Since (const) Ingo::RULE_ALL has the value (int) 1
$script gets assigned the value "i", which later gets converted to  
uppercase and is then used as part of a class name.

I don't know if this is something that happened during an error while  
upgrading - but this file has the same mtime timestamp as all other  
PHP files in my installation, so I assume it got touched during the  
upgrade.






More information about the bugs mailing list