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

Auditing logs is needed. #22

Open
npavlyk82 opened this issue Feb 7, 2025 · 0 comments · May be fixed by #23
Open

Auditing logs is needed. #22

npavlyk82 opened this issue Feb 7, 2025 · 0 comments · May be fixed by #23

Comments

@npavlyk82
Copy link

npavlyk82 commented Feb 7, 2025

We need to audit logs of downloads.

The solution is to use an existing store of tokens but extended with extra properties and with a soft-deleting feature.

The following changes should be done for HotChocolate and MongoDB packages:

  • Add an ExtraProperties field to the Token model
  • Add an IsDeleted field to the Token model
  • Implement soft-deleting logic instead of hard removing records from storage
  • Create a TTL index on the ExpirationDate field to hard remove records after 365*2 days by default (it is configurable)
  • Add the ability to Add/read extra properties using HotChocolate ScopedContextData

None of these changes should impact the current logic of generating/validating tokens.

@npavlyk82 npavlyk82 linked a pull request Feb 7, 2025 that will close this issue
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 a pull request may close this issue.

1 participant