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 rate limiting to the API #723

Closed
ntimo opened this issue Nov 13, 2019 · 2 comments
Closed

Add rate limiting to the API #723

ntimo opened this issue Nov 13, 2019 · 2 comments

Comments

@ntimo
Copy link
Contributor

ntimo commented Nov 13, 2019

Hello,
first off awesome project. I just took a look at the official bitwarden API and saw that it has a rate limit. I would like suggest to add a rate limit too. It should probably use the same headers like the official one:

x-rate-limit-limit: 1m
x-rate-limit-remaining: 199
x-rate-limit-reset: 2019-11-13T22:48:01.3005818Z

What do you think about that? Maybe the limit could also be made configurable using a environment variable.

@ntimo ntimo changed the title Ratelimiting the API Add ratelimiting to the API Nov 14, 2019
@ntimo ntimo changed the title Add ratelimiting to the API Add rate limiting to the API Nov 14, 2019
@ntimo ntimo mentioned this issue Nov 14, 2019
61 tasks
@dani-garcia
Copy link
Owner

So far we've intentionally kept out of this space because it's reasonably easy to do with external tools while it could be quite complex to implement correctly and at the same time it would require a lot of configurability because no one wants the exact same setup. For example, someone might prefer to only ratelimit the login endpoint, or apply different limits to loggedin users vs anonymous users, someone might want to ban the users after the limit is reached, others might want to block them for a certain time, someone could want more restrictive limits for some IP range or more relaxed for the local LAN...

Personally I wouldn't mind some basic ratelimiting being built in, but a more robust solution would be to create documentation on how to integrate bitwarden_rs with the rate limiting of third party proxies or firewalls.

@BlackDex
Copy link
Collaborator

BlackDex commented Oct 8, 2020

To keep the issue tracker more focused, I'm closing this issue in favor of the meta issue at #246

@BlackDex BlackDex closed this as completed Oct 8, 2020
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

No branches or pull requests

3 participants