Method: WebShield::IPShield#initialize
- Defined in:
- lib/web_shield/ip_shield.rb
#initialize(id, shield_path, options, config) ⇒ IPShield
Params:
path:
options:
whitelist: options, defualt [], like 172.10.10.10 172.10.10.10/16
blacklist: options, default [], like 172.10.10.10 172.10.10.10/16
13 14 15 16 17 18 19 20 |
# File 'lib/web_shield/ip_shield.rb', line 13 def initialize(id, shield_path, , config) super (@options) @options[:dictatorial] = true push_to_whitelist([:whitelist]) if [:whitelist] push_to_blacklist([:blacklist]) if [:blacklist] end |