Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 1058 | Gateway: allow nested fields verification #1059

Merged
merged 2 commits into from
Oct 31, 2023

Conversation

IceKhan13
Copy link
Member

@IceKhan13 IceKhan13 commented Oct 30, 2023

Summary

Allow nested fields verification from auth API

Details and comments

Now if verification API has structure something like that

{
  "is_valid": true,
  "some": {
    "nested": {
      "field": true
    },
    "other": "bla"
  }
}

We can verify agains it with following settings:

"SETTINGS_TOKEN_AUTH_VERIFICATION_FIELD", "is_valid;some,nested,field"

Back compatible PR

Closes #1058

@IceKhan13 IceKhan13 added this to the 0.7 milestone Oct 30, 2023
@IceKhan13 IceKhan13 marked this pull request as ready for review October 30, 2023 15:02
@psschwei
Copy link
Collaborator

How would we include other in the

"SETTINGS_TOKEN_AUTH_VERIFICATION_FIELD", "is_valid;some,nested,field"

block?

@IceKhan13
Copy link
Member Author

IceKhan13 commented Oct 30, 2023

If we need to check for other too

"SETTINGS_TOKEN_AUTH_VERIFICATION_FIELD", "is_valid;some,nested,field;some,other"

Copy link
Collaborator

@akihikokuroda akihikokuroda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

gateway/main/settings.py Outdated Show resolved Hide resolved
@psschwei psschwei mentioned this pull request Oct 30, 2023
@IceKhan13 IceKhan13 merged commit c750dbe into main Oct 31, 2023
5 checks passed
@IceKhan13 IceKhan13 deleted the issue-1058/gateway-update-auth branch October 31, 2023 13:26
caleb-johnson pushed a commit to caleb-johnson/quantum-serverless that referenced this pull request Nov 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Custom auth: allow multiple fields for verification
3 participants