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

Add custom attributes support to token generator #1652

Conversation

raphaelcosta
Copy link
Contributor

Summary

Adds support to the custom attributes added by the PR #1602 in the custom access_token_generator. It's now possible to use the custom attributes in the JWT payload for example.

Other Information

Related PR #1602

@guardrails
Copy link

guardrails bot commented Apr 8, 2023

⚠️ We detected 1 security issue in this pull request:

Insecure Use of Language/Framework API (1)
Severity Details Docs
Medium Title: User Controlled Method Invocation
attributes[attribute_name] = send(attribute_name)
📚

More info on how to fix Insecure Use of Language/Framework API in Ruby.


👉 Go to the dashboard for detailed results.

📥 Happy? Share your feedback with us.

@raphaelcosta
Copy link
Contributor Author

@JeremyC-za I would like to have your opinion here since it's based on your PR. Thanks!

Copy link
Member

@nbulaj nbulaj left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@nbulaj
Copy link
Member

nbulaj commented Apr 13, 2023

Could you please also add a changelog entry? And squash the commits then 🙇 Thanks in advance

Use variable to send attribute call

Add specs

Use public_send instead of send

Update changelog
@raphaelcosta raphaelcosta force-pushed the feature/add-custom-attributes-to-token-generator branch from 9ac9b99 to 4e95934 Compare April 13, 2023 17:24
@raphaelcosta
Copy link
Contributor Author

Could you please also add a changelog entry? And squash the commits then 🙇 Thanks in advance

Done, thanks!

@nbulaj nbulaj merged commit 1371bd4 into doorkeeper-gem:main Apr 18, 2023
19 checks passed
@nbulaj
Copy link
Member

nbulaj commented Apr 18, 2023

Thanks @raphaelcosta !

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.

None yet

2 participants