Options
All
  • Public
  • Public/Protected
  • All
Menu

Module @aws-sdk/middleware-bucket-endpoint

Index

References

Interfaces

Variables

Functions

Object literals

References

BucketEndpointInputConfig

Re-exports BucketEndpointInputConfig

BucketEndpointResolvedConfig

Re-exports BucketEndpointResolvedConfig

BucketHostname

Re-exports BucketHostname

NODE_DISABLE_MULTIREGION_ACCESS_POINT_CONFIG_OPTIONS

Re-exports NODE_DISABLE_MULTIREGION_ACCESS_POINT_CONFIG_OPTIONS

NODE_DISABLE_MULTIREGION_ACCESS_POINT_ENV_NAME

Re-exports NODE_DISABLE_MULTIREGION_ACCESS_POINT_ENV_NAME

NODE_DISABLE_MULTIREGION_ACCESS_POINT_INI_NAME

Re-exports NODE_DISABLE_MULTIREGION_ACCESS_POINT_INI_NAME

NODE_USE_ARN_REGION_CONFIG_OPTIONS

Re-exports NODE_USE_ARN_REGION_CONFIG_OPTIONS

NODE_USE_ARN_REGION_ENV_NAME

Re-exports NODE_USE_ARN_REGION_ENV_NAME

NODE_USE_ARN_REGION_INI_NAME

Re-exports NODE_USE_ARN_REGION_INI_NAME

bucketEndpointMiddleware

Re-exports bucketEndpointMiddleware

bucketEndpointMiddlewareOptions

Re-exports bucketEndpointMiddlewareOptions

bucketHostname

Re-exports bucketHostname

getArnResources

Re-exports getArnResources

getBucketEndpointPlugin

Re-exports getBucketEndpointPlugin

getSuffixForArnEndpoint

Re-exports getSuffixForArnEndpoint

resolveBucketEndpointConfig

Re-exports resolveBucketEndpointConfig

validateAccountId

Re-exports validateAccountId

validateDNSHostLabel

Re-exports validateDNSHostLabel

validateNoDualstack

Re-exports validateNoDualstack

validateNoFIPS

Re-exports validateNoFIPS

validateOutpostService

Re-exports validateOutpostService

validatePartition

Re-exports validatePartition

validateRegion

Re-exports validateRegion

Variables

Const AWS_PARTITION_SUFFIX

AWS_PARTITION_SUFFIX: "amazonaws.com" = "amazonaws.com"

Const DOMAIN_PATTERN

DOMAIN_PATTERN: RegExp = /^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/

Const DOTS_PATTERN

DOTS_PATTERN: RegExp = /\.\./

Const DOT_PATTERN

DOT_PATTERN: RegExp = /\./

Const IP_ADDRESS_PATTERN

IP_ADDRESS_PATTERN: RegExp = /(\d+\.){3}\d+/

Const NODE_DISABLE_MULTIREGION_ACCESS_POINT_ENV_NAME

NODE_DISABLE_MULTIREGION_ACCESS_POINT_ENV_NAME: "AWS_S3_DISABLE_MULTIREGION_ACCESS_POINTS" = "AWS_S3_DISABLE_MULTIREGION_ACCESS_POINTS"

Const NODE_DISABLE_MULTIREGION_ACCESS_POINT_INI_NAME

NODE_DISABLE_MULTIREGION_ACCESS_POINT_INI_NAME: "s3_disable_multiregion_access_points" = "s3_disable_multiregion_access_points"

Const NODE_USE_ARN_REGION_ENV_NAME

NODE_USE_ARN_REGION_ENV_NAME: "AWS_S3_USE_ARN_REGION" = "AWS_S3_USE_ARN_REGION"

Const NODE_USE_ARN_REGION_INI_NAME

NODE_USE_ARN_REGION_INI_NAME: "s3_use_arn_region" = "s3_use_arn_region"

Const S3_HOSTNAME_PATTERN

S3_HOSTNAME_PATTERN: RegExp = /^(.+\.)?s3(-fips)?(\.dualstack)?[.-]([a-z0-9-]+)\./

Const S3_US_EAST_1_ALTNAME_PATTERN

S3_US_EAST_1_ALTNAME_PATTERN: RegExp = /^s3(-external-1)?\.amazonaws\.com$/

Functions

Const bucketEndpointMiddleware

Const bucketHostname

Const getArnResources

  • getArnResources(resource: string): { accesspointName: string; outpostId?: string }
  • Validate and parse an Access Point ARN or Outposts ARN

    internal

    Parameters

    • resource: string

      The resource section of an ARN

    Returns { accesspointName: string; outpostId?: string }

    Access Point Name and optional Outpost ID.

    • accesspointName: string
    • Optional outpostId?: string

Const getBucketEndpointPlugin

Const getEndpointFromAccessPointArn

  • getEndpointFromAccessPointArn(__namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; tlsCompatible: boolean; useArnRegion: boolean }): BucketHostname
  • Parameters

    • __namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; tlsCompatible: boolean; useArnRegion: boolean }
      • accesspointName: string
      • bucketName: ARN
      • clientRegion: string
      • clientSigningRegion: string
      • dualstackEndpoint: boolean
      • fipsEndpoint: boolean
      • hostnameSuffix: string
      • isCustomEndpoint: boolean
      • tlsCompatible: boolean
      • useArnRegion: boolean

    Returns BucketHostname

Const getEndpointFromArn

Const getEndpointFromBucketName

  • getEndpointFromBucketName(__namedParameters: { accelerateEndpoint: boolean; baseHostname: string; bucketName: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; isCustomEndpoint: boolean; pathStyleEndpoint: boolean; region: string; tlsCompatible: boolean }): BucketHostname
  • Parameters

    • __namedParameters: { accelerateEndpoint: boolean; baseHostname: string; bucketName: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; isCustomEndpoint: boolean; pathStyleEndpoint: boolean; region: string; tlsCompatible: boolean }
      • accelerateEndpoint: boolean
      • baseHostname: string
      • bucketName: string
      • dualstackEndpoint: boolean
      • fipsEndpoint: boolean
      • isCustomEndpoint: boolean
      • pathStyleEndpoint: boolean
      • region: string
      • tlsCompatible: boolean

    Returns BucketHostname

Const getEndpointFromMRAPArn

  • getEndpointFromMRAPArn(__namedParameters: { disableMultiregionAccessPoints: boolean; dualstackEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; mrapAlias: string }): BucketHostname
  • Parameters

    • __namedParameters: { disableMultiregionAccessPoints: boolean; dualstackEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; mrapAlias: string }
      • disableMultiregionAccessPoints: boolean
      • dualstackEndpoint: boolean
      • hostnameSuffix: string
      • isCustomEndpoint: boolean
      • mrapAlias: string

    Returns BucketHostname

Const getEndpointFromObjectLambdaArn

  • getEndpointFromObjectLambdaArn(__namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; tlsCompatible: boolean; useArnRegion: boolean }): BucketHostname
  • Parameters

    • __namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; tlsCompatible: boolean; useArnRegion: boolean }
      • accesspointName: string
      • bucketName: ARN
      • clientRegion: string
      • clientSigningRegion: string
      • dualstackEndpoint: boolean
      • fipsEndpoint: boolean
      • hostnameSuffix: string
      • tlsCompatible: boolean
      • useArnRegion: boolean

    Returns BucketHostname

Const getEndpointFromOutpostArn

  • getEndpointFromOutpostArn(__namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; outpostId: string; tlsCompatible: boolean; useArnRegion: boolean }): BucketHostname
  • Parameters

    • __namedParameters: { accesspointName: string; bucketName: ARN; clientRegion: string; clientSigningRegion: string; dualstackEndpoint: boolean; fipsEndpoint: boolean; hostnameSuffix: string; isCustomEndpoint: boolean; outpostId: string; tlsCompatible: boolean; useArnRegion: boolean }
      • accesspointName: string
      • bucketName: ARN
      • clientRegion: string
      • clientSigningRegion: string
      • dualstackEndpoint: boolean
      • fipsEndpoint: boolean
      • hostnameSuffix: string
      • isCustomEndpoint: boolean
      • outpostId: string
      • tlsCompatible: boolean
      • useArnRegion: boolean

    Returns BucketHostname

Const getRegionalSuffix

  • getRegionalSuffix(hostname: string): [string, string]

Const getSuffix

  • getSuffix(hostname: string): [string, string]

Const getSuffixForArnEndpoint

  • getSuffixForArnEndpoint(hostname: string): [string, string]

Const isBucketNameOptions

Const isDnsCompatibleBucketName

  • isDnsCompatibleBucketName(bucketName: string): boolean

Const isEqualRegions

  • isEqualRegions(regionA: string, regionB: string): boolean

resolveBucketEndpointConfig

Const validateAccountId

  • validateAccountId(accountId: string): void

Const validateArnEndpointOptions

  • validateArnEndpointOptions(options: { accelerateEndpoint?: boolean; pathStyleEndpoint?: boolean; tlsCompatible?: boolean }): void

Const validateCustomEndpoint

  • validateCustomEndpoint(options: { accelerateEndpoint?: boolean; dualstackEndpoint?: boolean; isCustomEndpoint?: boolean }): void

Const validateDNSHostLabel

  • validateDNSHostLabel(label: string, options?: { tlsCompatible?: boolean }): void

Private Const validateMrapAlias

  • validateMrapAlias(name: string): void

Const validateNoDualstack

  • validateNoDualstack(dualstackEndpoint?: boolean): void

Const validateNoFIPS

  • validateNoFIPS(useFipsEndpoint?: boolean): void

Const validateOutpostService

  • validateOutpostService(service: string): void

Const validatePartition

  • validatePartition(partition: string, options: { clientPartition: string }): void

Const validateRegion

  • validateRegion(region: string, options: { allowFipsRegion?: boolean; clientRegion: string; clientSigningRegion: string; useArnRegion?: boolean; useFipsEndpoint: boolean }): void
  • validate region value inferred from ARN. If options.useArnRegion is set, it validates the region is not a FIPS region. If options.useArnRegion is unset, it validates the region is equal to options.clientRegion or options.clientSigningRegion.

    internal

    Parameters

    • region: string
    • options: { allowFipsRegion?: boolean; clientRegion: string; clientSigningRegion: string; useArnRegion?: boolean; useFipsEndpoint: boolean }
      • Optional allowFipsRegion?: boolean
      • clientRegion: string
      • clientSigningRegion: string
      • Optional useArnRegion?: boolean
      • useFipsEndpoint: boolean

    Returns void

Const validateRegionalClient

  • validateRegionalClient(region: string): void

Const validateS3Service

  • validateS3Service(service: string): void

Const validateService

  • validateService(service: string): void

Object literals

Const NODE_DISABLE_MULTIREGION_ACCESS_POINT_CONFIG_OPTIONS

NODE_DISABLE_MULTIREGION_ACCESS_POINT_CONFIG_OPTIONS: object

default

default: false = false

configFileSelector

  • configFileSelector(profile: Profile): boolean

environmentVariableSelector

  • environmentVariableSelector(env: ProcessEnv): boolean

Const NODE_USE_ARN_REGION_CONFIG_OPTIONS

NODE_USE_ARN_REGION_CONFIG_OPTIONS: object

Config to load useArnRegion from environment variables and shared INI files

api

private

default

default: false = false

configFileSelector

  • configFileSelector(profile: Profile): boolean

environmentVariableSelector

  • environmentVariableSelector(env: ProcessEnv): boolean

Const bucketEndpointMiddlewareOptions

bucketEndpointMiddlewareOptions: object

name

name: string = "bucketEndpointMiddleware"

override

override: true = true

relation

relation: "before" = "before"

tags

tags: string[] = ["BUCKET_ENDPOINT"]

toMiddleware

toMiddleware: string = "hostHeaderMiddleware"