Compare commits

...

17 Commits

Author SHA1 Message Date
0e370eb457 new index
All checks were successful
Deploy / trigger (push) Successful in 21s
2026-03-27 23:14:15 +01:00
15e1860105 Merge branch 'main' of https://git.vps.francescomancuso.it/elisabetta/cryptoseals
All checks were successful
Deploy / trigger (push) Successful in 20s
2026-03-27 22:47:52 +01:00
2565f8f04c fixed urls 2026-03-27 22:47:47 +01:00
259296fc0f Fix su pom.xml
All checks were successful
Deploy / trigger (push) Successful in 20s
2026-03-27 22:34:48 +01:00
af5415a6f1 Fix su pom.xml
All checks were successful
Deploy / trigger (push) Successful in 20s
2026-03-27 22:32:54 +01:00
d3ab08e944 Merge branch 'main' of https://git.vps.francescomancuso.it/elisabetta/cryptoseals
All checks were successful
Deploy / trigger (push) Successful in 20s
2026-03-27 22:21:22 +01:00
97387d2867 Quick fix su pom.xml 2026-03-27 22:21:19 +01:00
75698d078f Merge branch 'main' of https://git.vps.francescomancuso.it/elisabetta/cryptoseals
All checks were successful
Deploy / trigger (push) Successful in 19s
2026-03-27 22:18:58 +01:00
c45f4414b1 random 2026-03-27 22:18:54 +01:00
e559bd2e58 Quick fix su pom.xml
All checks were successful
Deploy / trigger (push) Successful in 19s
2026-03-27 22:16:15 +01:00
b6c9155b81 Quick fix su pom.xml
All checks were successful
Deploy / trigger (push) Successful in 20s
2026-03-27 22:13:31 +01:00
19d360b4d6 Deploy su server Java
All checks were successful
Deploy / trigger (push) Successful in 19s
2026-03-27 22:08:12 +01:00
56214f1b57 Nuova versione per build web
All checks were successful
Deploy / trigger (push) Successful in 20s
Signed-off-by: Francesco Mancuso <hello@francescomancuso.it>
2026-03-27 21:55:44 +01:00
5b02382cf5 Merge branch 'main' of https://git.vps.francescomancuso.it/elisabetta/cryptoseals
All checks were successful
Deploy / trigger (push) Successful in 17s
2026-03-27 21:49:18 +01:00
a727a0160f fixed gitignore 2026-03-27 21:49:12 +01:00
923bc348cf Fixed structure again 2026-03-27 21:48:15 +01:00
c382d1c514 Fixed structure 2026-03-27 21:48:04 +01:00
16 changed files with 968 additions and 822 deletions

View File

@@ -12,7 +12,7 @@ jobs:
env:
REPO_NAME: ${{ gitea.event.repository.name }}
REPO_OWNER: ${{ gitea.repository_owner }}
ROOT_DIR: "/src"
ROOT_DIR: "/backend/src/main/java/com/crypto"
TYPE: "java"
JOB_TOKEN: ${{ gitea.token }}
run: |

12
.gitignore vendored
View File

@@ -24,16 +24,6 @@
hs_err_pid*
replay_pid*
# ---> Maven
target/
pom.xml.tag
pom.xml.releaseBackup
pom.xml.versionsBackup
pom.xml.next
release.properties
dependency-reduced-pom.xml
buildNumber.properties
.mvn/timing.properties
# https://github.com/takari/maven-wrapper#usage-without-binary-jar
.mvn/wrapper/maven-wrapper.jar
@@ -43,3 +33,5 @@ buildNumber.properties
# JDT-specific (Eclipse Java Development Tools)
.classpath
target/
.vscode/

4
.vscode/settings.json vendored Normal file
View File

@@ -0,0 +1,4 @@
{
"maven.view": "hierarchical",
"java.configuration.updateBuildConfiguration": "interactive"
}

68
backend/pom.xml Normal file
View File

@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.crypto</groupId>
<artifactId>cryptoseals</artifactId>
<version>1</version>
<properties>
<maven.compiler.source>23</maven.compiler.source>
<maven.compiler.target>23</maven.compiler.target>
</properties>
<dependencies>
<dependency>
<groupId>io.javalin</groupId>
<artifactId>javalin</artifactId>
<version>6.1.3</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>2.0.16</version>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.16.1</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<archive>
<manifest>
<mainClass>
com.crypto.Seal
</mainClass>
</manifest>
</archive>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<attach>true</attach>
<finalName>app</finalName>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@@ -13,7 +13,7 @@ public class Seal {
}).start(8080);
System.out.println("Generazione chiavi RSA per il server web in corso...");
System.out.println("Generazione chiavi RSA per il server web in corso...");
// Cifratura con Cifrario di Cesare
app.post("/seal/caesar/encrypt", ctx -> {

View File

@@ -50,7 +50,7 @@
if(!input) return alert("Inserisci del testo!");
try {
const risposta = await fetch("http://localhost:8080/api/cesare/cifra", {
const risposta = await fetch("/seal/cesare/encrypt", {
method: "POST", headers: { "Content-Type": "application/json" },
// Invia il testo e la CHIAVE (convertita in numero) al server
body: JSON.stringify({ testo: input, chiave: parseInt(chiave) })
@@ -65,7 +65,7 @@
if(!inputCifrato) return alert("Nessun testo da decifrare!");
try {
const risposta = await fetch("http://localhost:8080/api/cesare/decifra", {
const risposta = await fetch("/seal/cesare/decrypt", {
method: "POST", headers: { "Content-Type": "application/json" },
body: JSON.stringify({ testo: inputCifrato, chiave: parseInt(chiave) })
});

View File

@@ -0,0 +1,58 @@
<!DOCTYPE html>
<html lang="it">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CryptoSeals - Home</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<nav class="navbar">
<a href="index.html" class="nav-brand">
<img src="seal1.png" height="50" alt="🦭" onerror="this.src='https://cdn-icons-png.flaticon.com/512/3063/3063126.png';">
CryptoSeals
</a>
<div class="menu-toggle" onclick="toggleMenu()">
<i class="fa-solid fa-bars"></i>
</div>
<ul class="nav-links" id="nav-links">
<li><a href="rsa.html"><i class="fa-solid fa-key"></i> RSA</a></li>
<li><a href="cesare.html"><i class="fa-solid fa-arrow-right-arrow-left"></i> Cesare</a></li>
<li><a href="vigenere.html"><i class="fa-solid fa-table"></i> Vigenère</a></li>
<li><a href="team.html"><i class="fa-solid fa-users"></i> Il Team</a></li>
</ul>
</nav>
<div class="container" style="display: flex; flex-direction: column; align-items: center; justify-content: center; height: 60vh;">
<h1>Welcome to CryptoSeals</h1>
<p class="descrizione">
Dive deep, Seal your data. <i class="fa-solid fa-water"></i><br><br>
Scegli uno strumento dal menu per iniziare a proteggere i tuoi messaggi!
</p>
<img src="seal1.png" alt="Mascotte CryptoSeals" style="max-width: 250px; border-radius: 20px; box-shadow: 0 10px 30px rgba(16, 185, 129, 0.2);" onerror="this.src='https://cdn-icons-png.flaticon.com/512/3063/3063126.png';">
</div>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320" style="margin-bottom: -5px;">
<path fill="#0b0f19" fill-opacity="1" d="M0,160L48,170.7C96,181,192,203,288,208C384,213,480,203,576,176C672,149,768,107,864,117.3C960,128,1056,192,1152,213.3C1248,235,1344,213,1392,202.7L1440,192L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path>
</svg>
<footer>
<div class="copyright">
<a href="/privacy-policy/">Privacy Policy</a> |
<a href="#"><i class="fa-brands fa-github"></i> GitHub</a> <br><br>
© <span id="year"></span> CryptoSeals Team
</div>
</footer>
<script>
// Gestione Menu Mobile
function toggleMenu() {
document.getElementById("nav-links").classList.toggle("active");
}
// Anno dinamico Footer
document.getElementById("year").innerText = new Date().getFullYear();
</script>
</body>
</html>

View File

@@ -30,8 +30,9 @@
<select id="keysize">
<option value="512">512 bit (Solo didattico - Veloce)</option>
<option value="1024" selected>1024 bit (Test - Bilanciato)</option>
<option value="2048">2048 bit (Standard - Lenta da generare)</option>
<option value="4096">4096 bit (Alta sicurezza - Molto lenta ⏳⏳)</option>
<option value="2048">2048 bit (Standard - Lenta da generare)</option>
<option value="3072">3072 bit (Ottima - Mediamente Lenta)</option>
<option value="4096">4096 bit (Alta sicurezza - Molto lenta)</option>
</select>
<div class="crypto-columns">
@@ -67,7 +68,7 @@
try {
// NOTA: Controlla che la rotta nel tuo Java sia corretta (/seal/rsa/encrypt o /api/rsa/cifra)
const res = await fetch("http://localhost:8080/seal/rsa/encrypt", {
const res = await fetch("/seal/rsa/encrypt", {
method: "POST", headers: { "Content-Type": "application/json" },
body: JSON.stringify({ text: plaintext, keysize: parseInt(size) })
});

View File

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

@@ -0,0 +1,238 @@
/* --- IMPORTS --- */
@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500&family=Poppins:wght@300;400;600&display=swap');
/* --- VARIABILI GLOBALI --- */
:root {
--bg-dark: #0b0f19;
--accent-green: #10b981;
--accent-hover: #059669;
--text-main: #f3f4f6;
--glass-bg: rgba(17, 24, 39, 0.7);
--glass-border: rgba(255, 255, 255, 0.1);
}
/* --- BASE --- */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
font-family: 'Poppins', sans-serif;
background: radial-gradient(circle at top right, #1f2937, var(--bg-dark));
color: var(--text-main);
min-height: 100vh;
display: flex;
flex-direction: column;
}
/* --- NAVBAR (Glassmorphism) --- */
.navbar {
display: flex;
justify-content: space-between;
align-items: center;
padding: 15px 5%;
background: var(--glass-bg);
backdrop-filter: blur(10px);
-webkit-backdrop-filter: blur(10px);
border-bottom: 1px solid var(--glass-border);
position: sticky;
top: 0;
z-index: 1000;
}
.nav-brand {
display: flex;
align-items: center;
gap: 15px;
font-size: 1.5rem;
font-weight: 600;
color: var(--text-main);
text-decoration: none;
}
.nav-brand img {
border-radius: 50%;
}
.nav-links {
list-style: none;
display: flex;
gap: 20px;
}
.nav-links a {
color: var(--text-main);
text-decoration: none;
font-weight: 400;
transition: color 0.3s ease;
}
.nav-links a:hover, .nav-links a.active {
color: var(--accent-green);
}
/* Menu Mobile */
.menu-toggle {
display: none;
font-size: 1.5rem;
cursor: pointer;
}
/* --- CONTENITORI --- */
.container {
flex: 1;
max-width: 1000px;
margin: 40px auto;
padding: 0 20px;
text-align: center;
}
h1 {
font-size: 2.5rem;
margin-bottom: 15px;
color: var(--accent-green);
}
.descrizione {
font-size: 1.1rem;
margin-bottom: 30px;
color: #9ca3af;
}
/* --- CRYPTO BOX (Glassmorphism) --- */
.crypto-box {
background: var(--glass-bg);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid var(--glass-border);
border-radius: 15px;
padding: 30px;
text-align: left;
box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.crypto-columns {
display: flex;
gap: 20px;
margin-top: 20px;
}
.crypto-col {
flex: 1;
display: flex;
flex-direction: column;
gap: 10px;
}
/* --- FORMS & INPUTS --- */
label {
font-weight: 600;
font-size: 0.9rem;
color: var(--accent-green);
}
select, textarea {
width: 100%;
padding: 12px;
border-radius: 8px;
background: rgba(0, 0, 0, 0.3);
border: 1px solid var(--glass-border);
color: var(--text-main);
font-family: 'Poppins', sans-serif;
outline: none;
transition: border-color 0.3s;
}
select:focus, textarea:focus {
border-color: var(--accent-green);
}
/* Font Monospazio per il testo cifrato */
#ciphertext, #decodedtext {
font-family: 'Fira Code', monospace;
font-size: 0.9rem;
}
textarea {
resize: vertical;
min-height: 120px;
}
/* --- BOTTONI --- */
button {
padding: 12px;
border: none;
border-radius: 8px;
background-color: var(--accent-green);
color: white;
font-size: 1rem;
font-weight: 600;
cursor: pointer;
transition: background-color 0.3s, transform 0.1s;
font-family: 'Poppins', sans-serif;
display: flex;
justify-content: center;
align-items: center;
gap: 8px;
}
button:hover {
background-color: var(--accent-hover);
}
button:active {
transform: scale(0.98);
}
button:disabled {
background-color: #374151;
cursor: not-allowed;
}
.btn-green {
background-color: #3b82f6; /* Usiamo un blu per distinguere la decifratura */
}
.btn-green:hover {
background-color: #2563eb;
}
/* --- FOOTER --- */
footer {
text-align: center;
padding: 20px;
background: var(--bg-dark);
border-top: 1px solid var(--glass-border);
font-size: 0.9rem;
color: #6b7280;
}
footer a {
color: var(--accent-green);
text-decoration: none;
}
/* --- RESPONSIVE --- */
@media (max-width: 768px) {
.crypto-columns {
flex-direction: column;
}
.nav-links {
display: none;
flex-direction: column;
position: absolute;
top: 70px;
left: 0;
width: 100%;
background: var(--bg-dark);
padding: 20px 0;
text-align: center;
}
.nav-links.active {
display: flex;
}
.menu-toggle {
display: block;
}
}

View File

@@ -1,47 +0,0 @@
<!DOCTYPE html>
<html lang="it">
<head>
<meta charset="UTF-8">
<title>CryptoSeals - Home</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<nav class="navbar">
<a href="index.html" class="nav-brand">
<img src="seal1.png" height="80" alt="🦭" onerror="this.style.display='none'; this.nextElementSibling.style.display='inline';">
<span style="display:none;"><img src="seal1.png"></span> CryptoSeals
</a>
<ul class="nav-links">
<li><a href="rsa.html">Algoritmo RSA</a></li>
<li><a href="cesare.html">Cesare</a></li>
<li><a href="vigenere.html">Vigenère</a></li>
<li><a href="team.html">Il Team</a></li>
</ul>
</nav>
<div></div>
<div class="container">
<h1>Welcome to CryptoSeals</h1>
<p class="descrizione">
Dive deep, Seal your data.<br>
<br><br>
<i>Click any tool in the bar on the right to start!</i>
</p>
<img src="/target/classes/seal1.png" alt="Mascotte CryptoSeals" style="max-width: 300px; border-radius: 20px; box-shadow: 0 10px 20px rgba(0,0,0,0.1);" onerror="this.style.display='none';">
</div>
<footer>
<div class="copyright">
<span>
<a href="/privacy-policy/">Privacy Policy</a> &nbsp;
</span>
<span>
© <span class="" data-timestamp="2026-03-26T11:39:53Z" data-function="format" data-format="YYYY" data-refresh="0">2026</span> CryptoSeals
</span>
</div>
</footer>
</body>
</html>

View File

@@ -1,168 +0,0 @@
/* Importiamo Inter per la massima leggibilità */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');
/* --- STILI BASE (DARK) --- */
body, h1, h2, p, ul, li { margin: 0; padding: 0; }
body {
font-family: 'Inter', system-ui, -apple-system, sans-serif;
background-color: #0c1221; /* Fondo quasi nero, molto profondo */
color: #f1f5f9; /* Testo chiaro ghiaccio */
padding-top: 100px;
-webkit-font-smoothing: antialiased; /* Rende il font più nitido su Mac */
}
footer {
display: flex;
flex-wrap: wrap;
flex-direction: row;
justify-content: space-between;
font-size: 0.85em;
position: absolute;
padding-top: 1rem;
z-index: 1050;
width: 100%;
margin-top: 3rem;
background: var(--color-bg-footer);
box-shadow: inset 0 2px 5px 0 rgba(0, 0, 0, 0.16),
inset 0 2px 10px 0 rgba(0, 0, 0, 0.12);
}
footer {
display: flex;
flex-wrap: wrap;
flex-direction: row;
justify-content: space-between;
font-size: 0.85em;
position: absolute;
padding-top: 1rem;
z-index: 1050;
width: 100%;
margin-top: 3rem;
background: var(--color-bg-footer);
box-shadow: inset 0 2px 5px 0 rgba(0, 0, 0, 0.16),
inset 0 2px 10px 0 rgba(0, 0, 0, 0.12);
}
footer .copyright {
display: flex;
flex-direction: row;
justify-content: space-between;
width: 100%;
margin-top: 2rem;
padding: 1.5rem 2em;
text-align: right;
border-top: 1px solid #ffffff10;
}
/* --- NAVBAR (EFFETTO VETRO SCURO) --- */
.navbar {
background-color: rgba(17, 24, 39, 0.8);
backdrop-filter: blur(12px); /* Effetto vetro sfocato */
position: fixed;
top: 0;
width: 100%;
height: 75px;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 40px;
box-sizing: border-box;
z-index: 1000;
border-bottom: 1px solid #1e293b;
}
.nav-brand { display: flex; align-items: center; gap: 12px; font-size: 24px; font-weight: 800; color: #f1f5f9; text-decoration: none; letter-spacing: -0.5px;}
.nav-brand span { font-size: 28px; color: #0688d4; /* Accento Ciano Ghiaccio */ }
.nav-links { list-style: none; display: flex; gap: 30px; }
.nav-links a { color: #94a3b8; text-decoration: none; font-weight: 500; font-size: 15px; transition: 0.2s;}
.nav-links a:hover, .nav-links a.active { color: #06b6d4; font-weight: 600; }
/* --- CONTENITORE CENTRALE --- */
.container { max-width: 1100px; margin: 0 auto 60px auto; padding: 20px; text-align: center; }
h1 { font-size: 48px; color: #f1f5f9; margin-bottom: 15px; font-weight: 900; letter-spacing: -1.5px; }
p.descrizione { font-size: 18px; color: #94a3b8; line-height: 1.6; margin-bottom: 50px; max-width: 700px; margin-left: auto; margin-right: auto;}
/* --- SCATOLA PRINCIPALE (MODERN DARK) --- */
.crypto-box {
background-color: #111827; /* Slate dark */
margin: 0 auto;
padding: 50px;
border-radius: 28px;
border: 1px solid #1e293b;
box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
text-align: left;
}
label { font-weight: 600; color: #94a3b8; font-size: 14px; margin-bottom: 10px; display: block; text-transform: uppercase; letter-spacing: 1px; }
/* Input, Select, Textarea (Modern Dark) */
textarea, select {
width: 100%;
padding: 18px;
border-radius: 14px;
border: 1px solid #1e293b;
background-color: #1f2937; /* Input leggermente più chiaro */
color: #f1f5f9;
font-family: 'Inter', system-ui, -apple-system, sans-serif;
font-size: 16px;
box-sizing: border-box;
transition: all 0.3s ease;
margin-bottom: 25px;
line-height: 1.6;
}
textarea:focus, select:focus { outline: none; border-color: #06b6d4; background-color: #111827; box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.15); }
textarea { height: 180px; resize: none; }
textarea::placeholder { color: #4b5563; }
/* --- DEFINIZIONE ANIMAZIONE PULSANTE --- */
@keyframes glitchPulse {
0% { border-color: #1e293b; box-shadow: 0 0 0 0 rgba(6, 182, 212, 0); }
50% { border-color: #06b6d4; box-shadow: 0 0 15px 2px rgba(6, 182, 212, 0.3); }
100% { border-color: #1e293b; box-shadow: 0 0 0 0 rgba(6, 182, 212, 0); }
}
/* Applichiamo l'animazione alla casella di input principale */
.pulse-textarea {
animation: glitchPulse 2.5s infinite ease-in-out; /* Pulsazione lenta e continua */
}
.pulse-textarea:focus {
animation: none; /* Smette di pulsare quando ci scrivi dentro */
}
/* --- LAYOUT A COLONNE --- */
.crypto-columns {
display: flex;
gap: 35px;
}
.crypto-col {
flex: 1;
display: flex;
flex-direction: column;
}
/* --- BOTTONI--- */
button {
background: linear-gradient(135deg, #0891b2, #06b6d4); /* Ciano Gradient */
color: #0b0f19;
border: none;
padding: 18px 25px;
font-size: 16px;
border-radius: 14px;
cursor: pointer;
transition: all 0.3s ease;
font-weight: 700;
width: 100%;
text-transform: uppercase;
letter-spacing: 1px;
}
button:hover { transform: translateY(-3px); box-shadow: 0 12px 25px rgba(6, 182, 212, 0.3); }
button:active { transform: translateY(-1px); }
/* Bottone Decifra (Verde Neon) */
.btn-green { background: linear-gradient(135deg, #059669, #10b981); color: #0b0f19;}
.btn-green:hover { box-shadow: 0 12px 25px rgba(16, 185, 129, 0.3); }
/* Responsive */
@media (max-width: 800px) {
.crypto-columns { flex-direction: column; gap: 0; }
}