dkan
dkan copied to clipboard
Spike: API calls to public endpoints fails with Authorization header
Describe the bug
Calling a public DKAN endpoint with the Authorization header returns 403 Forbidden. It does not matter if the Authorization is correct or not.
Steps To Reproduce
- Have a target site with DKAN installed.
- Call a public endpoint (for example /api/1/metastore/schemas/dataset)
$ curl --location --request GET "$(dktl url)/api/1/metastore/schemas/dataset" \
--header 'Accept: application/json' \
--header 'Authorization: Basic c3VzYW5hLnNpbWFuOnN1c2FuYS5zaW1hbg=='
Expected behavior
Calling public APIs should not fail when any form of authorization is used.