62
SSN Security of Systems and Networks Deel 1 Traditionele Crypto 29 Oktober 2007

Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

SSN

Security of Systems and Networks

Deel 1 Traditionele Crypto29 Oktober 2007

Page 2: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Evaluatie

● DIA en ESA....

Page 3: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Dit blok● Maandag en Donderdag

– Security of Systems and Networks SSN– Jaap van Ginkel

● Dinsdag en Woensdag– CIA Classical Internet Applications– Karst Koymans

● Donderdag 16:00 evaluatie● Woensdag

– Colloquia/Uitloop practicum

Page 4: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Praktica

● Eelco Schatborn● Voortgang in logboek bijhouden !● Werk samen in varierende samenstelling● Eigen inzet is nodig

Page 5: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Boek

● Basis tentamen

Page 6: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

WIKI

● www.os3.nl

Page 7: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Machinerie● Dell 850's achter in het rack● Via de 4 consoles● Niet werken in serverruimte !● Multiboot (opzetten bij CIA)● Linux (opzetten bij CIA)● Windows 2003 server (opzetten bij SSN)● Tweede netwerkinterface activeren

Page 8: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Windows 2003 Server

● Voldoende diskruimte● CD en Key via Jaap/Eelco blijft binnen lab !● Codebook CD● Openoffice (www.openoffice.org)● Wireshark (www.wireshark.com)● Geen DC ● Gebruik DHCP● Naamgeving en adressering !

Page 9: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Eigen Bijdrage

● “Gevorderden”● Aanmelden bij Jaap● Passend in programma

Page 10: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Gastdocenten● Karst Koymans Crypto Wiskunde● Rop Gongrijp Stemmachines● Jan Meijer Internetstemmen● Teun Nijssen PKI● Pieter de Boer Bufferoverflows● Leo Willems Social Engineering● Harko Robroch Smartcards● Jeroen van Beek Bluetooth RFID Oracle● Flexibel programma

Page 11: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

HUISREGELS

● Jaap– Je mag werken op je Mac– Je moet aanwezig zijn

● Gastdocenten– Stel (kritische) vragen– Blijf beleefd– Je mag je Mac niet gebruiken– Je moet aanwezig zijn

Page 12: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Tentamen

● Mogelijk open boek● Save a tree today● Geen electronische hulpmiddelen● Ook gastcollege's en additionele stof

Page 13: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Beoordeling

● Praktica: Voorwaarde voor cijfer● Project: 30%● Tentamen: 70 %

Mogelijk:● Peer review● Bijdragen

Page 14: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Film

● Facultatief● Donderdag 16:30 ?● Suggesties

– Enigma– Catch me if you can– A beautiful mind– Sneakers– Breaking the code

Page 15: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Programma SSN

Page 16: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Inleiding en Tools

– Protocolanalyse– Werkende machines

Page 17: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Crypto Historie

– Cryptologie– Ceasar Substitutie– Vigenère – Frequency analyse– Enigma

Page 18: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Crypto Wiskunde– Number Theory

● Primes● Euler

– Elyptical curves – Rainbow tables– Gastdocent Karst Koymans

Page 19: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Wachtwoorden– Kraken

● John● Distributed cracking● Rainbow tables● Hashes

Page 20: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Moderne Crypto– Crypto theorie

● RSA● AES/Rijndael

– Hashes● MD4/MD5/SHA-1● DES/IDEA/AES

– Public key● RSA/Diffie Hellman

Page 21: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Praktische security

– Firewalls– Wrappers– Port knocking– SSH SCP– LDAP– Windows– Unix– Mac

Page 22: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Authenticatie

– AuthN/Authz– SSO– Kerberos– A-Select– Shibboleth– Biometrie

Page 23: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Social Engineering

– De zachte kant– Mogelijk Gastdocent Leo Willems (TUNIX)

Page 24: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

SSL/TLS

– Versies– Ciphers– Implementatie– MITM

Page 25: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Draadloos● Wireless Security

– 802.11...– WEP– WPA/WPA2– EduRoam

● Bluetooth Security– Tracing

● RFID– Privacy

Page 26: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Smartcards– Javacard– GSM, RSA– OpenPGPcard– Gastdocent Marc Witteman (Riscure)

Page 27: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Email security– PGP– S/MIME

Page 28: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

PKI

– Public key crypografie– Trustmodels– Revocation– Keymanagement– TinyCA– Gastdocent Teun Nijsen (UvT Ticer)

Page 29: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

IP-SEC

– IKE/Skip– Praktische implementaties

Page 30: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Traditionele Crypto

Page 31: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Cryptology●Cryptography

● Greek kryptós, "hidden", and gráphein, "to write"●Cryptanalysis

● Greek kryptós, "hidden", and analýein, "to loosen" or "to untie")

Page 32: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Begrippen● Een cipher of cryptosystem wordt gebruikt om de

plaintext versleutelen● Het resultaat is ciphertext ● Een decrypt geeft de plaintext● Een sleutel is de configuratie van de cipher

Page 33: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

33

In een schema

plaintext

keykey

plaintext

ciphertext

encrypt decrypt

Page 34: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Cryptography

● Confidentiality● Integrity● Authentication● Non-repudiation● Anti-replay● Proof of delivery

Page 35: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Cryptography

Page 36: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Auguste Kerckhoffs● “A cryptosystem

should be secure even if everything about the system, except the key, is public knowledge”

● Claude Shannon "the enemy knows the system"

● No Security by obscurity

Page 37: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

37

Claude Shannon● Grondlegger Information Theory● Confusion and diffusion

– Confusion obscure relationship between plaintext and ciphertext

– Diffusion spread plaintext statistics through the ciphertext

– Bewees dat one-time secure is.

Page 38: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Roept u maar

● QNNE FGNNG URYRZNNY AVXF● Vx mvr urg abt avrg

Page 39: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

ROT-13

Page 40: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves
Page 41: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves
Page 42: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves
Page 43: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Pigpen

Page 44: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Vrijmetselaars

Page 45: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Sherlock Holmes● Wie wil er als eerste antwoord geven ?

Page 46: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Monoalphabetic substitution● Zeg het maar:

OK YOX QA WOQNWXOJK YWX WWQM KBPPOW VDNNWQ RW UDDH WWQ XWKKWHW OFDXODDQMW HOMFHWFFB UDDH VWXDDM YW UBWFWQ VWF NBWQ UWF KBPPOW AOF NW DAFBUDDF

Page 47: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

ROT-13

Page 48: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

ROT-13/CEASAR● Maar 26 mogelijkheden!● Exhaustive key search duur miliseconden● Obfuscation● Hoe beter ?

Page 49: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Substitutie

● 26 ! meer dan 2^88 mogelijkheden● Exhausitive search duurt millenia● Dus veilig ?

Page 50: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Al-Kindi

● أبو يوسف يعقوب ابن إسحاق الكندي ● Abū-Yūsuf Ya’qūb ibn Ishāq al-Kindī (c. 801–

873 CE)

Page 51: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

51

Cryptanalyse● Onmogelijk om alle 288 keys te doorzoeken● Is er een betere methode ?● Frequentie analyse !

Page 52: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Frequency analysis

● Taalafhankelijk● Langere teksten● Letters ● Paren van letters ● Volgorde van letters

Page 53: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

53

Cryptanalysis: Terminology

● Een cryptosystem is secure als de enige aanval een “exhaustive search “

● Een cryptosystem is insecure als er een vereenvoudiging bekend is

● Insecure kan soms veiliger zijn dan secure

Page 54: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

54

Double Transposition● Plaintext: attackxatxdawn

Permute rowsand columns

⇒ Ciphertext: xtawxnattxadakc Key: matrix size and permutations

(3,5,1,4,2) and (1,3,2)

Page 55: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

55

Codebook● Letterlijk, een boek met “codewords”● Zimmerman Telegram encrypted met codebook

Februar 13605fest 13732finanzielle 13850folgender 13918Frieden 17142Friedenschluss 17149

: :

Page 56: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

56

ZimmermanTelegram

Page 57: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

57

ZimmermanTelegramcleartext

Page 58: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Book crypto● Beale● Drie delen alleen II is ontcijferd● 115, 73, 24, 807, 37, 52, 49, 17, 31, 62, 647, 22, 7, 15, 140, 47, 29, 107, 79, 84, 56, 239, 10, 26,

811, 5, 196, 308, 85, 52, 160, 136, 59, 211, 36, 9, 46, 316, 554, 122, 106, 95, 53, 58, 2, 42, 7, 35, 122, 53, 31, 82, 77, 250, 196, 56, 96, 118, 71, 140, 287, 28, 353, 37, 1005, 65, 147, 807, 24, 3, 8, 12, 47, 43, 59, 807, 45, 316, 101, 41, 78, 154, 1005, 122, 138, 191, 16, 77, 49, 102, 57, 72, 34, 73, 85, 35, 371, 59, 196, 81, 92, 191, 106, 273, 60, 394, 620, 270, 220, 106, 388, 287, 63, 3, 6, 191, 122, 43, 234, 400, 106, 290, 314, 47, 48, 81, 96, 26, 115, 92, 158, 191, 110, 77, 85, 197, 46, 10, 113, 140, 353, 48, 120, 106, 2, 607, 61, 420, 811, 29, 125, 14, 20, 37, 105, 28, 248, 16, 159, 7, 35, 19, 301, 125, 110, 486, 287, 98, 117, 511, 62, 51, 220, 37, 113, 140, 807, 138, 540, 8, 44, 287, 388, 117, 18, 79, 344, 34, 20, 59, 511, 548, 107, 603, 220, 7, 66, 154, 41, 20, 50, 6,

● I have deposited in the county of Bedford about four miles from Bufords in an excavation or vault six feet below the surface of the ground the following articles belonging jointly to the parties whose names are given in number three herewith. The first deposit consisted of ten hundred and fourteen pounds of gold and thirty eight hundred and twelve pounds of silver deposited Nov eighteen nineteen. .....

Page 59: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Frequentie tabellen

English: ETAONIRSHLDCUPFMWYBGVKQXJZ Dutch: ENIARDTOGLSHVRMUWJBZCPFXYQ Esperanto: AIEONSLTRJUKMPDGCVBFZHQWXY French: EANRSITUOLDCMPVBFGHQJZXY German: ENIRSADTUGHOLBMCWFKVZPJQXY Interlingua: EAILNOSTRUDCMPVGBFHXQJWYZK Italian: EAIOLNRTSCDMPUVGZFBHQ Latin: IEUTAMSNRODLVCPQBFGXHJKWYZ Portuguese: EAOSIDRTNCPUMLVFGQHJXZBKWY Spanish: EAOSRNIDLCTUMPGWBQVHFZ Swedish: AENRTSIOMGKLDVFBCHPUYJXQWZ

Page 60: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Tabel ?

TUVWXYZKOFIEABCDGHJLMNPQRSHJLMNPQRSTUVWXYZKOFIEABCDGEABCDGHJLMNPQRSTUVWXYZKOFIEABCDGHJLMNPQRSTUVWXYZKOFITUVWXYZKOFIEABCDGHJLMNPQRSHJLMNPQRSTUVWXYZKOFIEABCDGEABCDGHJLMNPQRSTUVWXYZKOFIEABCDGHJLMNPQRSTUVWXYZKOFITUVWXYZKOFIEABCDGHJLMNPQRSHJLMNPQRSTUVWXYZKOFIEABCDGEABCDGHJLMNPQRSTUVWXYZKOFIEABCDGHJLMNPQRSTUVWXYZKOFITUVWXYZKOFIEABCDGHJLMNPQRSHJLMNPQRSTUVWXYZKOFIEABCDG

Page 61: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Di-Graph tabel

Page 62: Security of Systems and Networks Deel 1 …...– Ceasar Substitutie – Vigenère – Frequency analyse – Enigma Crypto Wiskunde – Number Theory Primes Euler – Elyptical curves

Polyalphabetical Substitution● Wie het weet mag het zeggen● ICHAQBEZQPJIOYAWFADVNBRNVKNGBHC

SGPNJYFQZJOLWGIBNXSKIVCVSCIBFGCELOBBGAMCBQWIMHBEOEMJFYBNJURMVNVLRKHPZJPUWAOCUSGVCBRDVRMWTVWFPUNXUHIPRKBQIUBDCSZNCOOGARQSRZITRCCZMVVCHNSNFDVBCPUSFRIUYIKBCUQVWXMCUKHPWOSOSAWFNBSYIRGKZVIWPYTSMNNXRAWCNLFVBRFRQBNORO