Opensearch Dashboard JWT Authentication CORS

I was wondering if it is possible to do a JWT authentication into the dashboard from different origins. I have set up the CORS configuration for my cluster and got a response, as well as sign into the dashboard with a JWT while I am at the dashboard’s login page.

However, if I try to run the same HTTP request with the JWT in the authorization header from a different origin, then I get the CORS error. I can see a server.cors and server.cors.origins config variable in this file https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/bin/opensearch-dashboards-docker though it does not seem to do anything.