You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add temporary credentials support for put object? #41
Seems like it can't make use of session token params when we put object, minio always return “The AWS Access Key Id you provided does not exist in our records” error.
An Observatory debugger and profiler on Chrome is available at: http://127.0.0.1:64707/tsZWaTtM9yk=
REQUEST: GET https://s3-ap-northeast-1.amazonaws.com/
host: s3-ap-northeast-1.amazonaws.com
user-agent: MinIO (Unknown; Unknown) minio-dart/2.0.0
x-amz-date: 20230505T133214Z
x-amz-content-sha256: UNSIGNED-PAYLOAD
authorization: AWS4-HMAC-SHA256 Credential=......./20230505/ap-northeast-1/s3/aws4_request, SignedHeaders=host;x-amz-content-sha256;x-amz-date, Signature=.............
RESPONSE: 403 Forbidden
content-type: application/xml
date: Fri, 05 May 2023 13:32:13 GMT
server: AmazonS3
transfer-encoding: chunked
x-amz-id-2: ..................
x-amz-request-id: ................
Error: MinioError: The AWS Access Key Id you provided does not exist in our records.
as you said, enabletrace option shows the request headers, however I can't find X-Amz-Security-Token.
Env
Windows 10
Flutter 3.7.12
Dart 2.19.6
web browser client, windows standalond client
Is there any missing code? I'm really new to flutter and dart, so could you please give me some help?
@zawazawagh Hey! I think this package has a bug when it does not really send sessionToken. This error (The AWS Access Key Id you provided does not exist in our records) is certainly related to missed token - I reproduced it with Postman. I had a problem with PutObject API, but I think it could be the same with listBuckets. You can find a recent PR for a similar discussion there: #62
You can add it to pubspec.yaml this way:
But it did not work in my case: getting temp credentials from inside the AWS ECS Fargate task and put object to AWS S3 bucket, so I created this fork that I'm testing on my side right now, You can try it this way:
This one is stale — the x-amz-security-token header was added upstream in
commit 28a2e2f (2022-05-10), after this issue was opened, and it is signed
as part of the request. You can see it in the trace with enableTrace: true:
x-amz-security-token: your-session-token
The fork keeps that behaviour and adds the credentials provider callback on
top (see #94), so temporary credentials can also be renewed.
Activity
Boris-Plato commentedon May 3, 2023
More info: setting enableTrace=true I do not see X-Amz-Security-Token header in the trace.
zawazawagh commentedon May 5, 2023
Hi, @Boris-Plato I'm running this simple code, but I'm having
The AWS Access Key Id you provided does not exist in our records.error.and the console goes like this.
as you said, enabletrace option shows the request headers, however I can't find
X-Amz-Security-Token.Env
Is there any missing code? I'm really new to flutter and dart, so could you please give me some help?
Boris-Plato commentedon May 5, 2023
@zawazawagh Hey! I think this package has a bug when it does not really send sessionToken. This error (The AWS Access Key Id you provided does not exist in our records) is certainly related to missed token - I reproduced it with Postman. I had a problem with PutObject API, but I think it could be the same with listBuckets. You can find a recent PR for a similar discussion there:
#62
You can add it to pubspec.yaml this way:
But it did not work in my case: getting temp credentials from inside the AWS ECS Fargate task and put object to AWS S3 bucket, so I created this fork that I'm testing on my side right now, You can try it this way:
You can also create your own PR/fork
zawazawagh commentedon May 5, 2023
@Boris-Plato Thank you for your information.
Your forked repo solved my problem! You saved my day.
arrrrny commentedon Oct 22, 2026
This one is stale — the
x-amz-security-tokenheader was added upstream incommit
28a2e2f(2022-05-10), after this issue was opened, and it is signedas part of the request. You can see it in the trace with
enableTrace: true:The fork keeps that behaviour and adds the credentials provider callback on
top (see #94), so temporary credentials can also be renewed.
arrrrny commentedon Oct 22, 2026
This ships in zuraffa_minio — the maintained fork of this package, which upstream has not touched since August 2025.
The fork keeps the API of the original package unchanged, so moving over is an import swap:
Source, the changelog and the sweep of the open issues of this tracker: https://github.com/arrrrny/zuraffa_minio