# setsuna25th3/ttcs architecture

> Architecture diagram of the GitHub repository setsuna25th3/ttcs, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/setsuna25th3/ttcs
- Repository: https://github.com/setsuna25th3/ttcs

## Overview

TTCS.py is a single-file desktop teaching tool for exploring SHA-256 hashing and RSA encryption. Its visible input UI accepts typed text or reads a chosen file; separate windows expose SHA-256 preparation and hashing steps, and RSA key-generation and encryption/decryption workflows. The hash implementation uses binary-conversion helpers, while the RSA UI calls numeric helpers. The README is empty and the source excerpt omits application startup and wiring, so those connections are not inferred.

Main entry points: [`TTCS.py`](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py) (RSA Explorer)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_input["Input"]
  node_input_ui["Data Input<br/>[TTCS.py]"]
end

subgraph group_sha["SHA-256"]
  node_converter["Bit Converter<br/>[TTCS.py]"]
  node_sha_core["SHA-256 Engine<br/>[TTCS.py]"]
  node_sha_window["Hash Explorer<br/>[TTCS.py]"]
end

subgraph group_rsa["RSA"]
  node_rsa_window["RSA Explorer<br/>[TTCS.py]"]
  node_numeric_tools["Numeric Tools<br/>[TTCS.py]"]
end

node_user(("User"))
node_source_file["Chosen File"]

node_user -->|"enters data"| node_input_ui
node_input_ui -->|"reads file"| node_source_file
node_sha_core -->|"converts bits"| node_converter
node_sha_window -->|"creates and runs"| node_sha_core
node_rsa_window -->|"generates primes"| node_numeric_tools
node_rsa_window -->|"computes gcd"| node_numeric_tools

click node_input_ui "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"
click node_converter "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"
click node_sha_core "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"
click node_sha_window "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"
click node_rsa_window "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"
click node_numeric_tools "https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_input_ui,node_user toneBlue
class node_converter,node_sha_core,node_sha_window toneAmber
class node_rsa_window,node_numeric_tools toneMint
class node_source_file toneIndigo
```

## Components

### Input

- [Data Input](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`

### SHA-256

- [Bit Converter](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`
- [SHA-256 Engine](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`
- [Hash Explorer](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`

### RSA

- [RSA Explorer](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`
- [Numeric Tools](https://github.com/setsuna25th3/ttcs/blob/main/TTCS.py): `TTCS.py`

### Other components

- **User**
- **Chosen File**

## Connections

- User → Data Input: enters data (evidence: `TTCS.py`)
- Data Input → Chosen File: reads file (evidence: `TTCS.py`)
- SHA-256 Engine → Bit Converter: converts bits (evidence: `TTCS.py`)
- Hash Explorer → SHA-256 Engine: creates and runs (evidence: `TTCS.py`)
- RSA Explorer → Numeric Tools: generates primes (evidence: `TTCS.py`)
- RSA Explorer → Numeric Tools: computes gcd (evidence: `TTCS.py`)
