-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Sat, November 5, 2005 23:37, john habermann wrote:
>>>>> I seem to have a problem with some messages not being displayed
>>>>> in squirrelmail.
[..]
>>> Installed plugins are:
>>> Installed Plugins
[..]
>>> 14. gpg
>> Try disabling this one and see if it helps
> Beautiful it works fine now, I can see the body of the message is now
> displayed. I wonder why the gpg plugin could be causing this the message
> doesn't appear to be signed and is in plain text.
Okay, I was talking with Brian again about this one, and we uncovered the
bug. I think it was a minor missunderstanding of the documentation, or a
possible assumption. The code that handles the particular issue here is
calls strrpos and tries to find ".pgp" or ".asc" in the attachment name.
The problem is, unlike strpos, strrpos (notice the extra r) only searches
for the first character, which is a ".". Practically all files contain
extensions, and so any file that is attached with the content-type of
application/octet-stream was run through GPG, then attempted to be cleaned
up, and caused memory issues. The fix is actually incredibly easy. Open
plugins/gpg/setup.php, and around line 211 you should see something like:
if ((strrpos($filename,".asc") == (strlen($filename)-4)....
Go to that line, and replace the strrpos with strpos (notice the missing
extra r this time), and you can then re-enable your gpg plugin.
I've already commited this to the cvs branch of the gpg plugin, and it
should be in the next release.
- --
Jonathan Angliss
<[EMAIL PROTECTED]>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
iEYEARECAAYFAkNxdUoACgkQK4PoFPj9H3OwIQCfTOZ+qm+eyPtPUeKoNb7SySdY
P7wAoOB/6kjZ225eEyGlr+O0un3lTyff
=8oop
-----END PGP SIGNATURE-----
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
--
squirrelmail-users mailing list
Posting Guidelines:
http://www.squirrelmail.org/wiki/MailingListPostingGuidelines
List Address: [email protected]
List Archives:
http://news.gmane.org/thread.php?group=gmane.mail.squirrelmail.user
List Archives: http://sourceforge.net/mailarchive/forum.php?forum_id)95
List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-users