A team from City of London School has triumphed over 724 other UK schools to win the 11th National Cipher Challenge.
A total of 1,600 teams took part in the competition held towards the end of 2012, up from 200 teams in previous years.
The national code-breaking competition is organised by Southampton University, with support from the government intelligence agency GCHQ and commercial partners.
Foreign secretary William Hague MP launched the latest competition at code-breaking museum Bletchley Park in October 2012, as part of three GCHQ initiatives aimed at attracting young people into maths and computer science.
Cracking cryptic codes
Teams were required to decode a series of cryptic codes released online over a period of two months, with the codes increasing in difficulty.
Only 30 of the 1,600 teams that entered managed to complete every level, according to Graham Niblo, organiser of the contest and mathematics professor at Southampton University.
"The last cipher was not a standard cipher – we modified it so they couldn't use any standard decryption software,” he told the BBC.
The winning team – Samson Danziger, Daniel Hu, Anthony Landau and Charlie Hu – cracked the Trifid code in 44 hours and 20 minutes. They will receive a £1,000 prize from GCHQ.
Second place went to Andrew Carlotti from Sir Roger Manwood’s School in Kent, who competed on his own. Carlotti managed to crack the Trifid cipher in 46 hours and 54 minutes, winning the £800 IBM prize.
The third place went to a team from King Edward VII School in Sheffield, which will receive the £700 Trinity College prize.
Additionally, the top 50 runners-up will each receive a Raspberry Pi computer. The prize-giving ceremony will take place at Bletchley Park on 12 April.
More on code-breaking
- GCHQ releases Alan Turing code-breaking papers
- Breaking the code: Are passwords destined for obscurity?
- Cyber Security Challenge UK announces first University Challenge
- Breaking the World War 2 German encryption codes
- GCHQ launches online code-cracking test to attract ethical hackers
- Code-breaker secrets
Universities accept cipher challenge
The computer science departments at the University of Bristol, University of Birmingham, University College London and Edinburgh Napier University have accepted the challenge to develop their own cipher or puzzle based on encrypted messages.
The cipher will be released to other participating universities and Challenge candidates to break in a four-week virtual tournament which begins on 21 January. A new cipher will be released each week.
The competition is designed to inspire students who are particularly interested in entering cyber security careers and practising their skills.
The tournament will also act as a proof of concept for a series of university-on-university competitions the Cyber Security Challenge is looking to run in the future.