Apache Commons Email encode attach with base64
问题 I'm trying to send a file base64-encoded via apache.commons.mail and I just can't seam to get the Content-Transfer-Encoding: base64 header where it's supposed to go. // Create the email MultiPartEmail email = new MultiPartEmail(); email.setSmtpPort(587); email.setDebug(false); email.setHostName("smtp.gmail.com"); email.setAuthentication("from@gmail.com", "password"); email.setTLS(true); email.addTo("to@example.com"); email.setFrom("from@example.com"); email.setSubject("subject"); email.attach