I'm thinking about creating a liveCD having some linux on it. The distro (let's call it Exam OS) is meant to be used by students during an exam and should be, at least, unpleasent to bypass. Let's assume that students can come with their own notebooks and they receive a bootable Exam OS on CD.

The distro should be characterised by:

  • limited network access (preferably only to wolframalpha.com and / or Overlord Server [verifying users]) - no communication with other students and the external web
  • limited packages (but on the other hand some added like Maxima)

The second point is, what I believe, the easy one. The first seems to get harder if I want to be sure that no matter how long they analyse CD (they can save it on their HDD, right?) they won't b able to bypass the limitations. What is more, the system should be easy to verify ( well students may make.. similar system which looks just like my). I was thinking about logging and registering to the Overlord so that you can look how many PC are logged and what names (real names i mean) are they registered to. Server could also provide the user wih some KEY which student would have to put on his paper (yeah, in fact it's all paper work and PC should be only helping).

My questions are:

  • on which distro should I base Exam OS
  • what should I do to counter any attempts bypassing by students?

Thanks for any thoughts on the matter.

  • I believe that your stated requirement that "no matter how long they [analyze the] CD ... they won't [be] able to bypass the limitations" is close to impossible to meet. You could set up a separate VLAN and make their PCs use that, with outbound filtering and filtering DNS queries, but it would still only be an obstacle. Remember, you are basically giving them everything and then hoping to keep it secret. You can't keep how to make the secret sauce secret for long if you give the recipe to every person on the street (which is similar to what you are proposing) only asking them not to use it. – user Jan 24 '13 at 15:15
  • you can easily bypass all their network connections through a proxy, and log them..this in itself doesn't forbid them from illicit activities, but is traceable. – JoséNunoFerreira Jan 24 '13 at 15:21
  • 1
    @MichaelKjörling I am aware that bypassing limitations will always be possible. All I want is making hard enough to be harder to break than to learn actual math. :) – Jaom Jan 24 '13 at 15:28
  • You might want to take a look at Suse Studio (susestudio.com). You can build your own custom openSuSE-based linux with it. – Josh Austin Jan 24 '13 at 17:52

Without at least the threat of harm you cannot enforce a student booting your Exam OS. Skip to the horizontal rule for how I would achieve your overall goal. This is how I would fool your system:

I would boot into my Linux, where I will always have root privileges and everything I may need. Then I would mount the Exam OS root file system. That file system is on the CD you gave me and I will always be able to mount it. Then I would open a new terminal, chroot into Exam OS and fire up Exam OS inside that chroot-jail. If you based Exam OS on Debian or one of its derivatives I'd

/etc/init.d/rc S
/etc/init.d/rc 2

In effect I will have your Exam OS, which means I have everything you want to give me and at the same time I have my own Linux for everything you don't want to give me.

Maybe I'm overshooting a little by running /etc/init.d/rc S and probably should restrict myself to running /etc/init.d/rc 2 only. Every distribution has an easy to find out similar magic incartation.

Yes, you can go to war and make this cost me valuable exam time, but for every minute you cost me you have to invest several hours! Also, you have to make Exam OS refuse to boot inside a virtual machine, as that's another option to fool your system.

So much for the destructive part, let's get constructive. :-)

If you don't want students doing something, tell them and fail them, if they break that rule. That has worked for centuries! I would hand out Exam OS CDs and tell them using another OS during this exam is considered cheating. Now we have that problem solved. All we need to do now is catch them cheating (which they most likely won't anyway anymore).

To create Exam OS I'd modify some existing Live-CD. Which is almost irrelevant, however, it will be easiest if it is some "full scale" Linux so Ubuntu and Fedora are the first that come to mind, here is an incredibly large list of alternatives. I'd pick the one with the best documentation on how to create/rebuild the live-cd! The finished Exam OS would have to fulfill the following requirements:

  1. students have quick access to all programs I want them to have
  2. the desktop has distinctive design/skin so I can tell from a distance with 80% certainty if somebody is not using Exam OS
  3. no username password authentication is required by default
  4. to log in as another user, su or sudo you need an USB-stick (the one on your keychain) to authenticate
  5. have funky network settings so to restrict the internet and local communication to fit my needs.
  6. have a customised kernel that doesn't even have support for bluetooth, irda or any other subsystem than ethernet that could enable communication. USB needs to be restricted as well!

1 basically means I put desktop shortcuts to everything I want them to be able to use. That way I would have easy testing if everything works.

To achieve 2 I would skin the desktop with the school colors and an occational logo so that I recognise the Exam OS desktop when I see it. During the exam, when I see odd colors or pictures or even miss something I know should be there I can investicate more closely.

3 is easy, makes Exam OS uncomplicated and when I think somebody is cheating I can close the laptop, turn it around and open it up. When I see an Exam OS I appoligise, if I don't or even see a locked screen I caught someone cheating.

4 means to harden the system so you can only become root by having my usb key. There is a pam module for that so the USB-stick authentication is not hard to do (google pam_usb). With the basic OS of a live CD and that pam module in place for any service that can be used to get super user privileges, i.e., login, su, sudo and maybe some desktop manager and sshd, it should be sufficiently hard to become root. After that one still has to make sure that the normal user may not edit important configuration files and directories!

5 means no nameserver-entry in /etc/resolv.conf but some entries in /etc/hosts for all the websites I want the users to be able to visit. Also there needs to be a restrictive firewall which drops all incomming and outgoing packets and for each host I want the students to be able to reach an exception by ip-address has to be defined.

6 means just that. take the config from the generic kernel of the live-cd you chose and rip out all the subsystems you don't want. sound, video for linux, bluetooth, everything that is not needed during the exam. Rip out everything usb that is not usb-hid and usb-storage. Very important w.r.t. USB-stricks: remove all the filesystems that you do not need, and keep only those you need. For the authentication stick I would choose some odd FS that nobody anymore. Maybe even an experimental one that is not part of standard linux.

That's a rough guide only, sorry :D

  • GENERAL NOTE: It's only to make it more difficult to bypass limitations that to take a cellphone from your pocket and send data this way... (assuming that I won't notice cellphones which is impossible to fully control) the destructive part: what if I encrypted entire system letting studens use it only when teacher writes down his password? They would need a hardware keylogger (assuming not in a virtual machine). ad 4. +1 ad 6. +1 – Jaom Jan 25 '13 at 16:42
  • If you encrypt the root FS you would have to walk from student to student and type the password very often for many people to see. Not very safe but I think viable for exams with only few students. You need to spend some seconds to be sure it's not a virtual machine. I'd guess you need 30-40 seconds per student. What keeps students from rebooting into their own OS, if they have all the software installed? You need something to ensure they use Exam OS only. I have an idea for 7 and 8 :) – Bananguin Jan 25 '13 at 18:18
  • I'd choose Ubuntu as the base, to be safe. Many distro's don't support all hardware, for example, SliTaz fails to boot on my own laptop. – stommestack Oct 20 '13 at 14:48

Having them use your CD seems pretty invasive. Also, some netbook might not contain a CD drive at all...(let alone a student without an own device!) Do you have a computer lab available?

Have a look at1: Sage. It bundles lots of open-source math software (e.g. Maxima, GAP, SymPy, NumPy) in a web-based (notebook-centric) interface. Plus, people have been using it for computerized exams and share their experience and setup ideas on the sage-edu mailing list.

Having a Sage server (with locked-down worksheet sharing? Not sure if that's possible) on the local network, shut down properly, could enable you to disable internet access completely...

1: I have not thought this through completely, but maybe it's helpful anyways.

  • 1. We do have computer lab avaliable, but working stations are too close so in one lab max of 10 students can write a test which is troublesome for a group of 130 students. 2. The students have their own notebooks (not netbooks) or at least have access to some. They are studying Computer Science... 3. I've came across Sage. Didn't like it for various reasons (syntax, web-based, not widely used by anyone around...), yet perhaps this is the way to go... Yeah, it's helpful anyway. Made me look closer to Sage once again. :) That discuss group will be very useful! – Jaom Jan 24 '13 at 22:00
  • Machines without CD drives are ever more popular (iMacs come to mind, and the current crop of "ultrabooks"). And how would you distinguish my notebook running ExamOS from my Fedora, configured as a lookalike? – vonbrand Jan 24 '13 at 23:08
  • 1. They are more popular but not popular enough to be a problem. Later perhaps I could think about pendrives or something like that. 2. Distinguishing system is one of the issues I want to resolve. – Jaom Jan 25 '13 at 16:28
  • You could fix the problem that not all computers have disk drives by handing out LiveUSB's instead of LiveCD's. – stommestack Oct 20 '13 at 14:49

A couple of suggestions to make things harder. A lot of these assume that you're doing this somewhere at school, not that you're sending the CDs home (if you are, give up: the student could just cheat using another computer, phone, tablet, etc.)

NFS Rootfs

Instead of having the entire OS on the CD, only put a minimal system on it. Preferably only through initramfs. Have it use an NFS root filesystem, on a server you/the school controls, and can only be accessed on exam day.

This way, the test taker has a much harder time examining the system; he/she must do it during the exam. The test taker of course should not have root access, and no persistent, writable media should be mounted, so he/she will have a hard time tar'ing up the rootfs to examine later.

Also much easier for you to update. You don't have to burn 200 CDs each time you want to.

going further

If all the machines support netbooting, netboot them. Do not distribute CDs at all.

Make it look different

Linux desktop environments are very customizable. You can (depending on which one) change the color of the windows, title bars, the fonts used, the look of the menu & task bars, the desktop background, etc. Don't do anything crazy (that'll make the system too unfamiliar), but do make it non-default. Then you'll be able to quickly glance at screens and see the one that doesn't look right.

You could also do smaller things. E.g., put some icon on the desktop, or an analog clock in the menu bar. When you look closely at a screen, you can check for these.

… each exam

Someone might be able to copy your look and have it ready for the next exam. Or at least close enough that you have to look carefully.

If you don't have to re-burn images all the time, its easy to change the appearance each exam. The student won't know what ExamOS will look like today until he/she starts the exam.

Set up a VNC server

You can set VNC up to allow you to view the desktop, so you can check on people from the comfort of your desk. Ethically, I think your should notify people that you can do this.

Record exams

If you have the fileserver space & bandwidth, do a screen recording of the entire exam session. (There are several screen recording programs). Review only if suspicion arises and/or a random sample. Another one which, ethically, I think you should notify students of.

Control the media

You should give out the ExamOS CDs at the beginning of the exam, and collect them at the end. Require that people turn them back in.

Network control


You can block all outgoing traffic except the traffic you'd like using iptables. I'd suggest you configure the web browser to use an HTTP proxy, and the only outgoing traffic you allow is to that proxy. Additionally allow DNS if needed to connect to the proxy (but only to your DNS servers).


You can configure squid, apache, etc. with a list of URLs that are allowed and disallowed. You can run this on a server you control, or each local machine.

external firewall

If all the exam machines are behind a firewall you control, block things there, too. The student won't be able to bypass that, without bringing their own connection.

  • ad different look: they can run it, memorise (or have it in virtual machine), and change their system right away. ad VNC - good idea ad recording - perhaps only some of the data. Data from proxy/overlord should be enough to determine if someone was making use of it. ad taking CD back - obvious but may happen that someone copy the CD during the exam I find your post very useful. Thanks! – Jaom Jan 25 '13 at 16:50
  • @Jaom That's part of the point of the smaller things that are different. Maybe they'll fail to copy some of those, and then you'll be able to tell. Also, most virtual machine hypervisors don't try to hide their existence from the guest—you can detect them. See imvirt/imvirt-helper. – derobert Jan 25 '13 at 16:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.