Keycloak — Auto Redirect ไปยัง Identity Provider (auth0.com) โดยไม่แสดงหน้า Login ของ Keycloak

wk
2 min readJun 1, 2020

--

ความต้องการ

  1. Login Web App ผ่าน Keycloak โดย Keycloak ผูกอยู่กับ Identity Provider อีกชั้น เช่น auth0.com
  2. ไม่ต้องแสดงหน้า Login ของ Keycloak แต่ให้ Redirect ไปยังหน้า Login ของ auth0.com
  3. ไม่ต้องอัปเดต/เพิ่ม User Profile บน Keycloak หลังจาก Login ครั้งแรก (ถึงแม้ใน Keycloak จะไม่มี User Profile นั้นอยู่)

ขั้นตอน

ตัวอย่างนี้จะแสดงเฉพาะการตั้งค่าใน Keycloak โดยไม่มีรายละเอียดของการ Implement Web App และการตั้งค่าใน auth0.com

  1. เพิ่ม Identity Provider ผ่าน SAML 2 โดย IdP ที่ใช้ oauth0.com

2. ตั้งค่า Authentications โดยเลือก Identity Provider Redirector (Auto) เป็น Alternative

3. เพิ่ม Actions เซ็ต Default Identity Providerโดยใช้ Alias ในข้อ 1. เช่น auth0

4. ปรับค่า First Broker Login โดยปรับ Review Profile (review profile config) จาก REQUIRED เป็น DISABLE

--

--

No responses yet