JOSSO 解決登入出現AuthenticationFailureException的問題

最近在研究JOSSO(Java Open Single Sign-On)時,在登入時會出現AuthenticationFailureException,找了一段時間的資料,發現在這個討論串有類似的解答:


主要是說,當你在josso-gateway-auth.xml中設置的basic-authscheme如果是basic-auth-scheme時,要把hashAlgorithm和hashEncoding這兩個properties拿掉,不然會出現類似的Exception。

拿掉之後的配置會類似這樣:

    <basic-authscheme:basic-auth-scheme
            id="josso-basic-authentication"
            ignorePasswordCase="false"
            ignoreUserCase="false">

        <basic-authscheme:credentialStore>
            <s:ref bean="josso-identity-store"/>
        </basic-authscheme:credentialStore>

        <basic-authscheme:credentialStoreKeyAdapter>
            <s:ref bean="josso-simple-key-adapter"/>
        </basic-authscheme:credentialStoreKeyAdapter>

    </basic-authscheme:basic-auth-scheme>


之後就可以正常登入了:

Share this post!

Bookmark and Share

0 意見: