Visualising a Traffic-Light Hacking Challenge in Unity

A low-poly Unity city built for the CrySyS PLC-hacking challenge.

Low-poly Unity city with cars queuing at junctions around a small park.

While working at CrySyS1, the cybersecurity research group at my first university, I got the fun job of simulating traffic in a small city. The lab was preparing a hacking challenge targeting PLCs that controlled traffic lights, so a successful attack would cause mayhem on the roads.

I built the simulation in Unity2. C# scripts controlled the drivers, with driving and self-driving models designed to look realistic. Unity polled an external REST service at /trafficLights/ to read the traffic-light states controlled by the challenge infrastructure. The drivers had to obey those lights unconditionally, tunnel vision and all. That was the point: faulty control logic had to lead to wacky disasters on screen.

The art was on me too, so I ended up watching a bunch of Blender Guru3 tutorials and modelling everything in a low-poly style. Far too much of that time went into animating a playground swing rocking back and forth in the city’s park; it wasn’t great, but it looked passable from a distance.

The CTF’s large venue, with screens dotted everywhere, added one final challenge: netcode. The whole simulation ran on a server, with each screen acting as a thin client that interpolated between received states to keep the motion smooth.

References
  1. CrySyS: https://www.crysys.hu/↩
  2. Unity: https://unity.com/↩
  3. Blender Guru: https://www.youtube.com/@blenderguru↩

Searches titles, descriptions, and the full text of every article.

    ↑↓ to move↵ to openEsc to close