[prev in list] [next in list] [prev in thread] [next in thread] 

List:       squirrelmail-plugins
Subject:    Re: [SM-PLUGINS] unsafe_image_rules error?
From:       "Hongwei Li" <hongwei () wustl ! edu>
Date:       2005-06-23 13:29:30
Message-ID: 3348.128.252.85.103.1119533370.squirrel () morpheus ! wustl ! edu
[Download RAW message or body]

>>>>>> Hi,
>>>>>>
>>>>>> We have SM 1.4.3a and 1.4.4 on two RH FC3 linux systems (kernel
>>>>>> 2.6.11-1.14_FC3). I also installed some plugins, everything seems
>>>>>> working except unsafe_image_rules.0.7-1.4 that creates a lot of
>>>>>> error entries in the system log as:
>>>>>>
>>>>>> [client 24.107.131.218] PHP Notice:  Undefined property:  replyto
>>>>>> in /usr/share/squirrelmail/plugins/unsafe_image_rules/setup.php on
>>>>>> line 247,
>>>>>> referer: http://morpheus.wustl.edu/webmail/src/right_main.php
>>>>>>
>>>>>> whenever a user logs in SM and click any mail.  The line 247 of
>>>>>> that setup.php is
>>>>>>
>>>>>> $num_matches = preg_match_all($regex, $header->replyto,
>>>>>> $matches);
>>>>>>
>>>>>> What's wrong with the plugin?  Everyday, I have thousands of such
>>>>>> error log entries that is not acceptable.  On the other hand, if I
>>>>>> remove this plugin, many emails in html format with pictures
>>>>>> cannot be displayed -- "This image has been removed for security
>>>>>> reasons" etc.
>>>>>>
>>>>>> Can somebody tell how to fix the problem?  If there is no updated
>>>>>> plugin for this, I'd like to allow all images be displayed w/o
>>>>>> using this plugin. Then, how to display all images without blocking
>>>>>> or warning? What other code should be modified?
>>>>>
>>>>> I'm not 100% sure, but I think most problems with this plugin are
>>>>> fixed here:
>>>>>
>>>>> http://sourceforge.net/project/showfiles.php?group_id=85319&package
>>>>> _id=89289
>>>>
>>>> I downloaded what you provided.  However, I found that what I have
>>>> installed is identical to what you provided.  Any new version? or
>>>> patch, or, if I have to discard it, how to display all images without
>>>> blocking or warning? What other code should be modified?
>>>
>>> Check out the CVS version. The files can be found at
>>> <http://cvs.sourceforge.net/viewcvs.py/sm-plugins/plugins/unsafe_image_r
>>> ules/>. Please provide feedback.
>>
>> I downloaded the cvs version, installed and tested it -- the same: it
>> works, but creating error log when I click an email:
>>
>> [client xxx.xxx.xxx.xxx] PHP Notice:  Undefined property:  replyto in
>> /usr/share/squirrelmail/plugins/unsafe_image_rules/functions.php on line
>> 238,
>> referer:
>> http://morpheus.wustl.edu/webmail/src/right_main.php?PG_SHOWALL=0&sort=0&s
>> tartMessage=1&mailbox=INBOX
>>
>> Any idea?  Do I need to modify ..../src/right_main.php?
>
> plugins/unsafe_image_rules/functions.php line 234:
>    $header = $message->rfc822_header;
>
> plugins/unsafe_image_rules/functions.php line 238:
>    $num_matches = preg_match_all($regex, $header->replyto, $matches);
>
> Adding this after line 234 might reveal something useful:
>
> var_dump($header);
>
> If there's no replyto in the var_dump the problem might be solved by
> adding a test for it. If it doesn't exist line 238 shouldn't be executed.
> This is just a guess though.
>
> I think the answer is related to class/mime/Message.class.php but I don't
> know enough about SquirrelMail to solve it here and now. Maybe someone
> else can provide help.
>
> Sincerely,
> Fredrik.
>

I added that line after line 234.  However, after I log in squirrelmail, even
before clicking any email, the system log shows the same error:

[client xx.xx.xx.xxx] PHP Notice:  Undefined property:  replyto in
/usr/share/squirrelmail/plugins/unsafe_image_rules/functions.php on line 238,
referer:
http://morpheus.wustl.edu/webmail/src/right_main.php?PG_SHOWALL=0&sort=0&startMessage=1&mailbox=INBOX

Also, now everytime when I click an email, it creates 2 error entries instead
of one as before.  I could not find other related log messages.

Anything else can help?  Thanks!

Hongwei



-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
--
squirrelmail-plugins mailing list
Posting Guidelines: http://squirrelmail.org/wiki/wiki.php?MailingListPostingGuidelines
List Address: squirrelmail-plugins@lists.sourceforge.net
List Archives: http://news.gmane.org/thread.php?group=gmane.mail.squirrelmail.plugins
List Archives: http://sourceforge.net/mailarchive/forum.php?forum_id=3931
List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-plugins
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic