php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #7531 imap_qprint faultly returns empty string
Submitted: 2000-10-30 10:00 UTC Modified: 2001-05-04 21:22 UTC
From: michel dot jansens at ulb dot ac dot be Assigned:
Status: Not a bug Package: IMAP related
PHP Version: 4.0.1pl2 OS: Solaris 2.6
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: michel dot jansens at ulb dot ac dot be
New email:
PHP Version: OS:

 

 [2000-10-30 10:00 UTC] michel dot jansens at ulb dot ac dot be
I just found a mail body which is not decoded properly
by imap_qprint() (returning empty string), but is 
decoded the right way by quoted_printable_decode()

the string is the following (not including the ------ lines)
-------------------------------------
>Monsieur, A la suite de l'envoi d'un bon vert pour la 
connection =E0=20 resulb, nous n'avons toujours pas 
de nouvelles. Le payement a-t'il bien =E9t=E9 effectu=
E9? sinon pourriez-vous nous=20 prevenir s'il vous 
plait et dans le cas contraire dans combien=20 de 
temps aurons-nous une adresse IP? =20 Je vous 
serais gr=E9 de me tenir au courant. Merci d'avance 
Sadia >> Monsieur, >> >> >>Notre service 
d'embryologie mol=E9culaire aimerait faire une 
demande pour >>la connection d'un nouvel ordinateur 
=E0 resulb. Nous comptons effectuer >>le paiement 
des 4000 Bef par bon vert , vous serait-il possible de 
nous >>faire parvenir le num=E9ro de compte vers 
lequel nous devons effectuer le >>virement. >> >>Je 
vous remercie d'avance. >> >>Sadia > >Bonjour, > >Il 
suffit de mettre le num=E9ro du cl=E9 d'imputation 
dans la case r=E9serv=E9 >au titulaire du compte et 
pour le reste c'est la secr=E9taire de notre >service qui 
s'en occupe. > >Bien =E0 vous, Kurosh Mahmoudi >=
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3 D=3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D >SERVICE RESEAU > >CP 
197 >AVENUE F.D. ROOSEVELT 50 >B-1050 
BRUXELLES >TEL. 32-2-650 37 10 >FAX. 32-2-650 37 
40 >E-MAIL:resulb@ulb.ac.be >=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D=3D=3D=3 D=3D=3D=3D =
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
3D > > >
-----------------------------------------------------------------

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-05-04 21:22 UTC] vlad@php.net
That's not a bug. This is a malformed quoted-printable encoding (read FRC 2045 section 6.7). 

If you try to do imap_qprint("=\r\nE9") (which is found in line 3 of your example), it's not gonna work, and neither will quoted_printable_decode(). Both will print return "E9", and not the character encoded.

You can't see any output at all because don't even use "\r\n", but just "\n", which is not RFC compliant by itself (but nobody seems to care).

In short, this is not a bug, and the difference between imap_qprint() and quoted_printable_decode() is that one does not produce any result at all, while the other produces bogus result (although it does it's best to guess what you meant and fails).

Vlad

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Dec 30 14:01:28 2024 UTC