我正在實現自定義外部身份提供程序,爲此我需要從jackrabbit實現ExternalIdentityProvider類。如何在實現jackrabbit的類中獲取HTTP請求對象ExternalIdentityProvider
http://jackrabbit.apache.org/oak/docs/security/authentication/externalloginmodule.html
在正常情況下,你需要通過爲j_username和爲j_password,你可以從值SimpleCredentials對象獲取這些
我的問題是,因爲我需要通過附加的形式參數說,例如LinkedIn ID在我的情況下,我該如何實現這一目標?
@Component(
policy = ConfigurationPolicy.REQUIRE
)
@Service
public class RDBMSIdentityProvider implements ExternalIdentityProvider {
@Override
public ExternalUser authenticate(Credentials credentials)
throws ExternalIdentityException, LoginException {
//i can get username/password from credentials object
//how to get additional parameters from http request object?
}
任何輸入是高度讚賞。
謝謝!