{"id":27494731,"url":"https://github.com/varunsingh87/frequency-analysis-simulator","last_synced_at":"2025-04-17T02:11:49.926Z","repository":{"id":123009292,"uuid":"198333549","full_name":"varunsingh87/Frequency-Analysis-Simulator","owner":"varunsingh87","description":"A Java program that decrypts classical ciphers without keys using frequency analysis. Includes support for simple (mono alphabetic) substitution cipher, Vigenere cipher, Caesar cipher, Vernam cipher, and variations.","archived":false,"fork":false,"pushed_at":"2025-01-31T14:53:03.000Z","size":16493,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-01-31T15:36:59.185Z","etag":null,"topics":["cipher","computer-science-project","cryptanalysis","data-visualization","frequency-analysis","frequency-analysis-simulator","java","monoalphabetic-cipher","vigenere-cipher"],"latest_commit_sha":null,"homepage":"https://varunsingh87.github.io/Frequency-Analysis-Simulator/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/varunsingh87.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-07-23T02:09:07.000Z","updated_at":"2025-01-31T14:54:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"c67f2589-0105-4e2f-a602-0fef0682cc42","html_url":"https://github.com/varunsingh87/Frequency-Analysis-Simulator","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/varunsingh87%2FFrequency-Analysis-Simulator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/varunsingh87%2FFrequency-Analysis-Simulator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/varunsingh87%2FFrequency-Analysis-Simulator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/varunsingh87%2FFrequency-Analysis-Simulator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/varunsingh87","download_url":"https://codeload.github.com/varunsingh87/Frequency-Analysis-Simulator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249300671,"owners_count":21247083,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cipher","computer-science-project","cryptanalysis","data-visualization","frequency-analysis","frequency-analysis-simulator","java","monoalphabetic-cipher","vigenere-cipher"],"created_at":"2025-04-17T02:11:49.423Z","updated_at":"2025-04-17T02:11:49.920Z","avatar_url":"https://github.com/varunsingh87.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Frequency Analysis Simulator\n\nThe purpose of this project is to decrypt a monoalphabetic substitution cipher using frequency analysis and find the\noptimal algorithm and conditions of decrypting a Vigenere cipher.\n\n## Methods of Cryptanalysis\n\n* Frequency Analysis\n* Kasiski Examination\n* Freidman Test\n* Kerckhoff's Method\n* Dictionary attack using WordNet API\n\n## Usage\n\n1. Clone this repo with `git clone https://github.com/varunsingh87/Frequency-Analysis-Simulator`\n   (for help see the [GitHub documentation](https://help.github.com/articles/cloning-a-repository/)).\n2. Run `mvn package`\n2. Run the GUI with the following command:\n\n```\nmvn compile exec:java\"\n``` \n\n### Collecting Data\n\nRun the following command for data collection of a single input (~480 runs/data points):\n\n```\nmvn compile exec:java -Dexec.mainClass=\"dataanalysis.DataCollector\"\n```\n\nRun the following command for data population of experiment data. To use a different key you will need to edit the\ndefault in DataCollector.java and make a new folder and subfolders of all the combinations of key length and caesar\ndecryption algorithms in the following format:\n\n```\noutputs/\n[ioc, friedman]_[kasiski, kerckhoff]/\n\n```\n\n### Generate executable file\n\nTo create an executable file without the user needing the Java Runtime Environment on his or her computer, use\nthe `jpackage` utility from the Java Development Kit:\n\n**Mac\n**: `jpackage --input target/ --name 'Frequency Analysis Simulation' --main-jar com.varunsingh.frequencyanalysissimulator-1.00.jar --main-class frequencyanalysissimulator.presentation.main.Main --type dmg --icon ./assets/icon.icns`\n\n**Windows\n**: `jpackage --input target/ --name 'Frequency Analysis Simulation' --main-jar com.varunsingh.frequencyanalysissimulator-1.00.jar --main-class frequencyanalysissimulator.presentation.main.Main --type exe --icon ./assets/icon.ico`\n*Does not work on Mac*\n\n**Linux\n**: `jpackage --input target/ --name 'Frequency Analysis Simulation' --main-jar com.varunsingh.frequencyanalysissimulator-1.00.jar --main-class frequencyanalysissimulator.presentation.main.Main --type deb --icon ./assets/icon.ico`\n*Does not work on Mac*\n\nDo the same for any other Java class with a main method that you would like to turn into an executable file.\n\n## Process\n\n**Phase I: Monoalphabetic Ciphers**: July 22, 2019 - February 16, 2020\n\n**Phase II: Vigenere Ciphers**: September 26, 2022 - May 8, 2023\n\n**Phase III: Graphics, Refactors, Variants**: July 22, 2023 - November 26, 2023\n\n### Phase III\n\nThe purpose of phase III was to study classical ciphers further and implement GUIs to reduce the project's reliance on\nGoogle Sheets for data visualization and analysis. The data analysis module\nin [Version 3](https://github.com/varunsingh87/Frequency-Analysis-Simulator/releases/tag/v3.0.0) contains two GUIs that\nallow a user to collect and visualize the accuracy of the Vigenere decryption algorithms with a particular message when\nencrypted with the Vigenere cipher.\n\n* Data GUI\n* Data collection GUI\n* Variants of Vigenere cipher\n\n### Phase II\n\n* [Data from Phase II](https://docs.google.com/spreadsheets/d/e/2PACX-1vQIqW8qXtnbI1yTCQR_LcYpy6F7p6eZg5EP07no3c-lBoEkMUbpTPyxo_oa5mCCj7Gfk8LOTonOY-4a/pubhtml)\n* [Presentation](https://docs.google.com/presentation/d/e/2PACX-1vR5Vu_MXCbKyHm0vHaMW5Tn4qaJWVDV34Z_WX1WpHbejcwIzODNiuNKExOOTFTRUUDs7CPsYwz8PA1T/pub?start=false\u0026loop=false\u0026delayms=3000)\n\n### Phase I\n\n* [Data from Phase I](https://docs.google.com/spreadsheets/d/130cqH1bGJPZ7mq2LrrTY6sMdm6E7qZP2Jea3s8cg3tA/edit#gid=0)\n* [Presentation](https://docs.google.com/presentation/d/e/2PACX-1vT29PD0nv69KI9cNDpZdsEA1p4eDg4P8V_XLVCWtpIFXDGnp_WmLrg-xiH120KWJkqppP9DZ-DlREr_/pub?start=false\u0026loop=false\u0026delayms=3000)\n\n## Concepts Used\n\n* Advanced Data Structures - Java Collections API, including TreeSet, HashMap, ArrayList\n* Layered Architecture - separated into presentation code (Java Swing framework), business logic (pure Java), and data\n  analysis module (I/O Streams)\n* Recursion\n\n## Built With\n\n* [Java](https://www.java.com/en/) - The programming language\n* [Maven](https://maven.apache.org/) - The dependency management system\n* [JUnit](https://junit.org/junit5/) - The testing framework\n\n## Sources of Research\n\n* Inspiration from _The Code Book_ by Simon Singh\n* _The Cryptanalyst_ by Helen Fouche Gaines\n* Michigan Technological University - explanations of the Kasiski Examination and index of coincidence with working\n  examples","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvarunsingh87%2Ffrequency-analysis-simulator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvarunsingh87%2Ffrequency-analysis-simulator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvarunsingh87%2Ffrequency-analysis-simulator/lists"}