<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Mapeamento dos campos do cadastro de usuário entre Keycloak e alfresco in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111943#M78772</link>
    <description>&lt;P&gt;Olá!&lt;/P&gt;&lt;P&gt;Estou usuando o keycloak para autenticar os usuários no alfresco share 7.4. No entanto o valor do campo email do cadastro do usuário no keycloak não é levado para o cadastro do usuário no alfresco.&lt;/P&gt;&lt;P&gt;Existem algum parametro especifico para configurar e fazer funcionar?&lt;/P&gt;&lt;P&gt;A integração entre keycloak e alfresco é por&amp;nbsp;&lt;SPAN&gt;OpenID Connect. Não tenho LDAP nem ActiveDiretory.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Grato!&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 18 Jun 2024 13:56:18 GMT</pubDate>
    <dc:creator>fmayconcs</dc:creator>
    <dc:date>2024-06-18T13:56:18Z</dc:date>
    <item>
      <title>Mapeamento dos campos do cadastro de usuário entre Keycloak e alfresco</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111943#M78772</link>
      <description>&lt;P&gt;Olá!&lt;/P&gt;&lt;P&gt;Estou usuando o keycloak para autenticar os usuários no alfresco share 7.4. No entanto o valor do campo email do cadastro do usuário no keycloak não é levado para o cadastro do usuário no alfresco.&lt;/P&gt;&lt;P&gt;Existem algum parametro especifico para configurar e fazer funcionar?&lt;/P&gt;&lt;P&gt;A integração entre keycloak e alfresco é por&amp;nbsp;&lt;SPAN&gt;OpenID Connect. Não tenho LDAP nem ActiveDiretory.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Grato!&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 18 Jun 2024 13:56:18 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111943#M78772</guid>
      <dc:creator>fmayconcs</dc:creator>
      <dc:date>2024-06-18T13:56:18Z</dc:date>
    </item>
    <item>
      <title>Re: Mapeamento dos campos do cadastro de usuário entre Keycloak e alfresco</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111944#M78773</link>
      <description>&lt;P&gt;Alguma sugestão&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/4825"&gt;@cristinamr&lt;/A&gt;&amp;nbsp;?&lt;/P&gt;</description>
      <pubDate>Tue, 18 Jun 2024 14:09:07 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111944#M78773</guid>
      <dc:creator>fmayconcs</dc:creator>
      <dc:date>2024-06-18T14:09:07Z</dc:date>
    </item>
    <item>
      <title>Re: Mapeamento dos campos do cadastro de usuário entre Keycloak e alfresco</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111945#M78774</link>
      <description>&lt;P&gt;Não trabalhei nisso, mas tentarei ajudá-lo.&lt;/P&gt;&lt;H3 id="toc-hId-1484209027"&gt;Passos para Configurar a Sincronização do Email&lt;/H3&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Configuração do Keycloak&lt;/STRONG&gt;:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Certifique-se de que o email está incluído no token JWT emitido pelo Keycloak.&lt;/LI&gt;&lt;LI&gt;Vá para o seu cliente no Keycloak (aquele que você usa para Alfresco).&lt;/LI&gt;&lt;LI&gt;Na aba "Mappers", certifique-se de ter um mapper para o email. Este mapper deve estar configurado para incluir o atributo de email no token.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Exemplo de configuração de um mapper:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;STRONG&gt;Name&lt;/STRONG&gt;: email&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Mapper Type&lt;/STRONG&gt;: User Property&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Property&lt;/STRONG&gt;: email&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Token Claim Name&lt;/STRONG&gt;: email&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Claim JSON Type&lt;/STRONG&gt;: String&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Add to ID token&lt;/STRONG&gt;: Yes&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Add to access token&lt;/STRONG&gt;: Yes&lt;/LI&gt;&lt;LI&gt;&lt;STRONG&gt;Add to userinfo&lt;/STRONG&gt;: Yes&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Configuração do Alfresco&lt;/STRONG&gt;:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Configure o conector OpenID Connect para mapear o email do token JWT para o registro de usuário no Alfresco.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;No arquivo de configuração alfresco-global.properties, certifique-se de ter a seguinte configuração:&lt;BR /&gt;authentication.chain=keycloak:external&lt;BR /&gt;authentication.keycloak.client-id=SEU_CLIENT_ID&lt;BR /&gt;authentication.keycloak.client-secret=SEU_CLIENT_SECRET&lt;BR /&gt;authentication.keycloak.realm=SEU_REALM&lt;BR /&gt;authentication.keycloak.auth-server-url=&lt;A href="https://SEU_KEYCLOAK_SERVER/auth" target="_blank" rel="noopener nofollow noreferrer"&gt;https://SEU_KEYCLOAK_SERVER/auth&lt;/A&gt;&lt;BR /&gt;authentication.keycloak.redirect-uri=&lt;A href="http://SEU_ALFRESCO_SERVER/share" target="_blank" rel="noopener nofollow noreferrer"&gt;http://SEU_ALFRESCO_SERVER/share&lt;/A&gt;&lt;BR /&gt;authentication.keycloak.scope=openid email profile&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;Ajuste os valores de SEU_CLIENT_ID, SEU_CLIENT_SECRET, SEU_REALM, SEU_KEYCLOAK_SERVER, e SEU_ALFRESCO_SERVER conforme sua configuração.&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Configuração dos Mapeamentos de Atributos&lt;/STRONG&gt;:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;O Alfresco precisa saber como mapear os atributos do token para os campos de usuário do Alfresco.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Você pode adicionar um arquivo de mapeamento de atributos em alfresco/extension/subsystems/Authentication/keycloak (certifique-se de criar os diretórios se não existirem).&lt;/P&gt;&lt;P&gt;Crie um arquivo chamado keycloak-authentication-context.xml com o seguinte conteúdo:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;beans:beans xmlns="&lt;A href="http://www.alfresco.org/schema/dictionary" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.alfresco.org/schema/dictionary&lt;/A&gt;"&lt;BR /&gt;xmlns:beans="&lt;A href="http://www.springframework.org/schema/beans" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.springframework.org/schema/beans&lt;/A&gt;"&lt;BR /&gt;xmlns:xsi="&lt;A href="http://www.w3.org/2001/XMLSchema-instance" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.w3.org/2001/XMLSchema-instance&lt;/A&gt;"&lt;BR /&gt;xsi:schemaLocation="&lt;A href="http://www.alfresco.org/schema/dictionary" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.alfresco.org/schema/dictionary&lt;/A&gt; &lt;A href="http://www.alfresco.org/schema/dictionary/1.0/alfresco-dictionary-1.0.xsd" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.alfresco.org/schema/dictionary/1.0/alfresco-dictionary-1.0.xsd&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://www.springframework.org/schema/beans" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.springframework.org/schema/beans&lt;/A&gt; &lt;A href="http://www.springframework.org/schema/beans/spring-beans-3.0.xsd" target="_blank" rel="noopener nofollow noreferrer"&gt;http://www.springframework.org/schema/beans/spring-beans-3.0.xsd&lt;/A&gt;"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;beans:bean id="keycloakUserMapping" class="org.alfresco.repo.security.authentication.ExternalUsersMapping"&amp;gt;&lt;BR /&gt;&amp;lt;beans&lt;img id="smileytongue" class="emoticon emoticon-smileytongue" src="https://connect.hyland.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;roperty name="mappings"&amp;gt;&lt;BR /&gt;&amp;lt;beans:map&amp;gt;&lt;BR /&gt;&amp;lt;beans:entry key="email" value="email"/&amp;gt;&lt;BR /&gt;&amp;lt;beans:entry key="given_name" value="firstName"/&amp;gt;&lt;BR /&gt;&amp;lt;beans:entry key="family_name" value="lastName"/&amp;gt;&lt;BR /&gt;&amp;lt;/beans:map&amp;gt;&lt;BR /&gt;&amp;lt;/beans&lt;img id="smileytongue" class="emoticon emoticon-smileytongue" src="https://connect.hyland.com/i/smilies/16x16_smiley-tongue.png" alt="Smiley Tongue" title="Smiley Tongue" /&gt;roperty&amp;gt;&lt;BR /&gt;&amp;lt;/beans:bean&amp;gt;&lt;BR /&gt;&amp;lt;/beans:beans&amp;gt;&lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;Este arquivo mapeia os atributos do token (email, given_name, family_name) para os campos correspondentes no Alfresco (email, firstName, lastName).&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;H3 id="toc-hId--1067947934"&gt;Validação&lt;/H3&gt;&lt;P&gt;Depois de fazer essas configurações, reinicie o Alfresco para aplicar as mudanças. Certifique-se de que os tokens emitidos pelo Keycloak contenham o campo de email e verifique os registros de usuário no Alfresco para ver se o campo de email está sendo sincronizado corretamente.&lt;/P&gt;&lt;P&gt;Se continuar tendo problemas, revise os logs do Alfresco para identificar qualquer erro relacionado à autenticação e mapeamento de atributos.&lt;/P&gt;&lt;P&gt;Se precisar de mais ajuda, por favor me avise.&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/LI&gt;&lt;/OL&gt;</description>
      <pubDate>Wed, 19 Jun 2024 10:05:50 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111945#M78774</guid>
      <dc:creator>cristinamr</dc:creator>
      <dc:date>2024-06-19T10:05:50Z</dc:date>
    </item>
    <item>
      <title>Re: Mapeamento dos campos do cadastro de usuário entre Keycloak e alfresco</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111946#M78775</link>
      <description>&lt;P&gt;Cara&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/4825"&gt;@cristinamr&lt;/A&gt;&amp;nbsp;desculpe pela demora em responder...&lt;/P&gt;&lt;P&gt;Obrigada pela resposta.&lt;/P&gt;&lt;P&gt;Infelizmente não tive muito sucesso. Após as configurações fiquei com este erro no log do share e não consegui acesso ao share...&lt;BR /&gt;ERROR [alfresco.web.site] [http-nio-8080-exec-1] org.springframework.security.oauth2.core.OAuth2AuthenticationException: [invalid_token_response] An error occurred while attempting to retrieve the OAuth 2.0 Access Token Response: 401 Unauthorized: [no body]&lt;/P&gt;&lt;P&gt;Voltei as configurações ao ponto onde estava logando...&lt;/P&gt;&lt;P&gt;Segui um pouco desta &lt;A href="https://github.com/aborroy/alfresco-identity-service-to-keycloak/tree/main" target="_self" rel="nofollow noopener noreferrer"&gt;postagem&lt;/A&gt; do&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/5487"&gt;@angelborroy&lt;/A&gt;&amp;nbsp;e também &lt;A href="https://github.com/Acosix/alfresco-keycloak/tree/master" target="_self" rel="nofollow noopener noreferrer"&gt;desta&lt;/A&gt; do&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16045"&gt;@afaust&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Também usei alguns detalhes desta &lt;A href="https://stackoverflow.com/questions/58541006/integrating-keycloak-with-alfresco" target="_self" rel="nofollow noopener noreferrer"&gt;postagem&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;Meu cenário é o seguinte...&lt;/P&gt;&lt;P&gt;Tenho no&amp;nbsp;alfresco-global.properties:&lt;/P&gt;&lt;P&gt;authentication.chain=identity-service1:identity-service&lt;/P&gt;&lt;P&gt;identity-service.enable-basic-auth=true&lt;BR /&gt;identity-service.auth-server-url=&lt;A href="https://meudominiokeycloak.com.br" target="_blank" rel="nofollow noopener noreferrer"&gt;https://meudominiokeycloak.com.br&lt;/A&gt;&lt;BR /&gt;identity-service.realm=alfresco&lt;BR /&gt;identity-service.resource=alfresco&lt;BR /&gt;&lt;BR /&gt;aims.enabled=true&lt;BR /&gt;aims.realm=alfresco&lt;BR /&gt;aims.resource=alfresco&lt;BR /&gt;aims.authServerUrl=&lt;A href="https://meudominiokeycloak.com.br" target="_blank" rel="nofollow noopener noreferrer"&gt;https://meudominiokeycloak.com.br&lt;/A&gt;&lt;BR /&gt;aims.publicClient=true&lt;/P&gt;&lt;P&gt;No&amp;nbsp;share-config-custom.xml:&lt;/P&gt;&lt;P&gt;&amp;lt;!-- AIMS --&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;config evaluator="string-compare" condition="AIMS"&amp;gt;&lt;BR /&gt;&amp;lt;enabled&amp;gt;true&amp;lt;/enabled&amp;gt;&lt;BR /&gt;&amp;lt;realm&amp;gt;alfresco&amp;lt;/realm&amp;gt;&lt;BR /&gt;&amp;lt;resource&amp;gt;alfresco&amp;lt;/resource&amp;gt;&lt;BR /&gt;&amp;lt;authServerUrl&amp;gt;&lt;A href="https://meukeycloak.com.br" target="_blank" rel="nofollow noopener noreferrer"&gt;https://meukeycloak.com.br&lt;/A&gt;&amp;lt;/authServerUrl&amp;gt;&lt;BR /&gt;&amp;lt;sslRequired&amp;gt;none&amp;lt;/sslRequired&amp;gt;&lt;BR /&gt;&amp;lt;publicClient&amp;gt;true&amp;lt;/publicClient&amp;gt;&lt;BR /&gt;&amp;lt;autodetectBearerOnly&amp;gt;true&amp;lt;/autodetectBearerOnly&amp;gt;&lt;BR /&gt;&amp;lt;alwaysRefreshToken&amp;gt;true&amp;lt;/alwaysRefreshToken&amp;gt;&lt;BR /&gt;&amp;lt;principalAttribute&amp;gt;email&amp;lt;/principalAttribute&amp;gt;&lt;BR /&gt;&amp;lt;enableBasicAuth&amp;gt;true&amp;lt;/enableBasicAuth&amp;gt;&lt;BR /&gt;&amp;lt;/config&amp;gt;&lt;/P&gt;&lt;P&gt;Consigo logar no share e também consegui logar via keycloak no Workspace fazendo alterações no app.config.json.&lt;/P&gt;&lt;P&gt;Mas não consigo mapear, por exemplo o valor da propriedade email do cadastro de usuário no keycloak para o campo email no alfresco.&lt;/P&gt;&lt;P&gt;Help&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/16045"&gt;@afaust&lt;/A&gt;,&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/5487"&gt;@angelborroy&lt;/A&gt;&amp;nbsp;and&amp;nbsp;&lt;A href="https://migration33.stage.lithium.com/t5/user/viewprofilepage/user-id/4825"&gt;@cristinamr&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jun 2024 19:33:05 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/mapeamento-dos-campos-do-cadastro-de-usu%C3%A1rio-entre-keycloak-e/m-p/111946#M78775</guid>
      <dc:creator>fmayconcs</dc:creator>
      <dc:date>2024-06-20T19:33:05Z</dc:date>
    </item>
  </channel>
</rss>

