amazonka-servicecatalog-2.0: Amazon Service Catalog SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Description

Associates the specified principal ARN with the specified portfolio.

If you share the portfolio with principal name sharing enabled, the PrincipalARN association is included in the share.

The PortfolioID, PrincipalARN, and PrincipalType parameters are required.

You can associate a maximum of 10 Principals with a portfolio using PrincipalType as IAM_PATTERN

When you associate a principal with portfolio, a potential privilege escalation path may occur when that portfolio is then shared with other accounts. For a user in a recipient account who is not an Service Catalog Admin, but still has the ability to create Principals (Users/Groups/Roles), that user could create a role that matches a principal name association for the portfolio. Although this user may not know which principal names are associated through Service Catalog, they may be able to guess the user. If this potential escalation path is a concern, then Service Catalog recommends using PrincipalType as IAM. With this configuration, the PrincipalARN must already exist in the recipient account before it can be associated.

Synopsis

Creating a Request

data AssociatePrincipalWithPortfolio Source #

See: newAssociatePrincipalWithPortfolio smart constructor.

Constructors

AssociatePrincipalWithPortfolio' 

Fields

  • acceptLanguage :: Maybe Text

    The language code.

    • en - English (default)
    • jp - Japanese
    • zh - Chinese
  • portfolioId :: Text

    The portfolio identifier.

  • principalARN :: Text

    The ARN of the principal (IAM user, role, or group). This field allows an ARN with no accountID if PrincipalType is IAM_PATTERN.

    You can associate multiple IAM patterns even if the account has no principal with that name. This is useful in Principal Name Sharing if you want to share a principal without creating it in the account that owns the portfolio.

  • principalType :: PrincipalType

    The principal type. The supported value is IAM if you use a fully defined ARN, or IAM_PATTERN if you use an ARN with no accountID.

Instances

Instances details
ToJSON AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

ToHeaders AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

ToPath AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

ToQuery AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

AWSRequest AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Generic AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Associated Types

type Rep AssociatePrincipalWithPortfolio :: Type -> Type #

Read AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Show AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

NFData AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Eq AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Hashable AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

type AWSResponse AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

type Rep AssociatePrincipalWithPortfolio Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

type Rep AssociatePrincipalWithPortfolio = D1 ('MetaData "AssociatePrincipalWithPortfolio" "Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio" "amazonka-servicecatalog-2.0-HQc7wwDA1XY4nlo6issXoI" 'False) (C1 ('MetaCons "AssociatePrincipalWithPortfolio'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "acceptLanguage") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "portfolioId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text)) :*: (S1 ('MetaSel ('Just "principalARN") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "principalType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 PrincipalType))))

newAssociatePrincipalWithPortfolio Source #

Create a value of AssociatePrincipalWithPortfolio with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:acceptLanguage:AssociatePrincipalWithPortfolio', associatePrincipalWithPortfolio_acceptLanguage - The language code.

  • en - English (default)
  • jp - Japanese
  • zh - Chinese

AssociatePrincipalWithPortfolio, associatePrincipalWithPortfolio_portfolioId - The portfolio identifier.

AssociatePrincipalWithPortfolio, associatePrincipalWithPortfolio_principalARN - The ARN of the principal (IAM user, role, or group). This field allows an ARN with no accountID if PrincipalType is IAM_PATTERN.

You can associate multiple IAM patterns even if the account has no principal with that name. This is useful in Principal Name Sharing if you want to share a principal without creating it in the account that owns the portfolio.

AssociatePrincipalWithPortfolio, associatePrincipalWithPortfolio_principalType - The principal type. The supported value is IAM if you use a fully defined ARN, or IAM_PATTERN if you use an ARN with no accountID.

Request Lenses

associatePrincipalWithPortfolio_acceptLanguage :: Lens' AssociatePrincipalWithPortfolio (Maybe Text) Source #

The language code.

  • en - English (default)
  • jp - Japanese
  • zh - Chinese

associatePrincipalWithPortfolio_principalARN :: Lens' AssociatePrincipalWithPortfolio Text Source #

The ARN of the principal (IAM user, role, or group). This field allows an ARN with no accountID if PrincipalType is IAM_PATTERN.

You can associate multiple IAM patterns even if the account has no principal with that name. This is useful in Principal Name Sharing if you want to share a principal without creating it in the account that owns the portfolio.

associatePrincipalWithPortfolio_principalType :: Lens' AssociatePrincipalWithPortfolio PrincipalType Source #

The principal type. The supported value is IAM if you use a fully defined ARN, or IAM_PATTERN if you use an ARN with no accountID.

Destructuring the Response

data AssociatePrincipalWithPortfolioResponse Source #

Constructors

AssociatePrincipalWithPortfolioResponse' 

Fields

Instances

Instances details
Generic AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Read AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Show AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

NFData AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

Eq AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

type Rep AssociatePrincipalWithPortfolioResponse Source # 
Instance details

Defined in Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio

type Rep AssociatePrincipalWithPortfolioResponse = D1 ('MetaData "AssociatePrincipalWithPortfolioResponse" "Amazonka.ServiceCatalog.AssociatePrincipalWithPortfolio" "amazonka-servicecatalog-2.0-HQc7wwDA1XY4nlo6issXoI" 'False) (C1 ('MetaCons "AssociatePrincipalWithPortfolioResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newAssociatePrincipalWithPortfolioResponse Source #

Create a value of AssociatePrincipalWithPortfolioResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:httpStatus:AssociatePrincipalWithPortfolioResponse', associatePrincipalWithPortfolioResponse_httpStatus - The response's http status code.

Response Lenses