Skip to content

Crash in Client Initialization due to possible race condition #3531

@wmorgan6796

Description

@wmorgan6796

Describe the bug

Issue we're seeing:

 level=INFO time=2025-09-03T19:43:11.748372Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use SDK Auto Resolved profile: [default] if not specified by users."
 level=INFO time=2025-09-03T19:43:11.748426Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Environment value for variable HOME is /home/nonroot"
 level=INFO time=2025-09-03T19:43:11.748438Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Home directory is missing the final / appending one to normalize"
 level=INFO time=2025-09-03T19:43:11.748447Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Final Home Directory is /home/nonroot/"
 level=INFO time=2025-09-03T19:43:11.748458Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=Aws::Config::AWSConfigFileProfileConfigLoader msg="Initializing config loader against fileName /home/nonroot/.aws/credentials and using profilePrefix = 0"
 level=INFO time=2025-09-03T19:43:11.748469Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Environment value for variable HOME is /home/nonroot"
 level=INFO time=2025-09-03T19:43:11.748479Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Home directory is missing the final / appending one to normalize"
 level=INFO time=2025-09-03T19:43:11.748488Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Final Home Directory is /home/nonroot/"
 level=INFO time=2025-09-03T19:43:11.748497Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Environment value for variable HOME is /home/nonroot"
 level=INFO time=2025-09-03T19:43:11.748506Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Home directory is missing the final / appending one to normalize"
 level=INFO time=2025-09-03T19:43:11.748514Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=FileSystemUtils msg="[AWS-DEBUG] Final Home Directory is /home/nonroot/"
 level=INFO time=2025-09-03T19:43:11.748524Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=ProfileConfigFileAWSCredentialsProvider msg="Setting provider to read credentials from /home/nonroot/.aws/credentials for credentials file and /home/nonroot/.aws/config for the config file , for use with profile default"
 level=INFO time=2025-09-03T19:43:11.748535Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=ProcessCredentialsProvider msg="Setting process credentials provider to read config from default"
 level=INFO time=2025-09-03T19:43:11.752858Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=tls-handler msg="[AWS-DEBUG] Set security policy to AWS-CRT-SDK-TLSv1.0-2023 (minimum_tls_version: 128; cipher_pref: 0)\x00"
 level=INFO time=2025-09-03T19:43:11.757905Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=AuthCredentialsProvider msg="[AWS-DEBUG] Successfully loaded all required parameters for sts web identity credentials provider.\x00"
 level=INFO time=2025-09-03T19:43:11.757932Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=channel-bootstrap msg="[AWS-DEBUG] id=0x7f0915b1f8d0: acquiring bootstrap reference\x00"
 level=INFO time=2025-09-03T19:43:11.757945Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=connection-manager msg="id=0x7f0907159800: Successfully created\x00"
 level=INFO time=2025-09-03T19:43:11.758308Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] Request Compression enabled"
 level=INFO time=2025-09-03T19:43:11.758321Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use MinReqCompression: 10240"
 level=INFO time=2025-09-03T19:43:11.758330Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use SDK Auto Resolved profile: [default] if not specified by users."
 level=INFO time=2025-09-03T19:43:11.758348Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=SSOBearerTokenProvider msg="Setting sso bearerToken provider to read config from default"
 level=INFO time=2025-09-03T19:43:11.758358Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=SSOCredentialsProvider msg="Setting sso credentials provider to read config from default"
 level=INFO time=2025-09-03T19:43:11.758367Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] Request Compression enabled"
 level=INFO time=2025-09-03T19:43:11.758378Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use MinReqCompression: 10240"
 level=INFO time=2025-09-03T19:43:11.758405Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use SDK Auto Resolved profile: [default] if not specified by users."
 level=INFO time=2025-09-03T19:43:11.758429Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=DefaultAWSCredentialsProviderChain msg="[AWS-DEBUG] The environment variable value AWS_CONTAINER_CREDENTIALS_RELATIVE_URI is "
 level=INFO time=2025-09-03T19:43:11.758440Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=DefaultAWSCredentialsProviderChain msg="[AWS-DEBUG] The environment variable value AWS_CONTAINER_CREDENTIALS_FULL_URI is "
 level=INFO time=2025-09-03T19:43:11.758449Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=DefaultAWSCredentialsProviderChain msg="[AWS-DEBUG] The environment variable value AWS_EC2_METADATA_DISABLED is "
 level=INFO time=2025-09-03T19:43:11.758460Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] Request Compression enabled"
 level=INFO time=2025-09-03T19:43:11.758470Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use MinReqCompression: 10240"
 level=INFO time=2025-09-03T19:43:11.758478Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=ClientConfiguration msg="[AWS-DEBUG] ClientConfiguration will use SDK Auto Resolved profile: [default] if not specified by users."
 level=WARNING time=2025-09-03T19:43:11.758497Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:94  aws_sdk=ClientConfiguration msg="User specified profile: [default] is not found, will use the SDK resolved one."
 level=INFO time=2025-09-03T19:43:11.758518Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=EC2MetadataClient msg="Creating AWSHttpResourceClient with max connections 25 and scheme https"
 level=INFO time=2025-09-03T19:43:11.758530Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=CurlHandleContainer msg="Initializing CurlHandleContainer with size 25"
 level=INFO time=2025-09-03T19:43:11.758542Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=InstanceProfileCredentialsProvider msg="Creating Instance with IMDS timeout: 1s, attempts: 1"
 level=INFO time=2025-09-03T19:43:11.758552Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=DefaultAWSCredentialsProviderChain msg="Added EC2 metadata service credentials provider to the provider chain."
 level=INFO time=2025-09-03T19:43:11.758591Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=Aws::Config::AWSConfigFileProfileConfigLoader msg="Unable to open config file /home/nonroot/.aws/credentials for reading."
 level=INFO time=2025-09-03T19:43:11.758602Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=Aws::Config::AWSProfileConfigLoaderBase msg="Failed to reload configuration."
 level=INFO time=2025-09-03T19:43:11.758613Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=ProcessCredentialsProvider msg="Failed to find credential process's profile: default"
 level=INFO time=2025-09-03T19:43:11.758625Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=AuthCredentialsProvider msg="[AWS-DEBUG] id=0x7f0907060ca0: STS_WEB_IDENTITY provider trying to load credentials\x00"
 level=INFO time=2025-09-03T19:43:11.758636Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: Acquire connection\x00"
 level=INFO time=2025-09-03T19:43:11.758649Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: snapshot - state=1, idle_connection_count=0, pending_acquire_count=1, pending_settings_count=0, pending_connect_count=1, vended_connection_count=0, open_connection_count=0, ref_count=1\x00"
 level=INFO time=2025-09-03T19:43:11.758661Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:97  aws_sdk=connection-manager msg="id=0x7f0907159800: Requesting 1 new connections from http\x00"
 level=INFO time=2025-09-03T19:43:11.758673Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=channel-bootstrap msg="[AWS-DEBUG] id=0x7f0915b1f8d0: acquiring bootstrap reference\x00"
 level=INFO time=2025-09-03T19:43:11.758685Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] id=0x7f09306534c0: Host resolution requested for sts.us-west-1.amazonaws.com\x00"
 level=INFO time=2025-09-03T19:43:11.758696Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] id=0x7f09306534c0: No cached entries found for sts.us-west-1.amazonaws.com starting new resolver thread.\x00"
 level=INFO time=2025-09-03T19:43:11.758856Z thread_id=0x00007f0900731700 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] static: resolving host sts.us-west-1.amazonaws.com\x00"
 level=INFO time=2025-09-03T19:43:11.766628Z thread_id=0x00007f0900731700 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] static: resolved record: 176.32.114.104\x00"
 level=INFO time=2025-09-03T19:43:11.766666Z thread_id=0x00007f0900731700 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] static, resolving host sts.us-west-1.amazonaws.com successful, returned 1 addresses\x00"
 level=INFO time=2025-09-03T19:43:11.766686Z thread_id=0x00007f0900731700 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] static: new address resolved 176.32.114.104 for host sts.us-west-1.amazonaws.com caching\x00"
 level=INFO time=2025-09-03T19:43:11.766699Z thread_id=0x00007f0900731700 caller=aws_logger.cpp:100  aws_sdk=dns msg="[AWS-DEBUG] static, invoking resolution callback for host sts.us-west-1.amazonaws.com with 1 addresses\x00"
 level=INFO time=2025-09-03T19:43:11.766771Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket msg="[AWS-DEBUG] id=0x7f09276a8000 fd=141: initializing with domain 0 and type 0\x00"
 level=INFO time=2025-09-03T19:43:11.766800Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket msg="[AWS-DEBUG] id=0x7f09276a8000 fd=141: setting socket options to: keep-alive 0, keep-alive timeout 0, keep-alive interval 0, keep-alive probe count 0.\x00"
 level=INFO time=2025-09-03T19:43:11.766816Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket msg="[AWS-DEBUG] id=0x7f09276a8000 fd=141: beginning connect.\x00"
 level=INFO time=2025-09-03T19:43:11.766835Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket msg="[AWS-DEBUG] id=0x7f09276a8000 fd=141: connecting to endpoint 176.32.114.104:443.\x00"
 level=INFO time=2025-09-03T19:43:11.768077Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:97  aws_sdk=socket msg="id=0x7f09276a8000 fd=141: connection success\x00"
 level=INFO time=2025-09-03T19:43:11.768096Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket msg="[AWS-DEBUG] id=0x7f09276a8000 fd=141: assigning to event loop 0x7f093078b610\x00"
 level=INFO time=2025-09-03T19:43:11.768115Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel-bootstrap msg="[AWS-DEBUG] id=0x7f0915b1f8d0: client connection on socket 0x7f09276a8000 completed with error 0 : AWS_ERROR_SUCCESS\x00"
 level=INFO time=2025-09-03T19:43:11.768140Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel msg="[AWS-DEBUG] id=0x7f09276be000: Beginning creation and setup of new channel.\x00"
 level=INFO time=2025-09-03T19:43:11.768156Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel msg="[AWS-DEBUG] id=0x7f09276be000: setup complete, notifying caller.\x00"
 level=INFO time=2025-09-03T19:43:11.768175Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel msg="[AWS-DEBUG] id=0x7f09276be000: no message pool is currently stored in the event-loop local storage, adding 0x7f0927689d00 with max message size 16384, message count 4, with 4 small blocks of 128 bytes.\x00"
 level=INFO time=2025-09-03T19:43:11.768198Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel-bootstrap msg="[AWS-DEBUG] id=0x7f0915b1f8d0: channel 0x7f09276be000 setup succeeded: bootstrapping.\x00"
 level=INFO time=2025-09-03T19:43:11.768216Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=socket-handler msg="[AWS-DEBUG] id=0x7f09276dc3c0: Socket handler created with max_read_size of 16384\x00"
 level=INFO time=2025-09-03T19:43:11.770379Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=tls-handler msg="[AWS-DEBUG] id=0x7f09276be300: Remote server name is sts.us-west-1.amazonaws.com\x00"
 level=INFO time=2025-09-03T19:43:11.770403Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=channel-bootstrap msg="[AWS-DEBUG] id=0x7f0915b1f8d0: tls negotiation result 0 on channel 0x7f09276be000\x00"
 level=INFO time=2025-09-03T19:43:11.770418Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:97  aws_sdk=http-connection msg="id=0x7f09276bec00: HTTP/1.1 client connection established.\x00"
 level=INFO time=2025-09-03T19:43:11.770428Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: Received new connection (id=0x7f09276bec00) from http layer\x00"
 level=INFO time=2025-09-03T19:43:11.770439Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: Grabbing pooled connection (0x7f09276bec00)\x00"
 level=INFO time=2025-09-03T19:43:11.770451Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: snapshot - state=1, idle_connection_count=0, pending_acquire_count=0, pending_settings_count=0, pending_connect_count=0, vended_connection_count=1, open_connection_count=1, ref_count=1\x00"
 level=INFO time=2025-09-03T19:43:11.770463Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: Successfully completed connection acquisition with connection id=0x7f09276bec00\x00"
 level=INFO time=2025-09-03T19:43:11.770562Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=http-stream msg="[AWS-DEBUG] id=0x7f09276bef00: Created client request on connection=0x7f09276bec00: POST / HTTP/1.1\x00"
 level=INFO time=2025-09-03T19:43:11.786429Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=AuthCredentialsProvider msg="[AWS-DEBUG] (id=0x7f0907060ca0) STS_WEB_IDENTITY credentials provider query received http status code 200\x00"
 level=INFO time=2025-09-03T19:43:11.786455Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=http-stream msg="[AWS-DEBUG] id=0x7f09276bef00: Client request complete, response status: 200 (OK).\x00"
 level=INFO time=2025-09-03T19:43:11.786468Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: User releasing connection (id=0x7f09276bec00)\x00"
 level=INFO time=2025-09-03T19:43:11.786480Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: snapshot - state=1, idle_connection_count=1, pending_acquire_count=0, pending_settings_count=0, pending_connect_count=0, vended_connection_count=0, open_connection_count=1, ref_count=1\x00"
 level=INFO time=2025-09-03T19:43:11.786510Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:97  aws_sdk=AuthCredentialsProvider msg="(id=0x7f0907060ca0) STS_WEB_IDENTITY credentials provider successfully queried credentials\x00"
 level=INFO time=2025-09-03T19:43:11.786524Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: User releasing connection (id=0x7f09276bec00)\x00"
 level=FATAL time=2025-09-03T19:43:11.786536Z thread_id=0x00007f09245f8700 caller=aws_logger.cpp:91  aws_sdk=connection-manager msg="id=0x7f0907159800: Connection released when vended connection count is zero\x00"
 level=INFO time=2025-09-03T19:43:11.786562Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=AuthCredentialsProvider msg="[AWS-DEBUG] id=0x7f0907060ca0: STS_WEB_IDENTITY provider trying to load credentials\x00"
 level=INFO time=2025-09-03T19:43:11.786608Z thread_id=0x00007f0930abd800 caller=aws_logger.cpp:100  aws_sdk=connection-manager msg="[AWS-DEBUG] id=0x7f0907159800: Acquire connection\x00"
 level=ERROR time=2025-09-03T19:43:11.786620Z thread_id=0x00007f09245f8700 caller=logging.cpp:35  msg="*** Aborted at 1756928591 (unix time) try \"date -d @1756928591\" if you are using GNU date ***\n"
 level=ERROR time=2025-09-03T19:43:11.786990Z thread_id=0x00007f09245f8700 caller=logging.cpp:35  msg="PC: @     0x7f0930ae4602 abort\n"
 level=ERROR time=2025-09-03T19:43:11.787002Z thread_id=0x00007f09245f8700 caller=logging.cpp:35  msg="*** SIGSEGV (@0x0) received by PID 1 (TID 0x7f09245f8700) from PID 0; stack trace: ***\n"

Regression Issue

  • Select this option if this issue appears to be a regression.

Expected Behavior

AWS SDK works correctly.

Current Behavior

It crashes.

Reproduction Steps

Latest released AWS SDK seems to have the problem

Possible Solution

No response

Additional Information/Context

No response

AWS CPP SDK version used

1.11.640

Compiler and Version used

GCC 15.2

Operating System and version

Ubuntu 20.04

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugThis issue is a bug.p1This is a high priority issueresponse-requestedWaiting on additional info and feedback. Will move to "closing-soon" in 10 days.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions