TDTech Digest

119. Client Credentials Grant 인증 설정 (Set up Client Credentials Grant authentication)

  • 원문: English
  • 위치: Additional capabilities › Knowledge Bases › Build a managed knowledge base › Create a managed knowledge base › Connect a data source › Box › Set up Client Credentials Grant authentication

한 줄 요약

Box 데이터 소스의 권장 인증 방식인 CCG(2LO) 설정 절차입니다. 사용자 로그인 없이 서비스 계정으로 엔터프라이즈 전체를 크롤링하며, ACL을 지원하는 유일한 방식입니다.

쉽게 말하면

Box Developer Console에서 “서버 인증용 앱"을 만들고, 권한을 넉넉히 준 뒤 관리자 승인을 받고, 키 4개를 Secrets Manager에 넣으면 됩니다.

핵심 내용

단계 요약

단계할 일주의
1. 앱 생성Box Developer Console › Create a New App › Server Authentication › Client Credentials Grant
2. 권한 구성App Access Level: App + Enterprise Access⚠️ 없으면 엔터프라이즈 데이터를 못 보고 크롤링 실패
Content actions: Read All Files and Folders + Write All Files and Folders⚠️ Box는 다운로드를 쓰기(write)로 취급하므로 읽기 전용 크롤링에도 Write 필수
Administrative actions: Manage Users, Manage GroupsACL용. ACL 불필요 시 생략 가능. Box는 읽기 전용 옵션이 없음
Make API calls using the as-user header 켜기, Generate user access tokens는 끄기사용자별 콘텐츠 크롤링용 위임
3. 자격 증명 수집Client ID, Fetch Secret으로 Client Secret, Properties의 User ID·Enterprise ID💡 Client Secret은 자동 표시 안 됨. 저장 직후 바로 Fetch
4. 앱 승인Authorize 클릭 → 엔터프라이즈 관리자 승인⚠️ “Not Submitted” 상태면 런타임에 실패
5. 시크릿 생성아래 JSON을 Secrets Manager에 저장ARN을 데이터 소스 secretArn에 사용

시크릿 형식

{
  "clientId": "your-client-id",
  "clientSecret": "your-client-secret",
  "enterpriseId": "your-enterprise-id",
  "ccgUserId": "your-user-id"
}
키출처 / 의미
clientIdApp Details › Access
clientSecret저장 후 Fetch Secret
enterpriseIdProperties. 크롤링할 Box 엔터프라이즈 식별
ccgUserIdProperties. 사용자로 위임 가능한지 검증용
  • 다음 단계: authType을 CCG로 데이터 소스 생성 → 122, ACL → 123

SA 관점

  • 고객 보안팀이 “Write 권한, Manage Users/Groups 권한"에 거부감을 보일 수 있습니다. Box 측 사양(다운로드=write, 관리 권한은 전체 세트만 제공)이라는 원문 근거를 미리 공유하세요.
  • 앱 자격 증명이 엔터프라이즈 전체 접근 권한을 가지므로 시크릿은 CMK 암호화·접근 최소화·로테이션 계획을 함께 세우는 것이 좋습니다.