We have a Java programme that sends email with .xls (Excel) attachment on daily basis. It works absolutely fine other than generating ATT00001.bin file as attachment along with Excel file. This BIN file is of same size as Excel attachment. BIN file can be opened with MS Excel and it has exactly same data as the Excel file does. After a lot of Googling I found that such problem arises because of attachment appearing first in the code. I have checked the code and body part comes first and attachment later. I Googled the problem but couldn't find solution as all the results are related to certain part of email turning into attachment(s). In my case email body is as it should be while attachment is duplicated but with different extension.