file upload failing in v1.14.0 using x509 authentication
Opened this issue · 1 comments
I have updated azure sdk from 1.11.0 to 1.14.0 and now file uploads are failing, telemetry data is successfully getting sent.
I am using DPS service, x509 certificated-based authentication for iot hub connection.
I am still using IoTHubDeviceClient_LL_UploadToBlob Api to upload data to blob as stated in below sample link which is working fine with older sdk too.
https://github.com/Azure/azure-iot-sdk-c/blob/main/iothub_client/samples/iothub_client_sample_upload_to_blob/iothub_client_sample_upload_to_blob.c
Here is Firmware error logs:
Error: Time:<NO TIME IMPL> File:./azure-iot-sdk-c/iothub_client/src/iothub_client_ll_uploadtoblob.c Func:send_http_request Line:161 HTTP failed response code was 400
Error: Time:<NO TIME IMPL> File:./azure-iot-sdk-c/iothub_client/src/iothub_client_ll_uploadtoblob.c Func:IoTHubClient_LL_UploadToBlob_NotifyIoTHubOfUploadCompletion Line:669 unable to execute send_http_request
Error: Time:<NO TIME IMPL> File:./azure-iot-sdk-c/iothub_client/src/iothub_client_ll_uploadtoblob.c Func:IoTHubClient_LL_UploadToBlob_NotifyCompletion Line:1098 IoTHubClient_LL_UploadToBlob_NotifyIoTHubOfUploadCompletion failed
Error: Time:<NO TIME IMPL> File:./azure-iot-sdk-c/iothub_client/src/iothub_client_core_ll.c Func:IoTHubClientCore_LL_UploadToBlob Line:2766 Failed completing upload to blob.
Iot Hub Error Log:
{"statusCode":"400","errorMessage":"Storage endpoint or blob name is invalid","deviceId":"7C:87:CE:EB:82:62","trackingId":"991D7E091C444B4091C0D555B612E911-G2:-TimeStamp:2024-09-06T10:34:48.670879080Z","fileUploadCorrelationId":"MjAyNDA5MDYxMTQ0XzdkNTkzYTNmLTQ1YWMtNDQ0OC04NzUyLTcyZWRiNzU5NjRmMV83Yzg3Y2VlYjgyNjJfZGV2aWNlQmFzZUluZm9fNDEyXzIwMjQwOTA2LTEyMzQzMy5keGRpX3ZlcjIuMA==","fileUploadStatusDescription":"","fileUploadStatusCode":"400000","maskedIpAddress":"106.76.204.XXX","isSuccess":"false","fileUploadFilename":"7c87ceeb8262_deviceBaseInfo_412_20240906-123433.dxdi"}
I am using esp32 board with esp-idf v.5.2.
I tried same certificates in windows Linux subsystem there also file upload fails
did you checked on version 1.13.0
some what similar issue i am facing in sdk 1.13.0
2024-11-11T13:26:45.7868581Z Mon Nov 11 13:25:30 2024 ERROR [dk-c\c-utility\adapters\socketio_win32.c:700 ] Socketio_Failure: Receiving data from endpoint: 10054.
2024-11-11T13:26:45.7869856Z Mon Nov 11 13:25:30 2024 ERROR [k-c\c-utility\adapters\httpapi_compact.c:476 ] Error signalled by underlying IO
2024-11-11T13:26:45.7870926Z Mon Nov 11 13:25:30 2024 ERROR [dk-c\c-utility\adapters\socketio_win32.c:700 ] Socketio_Failure: Receiving data from endpoint: 10054.
2024-11-11T13:26:45.7872006Z Mon Nov 11 13:25:30 2024 ERROR [k-c\c-utility\adapters\httpapi_compact.c:566 ] xio reported error on dowork
2024-11-11T13:26:45.7873048Z Mon Nov 11 13:25:30 2024 ERROR [k-c\c-utility\adapters\httpapi_compact.c:1276] Receive header from HTTP failed (result = HTTPAPI_READ_DATA_FAILED (10))
2024-11-11T13:26:45.7874156Z Mon Nov 11 13:25:30 2024 ERROR [zure-iot-sdk-c\c-utility\src\httpapiex.c:551 ] unable to recover sending to a working state
2024-11-11T13:26:45.7875164Z Mon Nov 11 13:25:30 2024 ERROR [ient\src\iothub_client_ll_uploadtoblob.c:156 ] unable to HTTPAPIEX_ExecuteRequest
2024-11-11T13:26:45.7876311Z Mon Nov 11 13:25:30 2024 ERROR [ient\src\iothub_client_ll_uploadtoblob.c:546 ] unable to HTTPAPIEX_ExecuteRequest
2024-11-11T13:26:45.7877342Z Mon Nov 11 13:25:30 2024 ERROR [ient\src\iothub_client_ll_uploadtoblob.c:915 ] error in IoTHubClient_LL_UploadToBlob_GetBlobCredentialsFromIoTHub
2024-11-11T13:26:45.7878421Z Mon Nov 11 13:25:30 2024 ERROR [othub_client\src\iothub_client_core_ll.c:2728] Failed initializing upload in IoT Hub