Skip to content
This repository was archived by the owner on Nov 8, 2021. It is now read-only.
This repository was archived by the owner on Nov 8, 2021. It is now read-only.

Authentication issue: The provided credentials are invalid or the user does not exist #437

Description

@lacklock

Goals

using correct ACCESS_TOKEN.TOKEN to query data

Expected Results

Success

Actual Results

Access token request

POST /auth HTTP/1.1
Content-Type: application/json; charset=utf-8
Cookie: INGRESSCOOKIE=a286c04f69f21a6977d4c309021183b3
Host: mobile-log.us1a.cloud.realm.io
Connection: close
User-Agent: Paw/3.1.9 (Macintosh; OS X/10.15.3) GCDHTTPRequest
Content-Length: 765

{"app_id":"io.realm.Auth","provider":"realm","data":RefreshToken ,"path":"/default"}

image

Schema request

https://mobile-log.us1a.cloud.realm.io/graphql/schema/default

GET /graphql/schema/default HTTP/1.1
Authorization:  Token
Cookie: INGRESSCOOKIE=a286c04f69f21a6977d4c309021183b3
Host: mobile-log.us1a.cloud.realm.io
Connection: close
User-Agent: Paw/3.1.9 (Macintosh; OS X/10.15.3) GCDHTTPRequest

Response

HTTP/1.1 401 Unauthorized
Date: Tue, 17 Mar 2020 09:08:57 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 250
Connection: close
Access-Control-Allow-Origin: *
ETag: W/"fa-epKhMUPW/YtdPagazS+IuqIjNmc"
Access-Control-Allow-Credentials: true
Access-Control-Allow-Methods: GET,HEAD,PUT,PATCH,POST,DELETE
Access-Control-Allow-Headers: DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Authorization

{"type":"https://docs.realm.io/server/troubleshoot/errors#invalid-credentials",
"title":"The provided credentials are invalid or the user does not exist.",
"status":401,"
detail":"The access token doesn't grant access to the requested path.","code":611}

Steps to Reproduce

I want to using graphQL execute query. I have a admin account user. I want to query from the default realm, path is /default .

Post body is:
{
"app_id":"",
"provider":"realm",
"data":"REFRESH_TOKEN.TOKEN",
"path":"/default"
}

But when using the response token put in the Authorization header send request, it will response 401:

{"type":"https://docs.realm.io/server/troubleshoot/errors#invalid-credentials","title":"The provided credentials are invalid or the user does not exist.","status":401,"detail":"The access token doesn't grant access to the requested path.","code":611}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions