Cybersecurity + Pure Mathematics
Implement classic ciphers and break them
Write Caesar and substitution ciphers, then crack them with frequency analysis.
- DifficultyEasy
- Estimated time2–7 days
- Budget₹0
- ClassClass 8–12
- TeamSolo or up to 2
- You needComputer only
Prerequisites: None beyond your class work
Original · by TechnifyedInvestigationSoftware ProjectBeginner friendlyFree to doComputer onlyResearch orientedWell documentedTwo subjects
Overview
Write Caesar and substitution ciphers, then crack them with frequency analysis.
Why build this?
Breaking your own cipher is the fastest way to understand why modern encryption is designed as it is.
What you will learn
- How substitution ciphers work
- How letter frequencies reveal a key
- Why a small key space is weak
Skills you will use
Materials and tools
- Computer with Python 3
- A few paragraphs of English text
Tools and software
Step-by-step roadmap
Start
You will finish with: working ciphers and a demonstration that both can be broken.
- 1
Prerequisites
Nothing special to know first. Then collect the 2 items in the materials list.
- 2
Learn
- How substitution ciphers work
- How letter frequencies reveal a key
- Why a small key space is weak
- 3
Plan
List the features for version one, sketch the screens or data flow and pick the tools. Keep the first version small.
- 4
Build
- Write functions to encrypt and decrypt with a Caesar shift.
- Break it by trying all 26 shifts.
- Write a substitution cipher with a random key.
- Count letter frequencies in the ciphertext.
- Use English letter frequencies to recover the key.
- 5
Test
Try it with wrong, empty and unusual input, and ask someone else to use it without your help.
- 6
Document
Write a README: what it does, how to run it, screenshots and what you learned. Report structure
- 7
Present
Show a live demo of one complete task, then the design and the hardest problem you solved. Presentation structure · Viva questions
- 8
Publish
Put the code on GitHub with the README and, if you can, deploy a live demo.
Expected outcome
Working ciphers and a demonstration that both can be broken.
Other versions of this project
Beginner version
Write only the Caesar cipher and try all 26 shifts.
Advanced version
Implement the Vigenère cipher and break it with the Kasiski method.
Make this project better
- BasicWrite only the Caesar cipher and try all 26 shifts.
- This projectImplement classic ciphers and break them
- AdvancedImplement the Vigenère cipher and break it with the Kasiski method.
Ways to do this project
Text marked "You write this" is a prompt for your own work; everything else is specific to this project.
- Problem
- You write thisWrite your question as: How does [what you change] affect [what you measure]?
- Hypothesis
- You write thisWrite it as: If [I change this], then [this will happen], because [reason].
- Variables
- You write thisName the one thing you change (independent), the thing you measure (dependent) and what you keep the same (controlled).
Materials and procedure are in Materials and the Roadmap.
Observation table
You write thisDraw a table with one column for what you change, one for each repeat reading and one for the average.
- Graph
- You write thisPlot what you changed along the bottom and what you measured up the side; use a bar chart for categories and a line graph for numbers.
- Results
- You write thisState what the graph shows in one or two sentences, with numbers.
- Conclusion
- You write thisSay whether the result supports your hypothesis and why you think so.
Display board
- Title and your name
- Question
- Hypothesis
- Materials
- Procedure (with photos)
- Data table and graph
- Conclusion
- What you would do next
Questions judges ask
- Why is a Caesar cipher weak?
- What is frequency analysis?
- What is the most common letter in English?
- What would you change if you did this again?
- What was your biggest source of error, and how did you reduce it?
- Where is this idea used in real life?
- Research question
- You write thisOne question you can answer with data, narrow enough to finish in the time you have.
- Hypothesis
- You write thisWhat you expect to find, and why.
- Variables
- You write thisWhat you change or compare, what you measure, and what you hold constant.
- Methodology
- You write thisDescribe the method in enough detail that someone else could repeat it: sample, tools, procedure.
- Data collection
- You write thisSay what you will record, how many times, and how you will keep the records safe.
- Analysis
- You write thisChoose the table, chart or test that answers the question; report averages with their spread.
- Limitations
- You write thisList what could have affected the result: small sample, instrument limits, things you could not control.
Literature review
Find five to eight sources (your textbook, review articles, reports) and note what each says about your question. Group them by idea, not one after another, and end with what is still not known.
References
List every source you used in one style throughout (author, year, title, where it was published, link and the date you opened it).
Use this as the outline of your README or case study.
- Problem
- You write thisThe problem in one or two sentences.
- Why it matters
- Breaking your own cipher is the fastest way to understand why modern encryption is designed as it is.
- What was built
- Working ciphers and a demonstration that both can be broken.
- Technology
- Python
- Architecture
- You write thisOne diagram: the parts and how data moves between them.
- Implementation
- You write thisThe 5 build steps in your own words, with one code or design decision you are proud of.
- Challenges
- You write thisThe hardest bug or decision, and how you got past it.
- Results
- You write thisNumbers: accuracy, speed, users, survey answers.
- Demo and code
- You write thisA link to a live demo or a short video, and to the GitHub repository.
- Lessons learned
- You write thisWhat you would do differently next time.
- Future improvements
- Implement the Vigenère cipher and break it with the Kasiski method.
- Problem
- Write Caesar and substitution ciphers, then crack them with frequency analysis.
- Target user
- You write thisOne specific person: who they are and when they would use this.
- Solution
- Write Caesar and substitution ciphers, then crack them with frequency analysis.
- First version (MVP)
- Write only the Caesar cipher and try all 26 shifts.
- Tech stack
- Python
- Architecture
- You write thisA quick sketch of the parts and how they connect.
- Demo
- You write thisThe one scenario you will show live, start to finish, in under two minutes.
- Stretch goals
- Implement the Vigenère cipher and break it with the Kasiski method.
Team roles
Plan by length
24-hour
- Hours 0–2: agree the problem, the user and the one thing the demo must show
- Hours 2–16: build only the first version
- Hours 16–20: test the demo path end to end and fix what breaks
- Hours 20–24: slides, a 2-minute demo script and a backup recording
48-hour
- Evening 1: problem, user, sketch and task split
- Day 1: first version working end to end
- Day 2 morning: one stretch goal and testing
- Day 2 afternoon: polish, slides and demo practice
1-week
- Day 1: research the problem and talk to two possible users
- Days 2–4: first version
- Day 5: stretch goals
- Day 6: testing and write-up
- Day 7: demo video and presentation
Working as a team
Solo or up to 2. Suggested roles:
Report and presentation
Report structure
- Title and summary
- Problem and target user
- Features
- Tools and technology
- Design: architecture, data model or screens
- Implementation
- Testing
- Results and screenshots
- Challenges
- Future improvements
- References
Presentation structure
- The problem
- Who it is for
- Live demo
- How it is built (one diagram)
- The hardest part
- Testing and results
- What you learned
- What comes next
Viva questions
Try answering before you open each one.
Why is a Caesar cipher weak?
There are only 25 possible keys, so all can be tried.
What is frequency analysis?
Using how often letters appear to guess which ciphertext letter stands for which.
What is the most common letter in English?
E.
Resources
Source and attribution
Original
Written by Technifyed. Free to use for your own school or college project; write the report in your own words. Added 1 Oct 2026.
Similar projects
More Cybersecurity projects
Cybersecurity · Authentication
Build a password strength checker
Score a password's strength, explain why, and estimate how long it would take to guess.
Cybersecurity · Privacy
Audit your digital footprint
Find what is publicly visible about you online and tighten your privacy settings.
Cybersecurity · Digital Forensics
Recover deleted files from a test drive
Delete files on a spare USB drive, image it and see what can be recovered and why.
Cybersecurity + Systems and Cloud
Analyse your own home network traffic
Capture traffic on your own computer and identify which protocols and services it talks to.
Same tools
Programming · Python
Build a Snake game
Program the classic Snake with scoring, growing length and game over.
Programming · Python
Make a to-do list app that saves to a file
Build a command-line task manager that adds, completes, deletes and saves tasks between runs.
Data · Data Analytics
Explore a dataset and tell its story
Pick a public dataset, ask five questions of it and answer each with a chart.
Programming · Python
Automate a boring task with a script
Write a script that renames and sorts a messy folder of files by type and date.
Two-subject alternatives
Public Policy and Governance + Cybersecurity
Study data privacy in the apps you use
Read the privacy policies and permissions of five apps and compare what they collect.
Pure Mathematics + Geography
Investigate the four-colour theorem with maps
Colour maps of states and districts with as few colours as possible and link it to graph colouring.
Pure Mathematics + Biology
Explore the Fibonacci sequence in nature
Count spirals on pine cones, sunflowers and pineapples and test whether they are Fibonacci numbers.
Programming + Cybersecurity
Make a file encryption tool
Encrypt and decrypt files with a password using a well-tested library.
Same difficulty and budget
Artificial Intelligence · NLP
Build a rule-based chatbot for school FAQs
Answer common questions about your school with keyword matching and a fallback reply.
Programming · Python
Build a calculator with a graphical interface
Make a desktop calculator with buttons, a display and keyboard support.
Software Development · Frontend
Make a personal portfolio website
Design and publish a fast, mobile-friendly site that shows who you are and what you have built.
Programming · JavaScript
Build a typing speed tester
Show a passage, time the user typing it and report words per minute and accuracy.