Skip to content

Auth API: return 403 if current account isn't authorized to fetch auth info #19742

Closed

Description

@severinbeauvais

Sample call:

image

Expected response: HTTP 403 (unauthorized)

Current response: CORS error

image

Implementing this ticket to use as follows: UI calls to this endpoint will attach a Account-Id header (example above: 668). If the specified entity (example above: BC0871271) is not affiliated to this account, return 403. Otherwise, return data as before.

Activity

  1. added
    Pay
    Entities Team
    on Feb 7, 2024
  2. self-assigned this
    on Feb 8, 2024
  3. seeker25 commented on Feb 8, 2024

    @seeker25
    Contributor

    I think this already works:

    image

  4. seeker25 commented on Feb 8, 2024

    @seeker25
    Contributor

    CORS policy it looks like doesn't allow the header... hmm

  5. seeker25 commented on Feb 8, 2024

    @seeker25
    Contributor

    @severinbeauvais this should be on DEV/TEST

  6. severinbeauvais commented on Feb 8, 2024

    @severinbeauvais
    CollaboratorAuthor

    Yup, seems to work (in Dev!). Take credit for this ticket and go ahead and merge/close it. Thanks!!!

  7. severinbeauvais commented on Feb 8, 2024

    @severinbeauvais
    CollaboratorAuthor

    Does any config need to be done in Prod?

    Update: never mind! I see it's a code change, which will eventually be deployed to Prod.

  8. seeker25 commented on Feb 14, 2024

    @seeker25
    Contributor

    It's in PROD

  9. severinbeauvais commented on Feb 14, 2024

    @severinbeauvais
    CollaboratorAuthor

    Thanks!

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

Metadata

Metadata

Assignees

Labels

Entities TeamPay

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions