Hi! I'm working with http4-connect (which is reall...
# http4k
t
Hi! I'm working with http4-connect (which is really great btw) and I'm facing an issue. In our organization, there is an on-premise S3 installation on an internal domain. I noticed that http4k-aws and http4k-connect have
<http://amazonaws.com|amazonaws.com>
domain hardcoded. When I change the domain with
ClientFilters.SetHostFrom
, the signature process seems to fail: I get an AccessDenied response, even if the request is correct. By trying the same request with Postman and its included AWS Signature feature, I got a different
SignedHeaders
: • Postman:
SignedHeaders=host;x-amz-content-sha256;x-amz-date,
• Http4k-connect:
SignedHeaders=host;x-amz-date,
So I think there are those two possibilities, either the signature is wrong due to a late host change, or the signature needs to sign
x-amz-content-sha256
too. Either way, it would be nice to be able to set the base domain.
d
aha - that's going to be an interesting one - I literally didn't even know you could get custom S3 installs! For the moment, could you simply write a custom the S3 adapter to suit your situation using the same actions? It's only a few lines of code. and you will be able to use all the same actions as we do in the original
can you raise an issue to remind me to look at it in the meantime?
the problem is that the host change is too late, so the original host is the one used in the signed headers
the content hash is unaffected
t
Alright, I'm going to raise an issue about it. Thank you for your swift response 🙂 I'll try to make it work as you say