aloneguid / stowage

Bloat-free, no BS cloud storage SDK.
Apache License 2.0
168 stars 14 forks source link

S3 signature is not calculated correctly #15

Closed zitmen closed 1 year ago

zitmen commented 1 year ago

Hi,

I am testing with S3 compatible storage (Minio) and I am experiencing issues where I am getting 403 Forbidden during authentication. Error code is SignatureDoesNotMatch. I have found 2 causes:

  1. if endpoint contains port other than 80 or 443, the port must be included in the host header
  2. if the path ends with a path separator it must not be url encoded (I verified this issue also with AWS S3)

Best, Martin

zitmen commented 1 year ago

Actually it has not been fixed correctly as I still can't connect to my local minio instance due to incorrect signature

aloneguid commented 1 year ago

How are you connecting? I've added a factory method for Minio for convenience, it works on my local network with custom port.

zitmen commented 1 year ago

I did use the new factory. I am going to investigate tomorrow and if I find the root cause, I will share.

zitmen commented 1 year ago

My appologies, I executed my integration tests with incorrect configuration yesterday. Everything seems to work well now, so I am closing the issue.