Rilo Ravestein
Guru
- Joined
- Mar 6, 2014
- Messages
- 686
Hi folks,
I would like to write the following script (coming from this thread):
Just before my firewall is started (automatically) in the jail, i want to fetch the ip address(es) ot my tun0 (OpenVPN) connection/tunnel and add those ip addresses to the firewall rules (replacing the old ones preferably) and then start the firewall. I think this could be an easy script, but i'm not yet really familiar with scripting. Maybe someone can give me some help, point me in the right direction?
Thanks!
EDIT: I think i got the big part, using these examples.
Example 1
Example 2 (old)
The only thing now is to fetch the IP addresses and use them to add to the rules
I would like to write the following script (coming from this thread):
Just before my firewall is started (automatically) in the jail, i want to fetch the ip address(es) ot my tun0 (OpenVPN) connection/tunnel and add those ip addresses to the firewall rules (replacing the old ones preferably) and then start the firewall. I think this could be an easy script, but i'm not yet really familiar with scripting. Maybe someone can give me some help, point me in the right direction?
Thanks!
EDIT: I think i got the big part, using these examples.
Example 1
Example 2 (old)
The only thing now is to fetch the IP addresses and use them to add to the rules
Last edited: