[AWS Error] com.amazonaws.AmazonServiceException: Cross-account pass role is not allowed. (Service: AWSLambda; Status Code: 403; Error Code: AccessDeniedException; Request ID: xxx)

2024. 2. 7. 17:25·Error code 모음/11. Aws errors
반응형

 

 

1. 원인


  • A 계정에서 B 계정에 접속해서 작업을 하려고 할 때,
  • 작업을 위해 B계정의 특정 Role 을 부여 받는데, 그 때 B계정에서 부여받은 role 을
  • A 계정이 이용할 권한이 없으면 발생하는 에러

 

 

 

 

2. 해결 방법


  • 신뢰 관계에서 sts:assumerole 의 principal 에 A계정의 유저를 추가
{
   "Version":"2012-10-17",
   "Statement":[
      {
         "Effect":"Allow",
         "Principal":{
            "AWS":[
               "arn:aws:iam::123456789012:user/user1",
               "arn:aws:iam::123456789012:user/user2"
            ],
            "Service":"ec2.amazonaws.com"
         },
         "Action":"sts:AssumeRole"
      }
   ]
}

 

 

 

3. 참고 링크


https://maxrohde.com/2016/06/27/aws-lambda-cross-account-pass-role-is-not-allowed

 

AWS Lambda: Cross-account pass role is not allowed.

Connect on social networks: Code of Joy Coding tutorials and contemplations on leadership and philosophy. © 2023 Copyright: Max Rohde

maxrohde.com

 

반응형
저작자표시 비영리 변경금지 (새창열림)

'Error code 모음 > 11. Aws errors' 카테고리의 다른 글

[Redshift Error] Caused by: com.amazon.redshift.util.RedshiftException: ERROR: COPY with MANIFEST parameter requires full path of an S3 object  (0) 2024.03.06
[RDS Error] Cannot create a publicly accessible DBInstance. The specified VPC does not support DNS resolution, DNS hostnames, or both. Update the VPC and then try again (Service: AmazonRDS; Status Code: 400; Error Code: InvalidVPCNetworkStateFault  (0) 2024.03.06
[AWS ERROR] AccessDeniedException when calling the PutJobSuccessResult  (0) 2024.02.07
[AWS Error] EMR spark error : java.lang.ClassNotFoundException: Failed to find data source: ...  (0) 2022.03.03
[AWS Lambda Error] Unable to import module 'lambda_function': No module named 'tqdm'  (0) 2022.02.07
'Error code 모음/11. Aws errors' 카테고리의 다른 글
  • [Redshift Error] Caused by: com.amazon.redshift.util.RedshiftException: ERROR: COPY with MANIFEST parameter requires full path of an S3 object
  • [RDS Error] Cannot create a publicly accessible DBInstance. The specified VPC does not support DNS resolution, DNS hostnames, or both. Update the VPC and then try again (Service: AmazonRDS; Status Code: 400; Error Code: InvalidVPCNetworkStateFault
  • [AWS ERROR] AccessDeniedException when calling the PutJobSuccessResult
  • [AWS Error] EMR spark error : java.lang.ClassNotFoundException: Failed to find data source: ...
쟈누
쟈누
Ad astra per aspera
    반응형
  • 쟈누
    쟈누의 기록공간
    쟈누
  • 전체
    오늘
    어제
    • 분류 전체보기 (444)
      • AWS (31)
        • Glue (4)
        • S3 (1)
      • 클라우드 (0)
      • Data Engineering (37)
        • GitHub (10)
        • NiFi (11)
        • Spark (10)
        • Snowflake (0)
        • 머신러닝, AI (6)
      • 언어 (118)
        • 데이터 베이스 (42)
        • JAVA (9)
        • Python (34)
        • Java Script (15)
        • Linux (18)
      • 프로젝트, 인강 그리고 책 (30)
        • Spotify Project (7)
        • RASA chatbot Project (9)
        • Naver shopping Project (6)
        • 빅데이터를 지탱하는 기술 (8)
      • OLD (56)
        • IT 용어 사전 (13)
        • Front End (12)
        • Back End (31)
      • Error code 모음 (165)
        • 1. SQL errors (17)
        • 2. Hadoop errors (20)
        • 3. Linux Errors (14)
        • 4. Python errors (33)
        • 5. JAVA, Spring errors (41)
        • 6. Jav Script errors (10)
        • 7. Dev Tools errors (9)
        • 8. Git errors (8)
        • 9. Jenkins Errors (4)
        • 10. airflow Errors (2)
        • 11. Aws errors (7)
      • 개인 (1)
        • 책 (1)
  • 블로그 메뉴

    • 홈
    • 태그
    • 방명록
    • 블로그 관리
    • 글쓰기
  • 링크

  • 공지사항

    • 간단한 블로그 소개
  • 인기 글

  • 태그

    리눅스
    Git
    node
    Python
    파이썬
    python error
    NiFi
    install
    java
    json
    error
    에러
    MySQL
    linux
    API
    SQL
    Spring
    설치
    AWS
    자바
  • 최근 댓글

  • 최근 글

  • hELLO· Designed By정상우.v4.10.3
쟈누
[AWS Error] com.amazonaws.AmazonServiceException: Cross-account pass role is not allowed. (Service: AWSLambda; Status Code: 403; Error Code: AccessDeniedException; Request ID: xxx)
상단으로

티스토리툴바