attachement empty with SSL.

Edmonde.Duteurtre@inria.fr Edmonde.Duteurtre@inria.fr
Tue, 20 Nov 2001 12:27:50 +0100


I just installed IMP 2.2.6 on a Sun server pop3 running Solaris 8
php is php 4.0.6
SSL is 0.9.6b
apache is 1.3.20

And I had the same problem that Gérard Gachelin on this mailing list:

On 7 Sep 2001, at 14:41, Gérard Gachelin wrote:
> Hello,
> 
> IMP 2.2.5 is installed on a Sun server running Solaris 8.
> 
> It works fine but we can't attach any file to emails.
> We can select a file with the browse button but when we  click on the
> Attach button, after a whilw,  the file name disappears from the field
> and the file is not attached. There is not any error message.
> In php.ini (we are using php4), we have :
> upload_max_filesize = 2M
> The attached file is 10K and however it doesn't work.
> Thank you for any help.
> -- 

I trace the attachment code, and I find the problem but I'm not really 
sure what happen really.

I try to explain you.
in compose.php3 in horde/imp/compose.ph3
the test on line 913 is always false and always break is execute.
        if (!is_uploaded_file(safe_file($file_upload))) {
        break;  /* ignore attempt to spoof us; back to composing */
        }
When I put the test or the break in comment the attachement works fine...

is_uploaded_file is a function in basic_functions.c in php.4.0.6:
{{{ proto boolean is_uploaded_file(string path)
   check if file was created by rfc1867 upload  */

Can you explain me what happened ? and why ?
And can I work with the test is_uploaded_file in comment or not ? 
Thank for your help.

Edmonde.Duteurtre               Email: Edmonde.Duteurtre@inria.fr
-------------------------------------------------------------------------
I.N.R.I.A. Rocquencourt           |      Fax: 33 (0)1 39 63 57 59
B.P. 105 78153 LE CHESNAY Cedex   |      Tél: 33 (0)1 39 63 55 45
 ------------------------------------------------------------------------