양식 기반 인증을 성공적으로 구현했으며 이제는 서블릿에서 javamail의 세션 객체를 초기화하기 위해 사용자 이름과 암호를 얻고 싶습니다. 어떻게해야합니까? request.getRemoteUser() 메서드를 사용하여 사용자 이름을 getlogin 할 수 있지만 암호를 얻는 방법을 모르겠습니다.서블릿에서 로그인 암호를 얻는 방법
내가 만드는 경우처럼 어떤 세션 객체 :
authentication = new PasswordAuthentication(user,password);
Properties props = new Properties();
props.put("mail.host", "localhost");
props.put("mail.debug",true);
props.put("mail.store.protocol", "pop3");
props.put("mail.transport.protocol", "smtp");
Session session = Session.getInstance(props, this);
후 어떻게 얻을 수있는 특정 사용자 이름과 암호를 기반으로 메일 서버에서받은 편지함 메시지, 내가 한 PasswordAuthentication 객체에 대한 서블릿에서 모든 암호를 전달하지 않는 경우?