Skip to content

ip filters #17

Closed
Closed

Description

@etr

Enable global/resource ip blacklists

Activity

  1. ghost assigned on Mar 28, 2012
  2. etr commented on Apr 8, 2012

    @etr
    OwnerAuthor

    Definitively added support to global ip blacklist.

    A default policy can be imposed on the created webserver; it can be ACCEPT or REJECT. If the policy is ACCEPT, all IP are accepted per default, otherwise they are rejected per default.

    In order to ban an IP, the method banIp can be used. It is possible to pass a string to the method that represents an ip (in IPv4 or IPv6 formats). It is also possible to pass strings like "231..." or "221.10.." or "215..12.1". In these case, wildcards allow to ban all ips corresponding.
    The method allowIp works in the same way.

    Have been inserted also two methods to remove bans and allowances.

    A request coming from an IP is rejected in two cases:

    • default policy is ACCEPT and IP has been banned and IP has not been allowed (this way is possible to define a ban for all ip correponding to 231...* but to allow 231.10.21.1)
    • default policy is REJECT and IP has not been allowed or, if the ip has been been allowed it has not been also banned.

    A rejected request is not served at all and no response is returned to the requestor.

    There is not a blacklist model at resource level because such a system may collide with the global one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions