aboutsummaryrefslogtreecommitdiff
path: root/manifests/subsystems/firewall/openvpn.pp
blob: f5e8c9432fe849b9795e0f4d4c7e430c232b0198 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
class firewall::openvpn {
  shorewall::zone { 'vpn':
    type  => 'ipv4',
    order => '4',
  }

  shorewall::interface { 'tun0':
    zone => 'vpn',
  }

  shorewall::policy { 'loc-vpn':
    sourcezone      => 'loc',
    destinationzone => 'vpn', 
    policy          => 'ACCEPT',
    order           => '20',
  }

  shorewall::policy { 'vpn-loc':
    sourcezone      => 'vpn',
    destinationzone => 'loc', 
    policy          => 'ACCEPT',
    order           => '21',
  }

  shorewall::policy { 'fw-vpn':
    sourcezone      => '$FW',
    destinationzone => 'vpn', 
    policy          => 'ACCEPT',
    order           => '22',
  }

  shorewall::tunnel { 'openvpn':
    tunnel_type => 'openvpnclient',
    zone        => 'net',
  }
}