move keyinfo to all hosts, as we want it for various other lookups
[mirror/dsa-puppet.git] / modules / ssh / manifests / init.pp
index 59fe97b..e2248f8 100644 (file)
@@ -13,6 +13,12 @@ class ssh {
                require => Package["openssh-server"],
                 notify  => Exec["ssh restart"]
                 ;
+              "/etc/ssh/userkeys":
+               ensure  => directory,
+               owner   => root,
+               group   => root,
+               mode    => 755,
+                ;
               "/etc/ssh/userkeys/root":
                 content => template("ssh/authorized_keys.erb"),
                 mode    => 444,
@@ -24,4 +30,14 @@ class ssh {
             path        => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
             refreshonly => true,
         }
+
+        @ferm::rule { "dsa-ssh":
+                description     => "Allow SSH from DSA",
+                rule            => "proto tcp mod state state (NEW) dport (ssh) @subchain 'ssh' { saddr (\$SSH_SOURCES) ACCEPT; }"
+        }
+        @ferm::rule { "dsa-ssh-v6":
+                description     => "Allow SSH from DSA",
+                domain          => "ip6",
+                rule            => "proto tcp mod state state (NEW) dport (ssh) @subchain 'ssh' { saddr (\$SSH_V6_SOURCES) ACCEPT; }"
+        }
 }