Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added Telekom Security Requirement numbers to the corresponding kitchen test #12

Merged
merged 3 commits into from
Jun 16, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions default/serverspec/sysctl_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,27 @@

describe 'IP V4 networking' do

# GIS: Req 3.21-1
context linux_kernel_parameter('net.ipv4.ip_forward') do
its(:value) { should eq 0 }
end

# GIS: Req 3.21-1
context linux_kernel_parameter('net.ipv4.conf.all.forwarding') do
its(:value) { should eq 0 }
end

# GIS: Req 3.21-3
context linux_kernel_parameter('net.ipv4.conf.all.rp_filter') do
its(:value) { should eq 1 }
end

# GIS: Req 3.21-3 ; GIS: Req 3.37-10
context linux_kernel_parameter('net.ipv4.conf.default.rp_filter') do
its(:value) { should eq 1 }
end

# GIS: Req 3.21-1
context linux_kernel_parameter('net.ipv4.icmp_echo_ignore_broadcasts') do
its(:value) { should eq 1 }
end
Expand All @@ -30,6 +35,7 @@
its(:value) { should eq 1 }
end

# GIS: Req 3.01-9
context linux_kernel_parameter('net.ipv4.icmp_ratelimit') do
its(:value) { should eq 100 }
end
Expand All @@ -42,10 +48,12 @@
its(:value) { should eq 0 }
end

# GIS: Req 3.21-3
context linux_kernel_parameter('net.ipv4.conf.all.arp_ignore') do
its(:value) { should eq 1 }
end

# GIS: Req 3.21-3
context linux_kernel_parameter('net.ipv4.conf.all.arp_announce') do
its(:value) { should eq 2 }
end
Expand All @@ -66,10 +74,12 @@
its(:value) { should eq 1 }
end

# GIS: Req 3.37-12
context linux_kernel_parameter('net.ipv4.conf.all.accept_source_route') do
its(:value) { should eq 0 }
end

# GIS: Req 3.37-12
context linux_kernel_parameter('net.ipv4.conf.default.accept_source_route') do
its(:value) { should eq 0 }
end
Expand Down Expand Up @@ -111,6 +121,7 @@
its(:value) { should eq 1 }
end

# GIS: Req 3.21-1
context linux_kernel_parameter('net.ipv6.conf.all.forwarding') do
its(:value) { should eq 0 }
end
Expand Down Expand Up @@ -173,6 +184,8 @@
end

describe 'ExecShield' do

# GIS: Req 3.21-5
if command('cat /proc/cpuinfo').return_stdout?(/^flags.*?:.*? nx( .*?)?$/)
context linux_kernel_parameter('kernel.exec-shield') do
its(:value) { should eq 1 }
Expand All @@ -185,6 +198,7 @@
end
end

# GIS: Req 3.21-5
context linux_kernel_parameter('kernel.randomize_va_space') do
its(:value) { should eq 2 }
end
Expand Down