• Home
  • Categories
  • Recent
  • Popular
  • Pricing
  • Contact us
  • Docs
  • Login
FusionAuth
  • Home
  • Categories
  • Recent
  • Popular
  • Pricing
  • Contact us
  • Docs
  • Login
  1. Home
  2. pawel.prochal
P
  • Profile
  • Following 0
  • Followers 0
  • Topics 1
  • Posts 1
  • Best 1
  • Controversial 0
  • Groups 0

pawel.prochal

@pawel.prochal

1
Reputation
1
Profile views
1
Posts
0
Followers
0
Following
Joined 15 Jun 2023, 18:16 Last Online 4 Jul 2023, 20:40

pawel.prochal Unfollow Follow

Best posts made by pawel.prochal

  • Accessing FusionAuth API using bearer token auth

    I have created a front end for users management in fusionAuth to which the users log using fusionAuth username/password. We authorize the requests sent to the user management endpoints e.g. api/user/search by providing an ApiKey defined in FusionAuth -> Settings -> Api Keys, which is granted access to these endpoints.

    I want to limit the access only to certain users and authorize such requests by using logged user bearer token, however I get 401 Unauthorized response. The token is valid and both e.g. /api/jwt/validate and /api/user/ return 200 with user's data, so clearly I'm missing some access roles.

    Question: is it possible to authorize user assigned to application via custom tenant (not FusionAuth) using Bearer JWT Token to access api/user/search API? One way would be to assign a custom Role both to the Application and User, validate the token for those roles in the backend and then swap the authentication method from Bearer Token to a Api Key kept on the server along the corresponding tenant-id, but I hope there's an out of the box solution to handle it.

    posted in Q&A
    P
    pawel.prochal
    15 Jun 2023, 18:35

Latest posts made by pawel.prochal

  • Accessing FusionAuth API using bearer token auth

    I have created a front end for users management in fusionAuth to which the users log using fusionAuth username/password. We authorize the requests sent to the user management endpoints e.g. api/user/search by providing an ApiKey defined in FusionAuth -> Settings -> Api Keys, which is granted access to these endpoints.

    I want to limit the access only to certain users and authorize such requests by using logged user bearer token, however I get 401 Unauthorized response. The token is valid and both e.g. /api/jwt/validate and /api/user/ return 200 with user's data, so clearly I'm missing some access roles.

    Question: is it possible to authorize user assigned to application via custom tenant (not FusionAuth) using Bearer JWT Token to access api/user/search API? One way would be to assign a custom Role both to the Application and User, validate the token for those roles in the backend and then swap the authentication method from Bearer Token to a Api Key kept on the server along the corresponding tenant-id, but I hope there's an out of the box solution to handle it.

    posted in Q&A
    P
    pawel.prochal
    15 Jun 2023, 18:35