Skip to content

Missing 'Authorization' or 'Cookie' header in JWT authentication mode with Cookie Enabled #9820

@Joan-George

Description

@Joan-George

Version Information

Server Version:
CLI Version (for CLI related issue): hasura/graphql-engine:v2.29.1

Environment

Hasura Docker

What is the current behaviour?

When I enable the Hasura JWT Authentication with header type cookie It's working fine when hit through my application endpoint. But, when I try to add the Cookie in the Hasura console it's not considering the Cookie which I added in the Hasura console header. and throws the error Missing 'Authorization' or 'Cookie' header in JWT authentication mode.

What is the expected behaviour?

Cookies also should be included when making a request from the Hasura console when I add it to the header.

How to reproduce the issue?

  1. In the Hasura docker-compose enable JWT mode with following environment variable.
    HASURA_GRAPHQL_JWT_SECRET: '{"type":"RS256","jwk_url":"https://cognito-idp.${REGION}.amazonaws.com/${COGNITO_ID}/.well-known/jwks.json","claims_format":"stringified_json","header":{"type":"Cookie","name":"token"}}'

Screenshots or Screencast

Hasura-console

no-cookie-request-header

Please provide any traces or logs that could help here.

Any possible solutions/workarounds you're aware of?

As of now, I don't have any workaround for this.

Keywords

Hasura Header, Cookie, JWT token

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions