-
Notifications
You must be signed in to change notification settings - Fork 99
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
Blocklist Filter #158
Comments
Since blocklists are such an essential part of proxies, I think it would be worth thinking of the blocklist not as a filter, but as a feature as part of a filter chain, so you'd set the list on that level, and then with #63 filters would be able to add and remove from the blocklist as part of their response.
We'll need to be able to block both, as you can use the port for UDP reflection amplification attacks. |
With #63 - I would suggest, let's take a user journey (this one seems like a good example), and flesh it out to see what we think we would like it to look like. I have some thoughts that think we can keep this quite simple, at least for first pass, but I won't dilute this ticket with those ideas for now. I don't think we need to have a new special construct for blocklist management, it can work as a Filter, it just depends where it should be in the Filterchain ordering, but also keeps the cognitive overhead for users down -- but doing a user journey discussion on #63 will likely also find where the edge cases are. |
I was thinking about this the other day, and wanted to get people's feedback:
I've called this version: v1alpha1
static:
filters:
- name: quilkin.extensions.filters.debug.v1alpha1.Firewall
config:
- direction: Read # ("Read": respond to on_read or "Write" for on_write filter events)
action: Allow # (action on address/port match. "Allow" would allow traffic through, "Deny" would drop the packets)
source: "192.168.51.0/24" # (ip4 or ipv6 Cidr)
ports: # (which ports to match on)
- 10 # (could be a single port, or a range with a `-` in the middle)
- 1000-7000
endpoints:
- address: 127.0.0.1:7001 WDYT? Some thoughts / questions I'm still thinking about, and would love feedback if you like the general idea:
Thoughts? |
This makes sense merging both allow and deny into a Firewall filter!
Leaving them as required sounds reasonable. Also since the user specifies a list of rules, mistakenly having multiple rules in the list with default values might be a footgun otherwise.
We can split the read/write rules into their own sections (like we do for e.g compress) since those rules won't relate to each other (e.g they can't conflict), so that we avoid specifying a config:
on_read:
- action: Allow
source: 0.0.0.0
ports: [1,2,3]
on_write:
- action: Allow
source: 0.0.0.1
ports: [1,2,3] |
Yeees! Thanks for that. We should definitely stick to the already established nomenclature of version: v1alpha1
static:
filters:
- name: quilkin.extensions.filters.debug.v1alpha1.Firewall
config:
on_read:
- action: ALLOW # (action on address/port match. "Allow" would allow traffic through, "Deny" would drop the packets)
source: "192.168.51.0/24" # (ip4 or ipv6 Cidr)
ports: # (which ports to match on)
- 10 # (could be a single port, or a range with a `-` in the middle)
- 1000-7000
on_write:
- action: DENY
source: "192.168.51.0/24" # (ip4 or ipv6 Cidr)
ports: # (which ports to match on)
- 7000
endpoints:
- address: 127.0.0.1:7001 (Those values aren't that realistic 😄 but this is a 👍🏻 for me!) |
Gonna start working on this. Let me know if anyone has any objections to the design above (can always tweak it as needed anyway). |
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
Code implementation of a Firewall filter that will allow/deny packets based on their from address on both read and write. Documentation to come next to finish off the below two tickets. Work on googleforgames#158 Work on googleforgames#343
While writing the docs, I found a typo in the name of the Filter, so included that as well. Closes googleforgames#158 Closes googleforgames#343
While writing the docs, I found a typo in the name of the Filter, so included that as well. Closes googleforgames#158 Closes googleforgames#343
Thinking about Server side DDOS mitigation, or just general abuse mitigation - being able to block specific addresses from sending traffic through to any gameserver should be useful.
Something like:
Question: Not sure if we need to block IP and port, or just IP?
The text was updated successfully, but these errors were encountered: