This content has been marked as final.
Show 1 reply
-
1. Re: Security issues with EJB to EJB communication between di
sradford Jun 18, 2003 9:09 AM (in response to jarikr)You just need to set a LoginContext for server1 to connect to server2 don't you (and configure the SecurityRealms of course)?
Something like:
SecurityAssociationHandler handler = new SecurityAssociationHandler();
Principal userPrincipal = new Principal() {
public String getName() {
return "loginNameForServer2";
}
};
handler.setSecurityInfo(userPrincipal, "passwordToUse".toCharArray());
LoginContext loginContext =
new LoginContext("server2SecurityRealm", (CallbackHandler) handler);
loginContext.login();
Regards,
Sean