Κρυπτογραφική επιτάχυνση με GPU

datacite.contributor.RelatedPersonΣκλάβος, Νίκος
datacite.contributor.RelatedPersonΝικολετσέας, Σωτήρης
datacite.contributor.SupervisorΒλάχος, Κυριάκος
dc.contributor.authorΡάικος, Ιάσων
dc.contributor.otherRaikos, Iason
dc.date.accessioned2026-06-30T09:37:40Z
dc.date.available2026-06-30T09:37:40Z
dc.date.issued2026-06-30
dc.degreegraduateThesis
dc.description.abstractΟι κρυπτογραφικές λειτουργίες αποτελούν θεμέλιο κάθε σύγχρονης ασφαλούςεπικοινωνίας (HTTPS, VPN, ασφαλή συστήματα ανταλλαγής μηνυμάτων), αλλά είναι υπολογιστικά δαπανηρές. Σε διακομιστές υψηλής κίνησης, που εξυπηρετούν χιλιάδες ταυτόχρονες ασφαλείς συνδέσεις, η κρυπτογραφία μπορεί να καταναλώνει σημαντικό μέρος των πόρων της CPU και να μετατρέπεται σε σημείο συμφόρησης (bottleneck).Στην παρούσα διπλωματική εργασία υλοποιούμε σε CUDA τέσσερις βασικές οικογένειες κρυπτογραφικών αλγορίθμων, τον συμμετρικό αυθεντικοποιημένο αλγόριθμο AES-GCM, τον ChaCha20-Poly1305, τον ασύμμετρο RSA και κρυπτογραφία Ελλειπτικών Καμπυλών (ECC, συγκεκριμένα X25519 για ανταλλαγή κλειδιών και Ed25519 για ψηφιακές υπογραφές) και τις εκτελούμε μαζικά παράλληλα στη GPU. Για τους ασύμμετρους αλγορίθμους η αριθμητική πολλαπλής ακρίβειας υλοποιείται από εμάς εξ ολοκλήρου σε CUDA, χωρίς εξωτερική βιβλιοθήκη big-number, με το μοντέλο «μία κρυπτογραφική λειτουργία ανά νήμα» (one operation per thread) και μαζική παράλληλη εκτέλεση πολλών ανεξάρτητων λειτουργιών.Συγκρίνουμε τη ρυθμοαπόδοση (throughput) των υλοποιήσεών μας στη GPU με τις αντίστοιχες, εξαιρετικά βελτιστοποιημένες υλοποιήσεις CPU της βιβλιοθήκης OpenSSL (η οποία αξιοποιεί εντολές AES-NI). Η μεθοδολογία μέτρησης διαχωρίζει τον «καθαρό» χρόνο υπολογισμού στη GPU από τον συνολικό χρόνο του διοχετευτικού αγωγού (pipeline) που περιλαμβάνει τις μεταφορές μέσω PCIe, ενώ η ορθότητα κάθε υλοποίησης επαληθεύεται με επίσημα δοκιμαστικά διανύσματα και known-answer tests.Τα αποτελέσματα δείχνουν ότι, για τους συμμετρικούς αλγορίθμους, ο καθαρός υπολογισμός της GPU είναι έως ~4.3× ταχύτερος για ChaCha20-Poly1305 και ~1.3× για AES-GCM σε μεγάλα σύνολα δεδομένων, αλλά η ρυθμοαπόδοση στους δύο αυτούς από άκρο σε άκρο περιορίζεται από τη μεταφορά PCIe και παραμένει κάτω από εκείνη μιας πολυνηματικής CPU με AES-NI. Αντίθετα, στις ομαδοποιημένες (batched) λειτουργίες RSA/ECC η GPU αποδίδει έως ~15× για επαλήθευση Ed25519, ~10× για X25519, ~9.5× για υπογραφή Ed25519 και ~6× για κρυπτογράφηση RSA-2048, με τηναποκρυπτογράφηση RSA-2048 στο ~1.6×. Καταλήγουμε ότι η μεταφόρτωση (offloading) κρυπτογραφικών υπολογισμών στη GPU είναι βιώσιμη στρατηγική για φόρτους εργασίας υψηλής ρυθμοαπόδοσης, και σκιαγραφούμε μια αρχιτεκτονική «ομαδοποίησης-καιμεταφόρτωσης» για συστήματα όπως VPN ή ασφαλή συστήματα μηνυμάτων.
dc.description.translatedabstractCryptographic functions are the foundation of all modern secure communications (HTTPS, VPN, secure messaging systems), but they are computationally expensive. On high-traffic servers that handle thousands of concurrent secure connections, cryptography can consume a significant portion of CPU resources and become a bottleneck.In this thesis, we implement four basic families of cryptographic algorithms in CUDA, the symmetric authenticated AES-GCM algorithm, ChaCha20-Poly1305, the asymmetric RSA algorithm, and Elliptic Curve Cryptography (ECC, specifically X25519 for key exchange and Ed25519 for digital signatures) and we execute them in parallel on the GPU.For asymmetric algorithms, we implement multi-precision arithmetic entirely in CUDA, without an external big-number library, using the “one cryptographic operation per thread” model and mass parallel execution of many independent operations.We compare the throughput of our GPU implementations with the corresponding, highly optimized CPU implementations from the OpenSSL library (which utilizes AES-NI instructions). The measurement methodology distinguishes the “pure” computation time on the GPU from the total pipeline time, which includes transfers via PCIe, while the correctness of each implementation is verified using official test vectors and known-answer tests.The results show that, for symmetric algorithms, the net GPU “pure” computation is up to ~4.3× faster for ChaCha20-Poly1305 and ~1.3× faster for AES-GCM on large datasets but the end-to-end throughput for both is limited by the PCIe bus and remains below that of a multithreaded CPU with AES-NI. In contrast, for batched RSA/ECC operations, the GPU delivers up to ~15× for Ed25519 verification, ~10× for X25519, ~9.5× for Ed25519 signing, and ~6× for RSA-2048 encryption, with RSA-2048 decryption at ~1.6×. We conclude that offloading of cryptographic computations to the GPU is a viable strategy for high-throughput workloads, and we outline a “cluster-and-offload” architecture for systems such as VPNs or secure messaging systems.
dc.identifier.urihttps://hdl.handle.net/10889/32150
dc.language.isoel
dc.rightsAttribution-NonCommercial-ShareAlike 3.0 Greeceen
dc.rights.urihttp://creativecommons.org/licenses/by-nc-sa/3.0/gr/
dc.subjectΚρυπτογραφική επιτάχυνση
dc.subject.alternativeCryptographic acceleration
dc.subject.alternativeGPU
dc.subject.alternativeCUDA
dc.subject.alternativeAES-GCM
dc.subject.alternativeChaCha20-Poly1305
dc.subject.alternativeRSA
dc.subject.alternativeECC
dc.subject.alternativeX25519
dc.subject.alternativeEd25519
dc.subject.alternativeThroughput
dc.subject.alternativeOpenSSL
dc.subject.alternativeBatching
dc.titleΚρυπτογραφική επιτάχυνση με GPU
dc.title.alternativeCryptographic acceleration with GPU

Files

Original bundle
Now showing 1 - 2 of 2
Loading...
Thumbnail Image
Name:
Thessis.pdf
Size:
2.13 MB
Format:
Adobe Portable Document Format
No Thumbnail Available
Name:
Codes.zip
Size:
150.52 KB
Format:
Unknown data format
License bundle
Now showing 1 - 1 of 1
No Thumbnail Available
Name:
license.txt
Size:
5.02 KB
Format:
Item-specific license agreed upon to submission
Description: