minio/minio-dotnet

Public play minio server accessKey not working

sabiland opened this issue · 5 comments

I get this exception message when trying to connect to play.min.io with public accessKey Q3AM3UQ867trueSPQQA43P2F Minio.Exceptions.AuthorizationException: 'The Access Key Id you provided does not exist in our records.'

this are the play credentials

play            
  URL       : https://play.min.io
  AccessKey : Q3AM3UQ867SPQQA43P2F
  SecretKey : zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG
  API       : S3v4
  Path      : auto

Those credentials are working fine

mc admin info play
●  play.min.io
 Uptime: 11 hours 
 Version: 2023-11-09T17:33:32Z
 Network: 1/1 OK 
 Drives: 4/4 OK 
 Pool: 1

Pools:
 1st, Erasure sets: 1, Drives per erasure set: 4

1.9 GiB Used, 318 Buckets, 8,058 Objects, 239 Versions, 9 Delete Markers
4 drives online, 0 drives offline

Might be somenthing in you implementation with dotnet

I did it per/documentation for testing:

string minioEndpoint = Configuration[$"MasterSettings:minioEndpoint"];
string minioAccessKey = Configuration[$"MasterSettings:minioAccessKey"];
string minioSecretKey = Configuration[$"MasterSettings:minioSecretKey"];
services.AddMinio(configureClient => configureClient
    .WithEndpoint(minioEndpoint)
    .WithCredentials(minioAccessKey, minioSecretKey));

I store IMinioClient to global variable and when calling var list = await Globals.GlobalMinioClient.ListBucketsAsync(); I get exception about accessKey.

My settings:

"minioEndpoint": "play.min.io",
"minioAccessKey": "Q3AM3UQ867trueSPQQA43P2F",
"minioSecretKey": "zuf+tfteSlswRu7BJ86wtrueekitnifILbZam1KYY3TG",

That's a typo, let me fix it.

Ok, now it is working with these settings:

"minioEndpoint": "play.min.io",
"minioAccessKey": "Q3AM3UQ867SPQQA43P2F",
"minioSecretKey": "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG",

Can I at the same time ask why in sample code there is always await ConfigureAwait(false) ? Is this mandatory with every call to minio server?