summaryrefslogtreecommitdiff
path: root/puppet/modules/site_shorewall
diff options
context:
space:
mode:
authorirregulator <irregulator@riseup.net>2014-05-21 20:42:46 +0300
committerelijah <elijah@riseup.net>2014-07-01 16:05:40 -0700
commit156c2e1194c65d2f7813b946ac8baa90ffdf1f39 (patch)
tree4bf94e10e1d0f2aeba5c915cacb8034f40b36349 /puppet/modules/site_shorewall
parent54fcafe131c411a49e4277cd0d14c6ea20044203 (diff)
Make shorewall accept incoming traffic for obfsproxy server
Diffstat (limited to 'puppet/modules/site_shorewall')
-rw-r--r--puppet/modules/site_shorewall/manifests/obfsproxy.pp24
1 files changed, 24 insertions, 0 deletions
diff --git a/puppet/modules/site_shorewall/manifests/obfsproxy.pp b/puppet/modules/site_shorewall/manifests/obfsproxy.pp
new file mode 100644
index 00000000..68fb9b9f
--- /dev/null
+++ b/puppet/modules/site_shorewall/manifests/obfsproxy.pp
@@ -0,0 +1,24 @@
+class site_shorewall::obfsproxy {
+
+ include site_shorewall::defaults
+
+ $obfsproxy = hiera('obfsproxy')
+ $scramblesuit = $obfsproxy['scramblesuit']
+ $scram_port = $scramblesuit['port']
+
+ # define macro for incoming services
+ file { '/etc/shorewall/macro.leap_obfsproxy':
+ content => "PARAM - - tcp $scram_port ",
+ notify => Service['shorewall'],
+ require => Package['shorewall']
+ }
+
+ shorewall::rule {
+ 'net2fw-obfs':
+ source => 'net',
+ destination => '$FW',
+ action => 'leap_obfsproxy(ACCEPT)',
+ order => 200;
+ }
+
+}