[Alfresco 5.2] External SSO configuration not work for http header encoded on base64

cancel
Showing results for 
Search instead for 
Did you mean: 
ysebahi
Member II

[Alfresco 5.2] External SSO configuration not work for http header encoded on base64

Hello there,

I have configured SSO authentication with header set, And it working well when I receive my header in clear (not encoded), But I need to configure it to receive  a header value encoded on Base64. 

this is My configuration :

Alfresco-global.properties

authentication.chain=external1:external
kerberos.authentication.sso.fallback.enabled=true
external.authentication.enabled=true
external.authentication.defaultAdministratorUserNames=admin
external.authentication.proxyUserName=
external.authentication.proxyHeader=Authorization
external.authentication.userIdPattern=uid=(.*)-.*
create.missing.people=false

Share-config-costum.xml

   <config evaluator="string-compare" condition="Remote">
      <remote>
             <connector>
            <id>alfrescoHeader</id>
            <name>Alfresco Connector</name>
            <description>Connects to an Alfresco instance using header and cookie-based authentication</description>
            <class>org.alfresco.web.site.servlet.SlingshotAlfrescoConnector</class>
            <userHeader>Authorization</userHeader>
            <userIdPattern>uid=(.*)-.*</userIdPattern>
         </connector>

         <endpoint>
            <id>alfresco</id>
            <name>Alfresco - user access</name>
            <description>Access to Alfresco Repository WebScripts that require user authentication</description>
            <connector-id>alfrescoHeader</connector-id>
            <endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
            <identity>user</identity>
            <external-auth>true</external-auth>
         </endpoint>
         
         <endpoint>
            <id>alfresco-feed</id>
            <parent-id>alfresco</parent-id>
            <name>Alfresco Feed</name>
            <description>Alfresco Feed - supports basic HTTP authentication via the EndPointProxyServlet</description> 
            <connector-id>alfrescoHeader</connector-id> 
            <endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
            <identity>user</identity>
            <external-auth>true</external-auth>
         </endpoint>
         
         <endpoint>
            <id>alfresco-api</id>
            <parent-id>alfresco</parent-id>
            <name>Alfresco Public API - user access</name>
            <description>Access to Alfresco Repository Public API that require user authentication.
                         This makes use of the authentication that is provided by parent 'alfresco' endpoint.</description>
            <connector-id>alfrescoHeader</connector-id>
            <endpoint-url>http://localhost:8080/alfresco/api</endpoint-url>
            <identity>user</identity>
            <external-auth>true</external-auth>
         </endpoint>
      </remote>
   </config>

And this is my header coded on baseµ64 :

Authorization : Basic dWlkPWFkbWluLTAsb3U9cGVyc29ubmVz

Regards.