View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003076 | OXID eShop (all versions) | 4.07. Source code, Test | public | 2011-07-20 11:18 | 2012-12-10 13:44 |
Reporter | mbrotzeller | Assigned To | |||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 4.5.0 revision 34568 | ||||
Fixed in Version | 4.5.2 revision 38481 | ||||
Summary | 0003076: oxemail deliberately breaks attachments | ||||
Description | phpmailer supports sending files as email attachments with a different name. oxemail overwrites the getter for the attachment array and mangles the filename and the tmpname in such a way that even a derived class cannot fix the damage. we have a form for registration that allows users to upload a file that should go directly to the shop owner instead of being stored on the webserver. the only way to do that with oxemail was to move the file first to its original (possibly non-unique) filename and then mail it, or bequeathe either oxemail and duplicate all functions that access PHPMailer::attachment (since it's private there) or bequeathe phpmailer and duplicate the "Mailer" setting logic that tries to read SMTP settings from oxshops. | ||||
Steps To Reproduce | Add one form to a page of the shop, try to use oxemail to send a file from the form as attachment to the shop owner under the original filename without copying the file around first. | ||||
Additional Information | there are a couple of try{<call parent class methods>} catch(Exception $e) {} in oxemail that make it even harder to figure out what goes wrong | ||||
Tags | No tags attached. | ||||
Theme | Both | ||||
Browser | All | ||||
PHP Version | any | ||||
Database Version | any | ||||
|
@developers please investigate it |
|
Yes, your notice about path is good and we fixed it. But i dont think its a bad idea to use try/catch blocks. In case you need to get these exceptions you can easily bypass oxemail functionality by writing own module and calling original methods like: PHPMailer::addAttachment( $sAttPath, $sAttFile = '', $sEncoding = 'base64', $sType = 'application/octet-stream' ) |