itsm_ysm/src/main/java/cmm/util/MyAuthentication.java

21 lines
618 B
Java

package cmm.util;
import javax.mail.Authenticator;
import javax.mail.PasswordAuthentication;
import egovframework.com.cmm.service.EgovProperties;
public class MyAuthentication extends Authenticator {
PasswordAuthentication pa;
public MyAuthentication(){
String id = EgovProperties.getProperty("Globals.mail.smtp.user");
String pw = EgovProperties.getProperty("Globals.mail.smtp.pass");
pa = new PasswordAuthentication(id, pw);
}
// 시스템에서 사용하는 인증정보
public PasswordAuthentication getPasswordAuthentication() {
return pa;
}
}