本文使用Orielly上传包实现验证类: package com.test.auth; import javax.mail.Authenticator; import javax.mail.PasswordAuthentication; public class Authentic extends Authenticator { protected PasswordAuthentication getPasswordAuthentication() { String username = "daryl715"; //大多数是你邮件@前面的部分 String pwd = "smallfish1009"; return new PasswordAuthentication(username, pwd); } } 发送页面:
本文使用Orielly上传包实现验证类: package com.test.auth; imp