Easier to read with cream paper, a tint, more contrast or larger text? Choose your colours and text, once, for every page.

Preview

SESP CS, DINC task 2: Block a weakness and prove it

This is the first page of the lesson. Read it and have a go at the activities. The rest is in the full lesson.

60 minutes

Close the door, then try the handle

Your test found an open door: a desk can reach the telnet service on the management server. You close it with a firewall (a tool that blocks some messages) rule.

But how do you know the door is really shut, and that you did not lock the front door at the same time? You try the handle, and you try the front door too.

By the end of this lesson

Note

I can block a service with a firewall rule and prove with tests that the fix works and breaks nothing.

Key words

WordWhat it means
Firewalla device or program that blocks some messages and lets others through
Ruleone line that says what the firewall does with a kind of message
Allowlet a message through
Dropthrow a message away without telling the sender
Default denyblock everything unless a rule allows it
Porta numbered door on a device where one service listens
Networkcomputers and devices joined together so they can share data
Routera device that passes messages from one network to another

The cells students fill in are left blank in this preview.

Starter

Have a go

Starter

3 questions
Have a go: your answers are marked here and then forgotten. Sign in if you would like your score kept, and to pick up where you left off.Sign in to keep your score

Your answers are marked here and are not kept. A college account keeps every student’s marks.

This is practice

Important

The real task gives you its own devices and settings screens. Here you use real commands in a lab. The method is the same: choose the smallest fix, give a reason, then test the fix and everything near it.

If nft is not found

Tip

These commands use nft, the Linux firewall tool. If your lab says the command is not found, install it with sudo apt-get install -y nftables, or ask your teacher to use the nat-gateway lab for this lesson.

Set up: routes out and back, part one

Command
sudo ip netns exec r1 ip route replace 10.0.99.0/24 via 10.0.12.2; sudo ip netns exec r1 ip route replace 10.0.3.0/24 via 10.0.12.2

A command for the lesson’s lab terminal. It is shown here and not run.

Set up: routes out and back, part two

Command
sudo ip netns exec r2 ip route replace 10.0.1.0/24 via 10.0.12.1

A command for the lesson’s lab terminal. It is shown here and not run.

Set up: start two services on the server

Command
sudo ip netns exec mgmt bash -c "nc -l -p 23 -k >/dev/null 2>&1 & nc -l -p 80 -k >/dev/null 2>&1 &"

A command for the lesson’s lab terminal. It is shown here and not run.

The lesson goes on

15 more parts of this lesson are in the full curriculum, with the tasks, the final check and the labs. A college account gives your students all of it.