Skip to content

Enhancement: Transform cloudformation in http api authorizers #10

Description

@Ankcorn

Transforming any cloud formation referenced in the custom authorizers section would help with building ephemeral authenticated API's. I think if this plugin looped through the authorizers array the same way it did the functions it could support this.

httpApi:
    payload: "2.0"
    authorizers:
      Authorizer:
        identitySource: $request.header.Authorization
        issuerUrl: !GetAtt UserPool.ProviderURL
        audience: !Ref UserPoolClient

I'm working on an over-engineered boilerplate and am trying to get everything working both locally and in the cloud

https://github.com/Ankcorn/serverless-fullstack-example-app

run npm i && serverless deploy --stage local && npm start

The jwt is from the wrong issuer when requests go react app -> serverless offline backend because the issuer is

{
   authorizerName: 'Authorizer',
   name: 'Authorizer',
   identitySource: '$request.header.Authorization',
   issuerUrl: { 'Fn::GetAtt': [ 'UserPool', 'ProviderURL' ] },
   audience: { Ref: 'UserPoolClient' }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions