Skip to content

Source ARN like arn:aws:sqs:eu-central-1:12345:queue-name is rejected #12

Description

@joern-belonio

Current Behavior

Its not possible to deploy with a valid sqs source arn, because arn:aws:sqs:eu-central-1:12345:queue-name the decimals in the regex are not escaped.

^arn:(aws[a-zA-Z0-9-]*):([a-zA-Z0-9-]+):([a-z]{2}((-gov)|(-iso(b?)))?-[a-z]+-d{1})?:(d{12})?:(.+)$

d{1} means 1 character d, but expected is \d{1} as one digit in eu-central-1

Expected Behavior

Valid arns should be accepted

Steps to Reproduce the Problem

  1. create a pipe with SQS Source in region eu-central-1
  2. sls deploy
  3. fails with "EventBridge Pipes Resource creation Failed: arn property is invalid for "

Fix:

escape d{1} and d{12} in regex with double backslash (\d)

Environment

  • Version: 1.0.1
  • Platform: Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions