Kryptographie (Passwort)

Hi Liste !! Ich habe da eine kleine Verständnisfrage: Wenn ein Passwort verschlüsselt ist (z.B. shadow) und man davon ausgeht, daß es Verschlüsselungsverfahren gibt, die nur schwer bzw. (momentan) gar nicht zu knacken sind, wie bekommt dann das System (z.B. bei Login-Passwort) das unverschlüsselte Passwort heraus ??? OK, ich könnte mir vorstellen, daß die Entschlüsselung o.ä. im Login-Programm enthalten ist, aber dann wäre sie doch (wegen Open-Source u.ä.) auch frei verfügbar - oder nicht !? Das gleiche ist ja auch bei z.B. EC-Karten der Fall. Glaubt man der Bank, so ist es für die Angestellten nicht möglich eine vergessene Geheimzahl nachträglich herauszufinden. Wie schafft es denn dann der Geldautomat herauszufinden, ob ich die korrekte Geheimzahl eingegeben habe ??? Dementrsprechend muß es doch auch (mehr oder weniger leicht) möglich sein, die Geheimzahl zu ermitteln, da es der Automat ja auch kann.... Oder befinde ich mich da vollkommen auf dem Holzweg ??? OK, klingt zwar etwas unprofessionell und laienhaft, aber das interresiert mich gerade irgendwie und es wäre nett, wenn mir da jemand eine qualifizierte und detailierte Antwort zu geben könnte. Vielen Dank im Voraus..... CU :-) Claudia

Hallo Claudia, das wichtigste zuerst: Diese Liste ist zwingend englisch-sprachig ! Bitte das nächste Mal in Englisch posten, okay ? Zu Deiner Frage: Das ganze funktioniert recht simpel. Das verwendete Verschlüsselungsverfahren ist nicht-reversibel, d.h. aus einem verschlüsselten Passwort kann nicht durch Entschlüsselung das Plaintext-Passwort herausbekommen werden. Sämtliche Testprogramme (wie z.B. der Login-Prozess) verschlüsselt das von Dir eingegebene Passwort und vergleicht das Ergebnis mit dem gespeicherten Schlüssel. Sind beide identisch, hast Du das richtige Passwort eingegeben (da es auch bei wiederholter Verschlüsselung jedesmal denselben Schlüssel ergibt). Stimmt es nicht überein..gut, dann stimmt Dein Passwort eben nicht. Genauso arbeiten Passwort-Cracker. Sie verschlüsseln Plaintext-Passwörter (zumeist aus einem Wörterbuch heraus, in welchem die statistisch am häufigsten verwendeten Passwörter gespeichert sind, also Vornamen, Automarken, bestimmte englische Begriffe, etc) und vergleichen den erhaltenen Schlüssel mit einer Shadow-Datei. Stimmt irgendwo etwas überein--Bingo. Ein LogIn ist geknackt. Wie das mit Bankautomaten funktioniert, weiss ich nicht. Vielleicht ein anderer aus der Liste ??? Ich hoffe, Dir weitergeholfen zu haben. Gruß Stephan For all non-german readers: The question was about cryptography and how it works. I explained that all plaintext-PWs (entered at login, f.ex.) are encrypted and are compared to the concerned entry in the shadow-file. This also is the way password-crackers work. Cracker-progs choose pws out of a list containing the most-often used passwords, encrypt them, and compare it with entries in a given shadow-file. I don't know if an ATM works the same way or, if not, how exactly it works. Maybe anyone else on this list can assist ? --- -------------------------------------------- Stephan M. Ott // OKDesign oHG Internet-Providing und Netzwerkmanagement smo@okdesign.de ..... http://www.okdesign.de fon. +49 961 3814139 .. fax. +49 961 3814140 mobil 0171-8351130 ... oder ... 0171-7858064 --------------------------------------------
-----Ursprüngliche Nachricht----- Von: Claudia Arnold [mailto:AClaudia@gmx.net] Gesendet: Sonntag, 31. Dezember 2000 13:11 An: suse-security@suse.com Betreff: [suse-security] Kryptographie (Passwort)
Hi Liste !!
Ich habe da eine kleine Verständnisfrage:
Wenn ein Passwort verschlüsselt ist (z.B. shadow) und man davon ausgeht, daß es Verschlüsselungsverfahren gibt, die nur schwer bzw. (momentan) gar nicht zu knacken sind, wie bekommt dann das System (z.B. bei Login-Passwort) das unverschlüsselte Passwort heraus ??? OK, ich könnte mir vorstellen, daß die Entschlüsselung o.ä. im Login-Programm enthalten ist, aber dann wäre sie doch (wegen Open-Source u.ä.) auch frei verfügbar - oder nicht !?
Das gleiche ist ja auch bei z.B. EC-Karten der Fall. Glaubt man der Bank, so ist es für die Angestellten nicht möglich eine vergessene Geheimzahl nachträglich herauszufinden. Wie schafft es denn dann der Geldautomat herauszufinden, ob ich die korrekte Geheimzahl eingegeben habe ??? Dementrsprechend muß es doch auch (mehr oder weniger leicht) möglich sein, die Geheimzahl zu ermitteln, da es der Automat ja auch kann.... Oder befinde ich mich da vollkommen auf dem Holzweg ???

Hi, please note that this list is english language. On Sun, Dec 31, Claudia Arnold wrote:
Ich habe da eine kleine Verständnisfrage:
Wenn ein Passwort verschlüsselt ist (z.B. shadow) und man davon ausgeht, daß es Verschlüsselungsverfahren gibt, die nur schwer bzw. (momentan) gar nicht zu knacken sind, wie bekommt dann das System (z.B. bei Login-Passwort) das unverschlüsselte Passwort heraus ???
Not at all. The encrypted password is never decrypted. The login program just encrypts the password you just entered and compares the result with the stored (encrypted) password. If they match, the password was ok.
CU :-) Claudia -o) Hubert Mantel Goodbye, dots... /\\ _\_v

Please note: this is an english list. I'll try to translate. Claudia: wenn Du kein englisch kannst, forwarde mir diese Mail nochmal, ich werde sie dann wieder ins deutsch übersetzen. * Claudia Arnold wrote on Sun, Dec 31, 2000 at 13:11 +0100:
Wenn ein Passwort verschlüsselt ist (z.B. shadow) und man davon ausgeht, daß es Verschlüsselungsverfahren gibt, die nur schwer bzw. (momentan) gar nicht zu knacken sind, wie bekommt dann das System (z.B. bei Login-Passwort) das unverschlüsselte Passwort heraus ???
The question: If a encrypted password is difficult to crack, how knows the system the unencrypted password (i.e. at the login prompt)? Answer: The system don't know the cleartext password. A encrypted password is stored. At login, you enter the cleartext password. That password gets encrypted in the same way like the stored became encrypted. Now the both encrypted values are compared. If they are equal, the entered cleartext password were the same as the cleartext of the stored.
OK, ich könnte mir vorstellen, daß die Entschlüsselung o.ä. im Login-Programm enthalten ist, aber dann wäre sie doch (wegen Open-Source u.ä.) auch frei verfügbar - oder nicht !?
Quenstion: I could imagine that the decryption is included in some login program, but since it's open source everybody could use it, ain't? Answer: See above, it's not neccesary to decrypt the password. Anyway, the algorihtms to crack passwords are known to the public, but it's take a long time to crack a (good) password, but's not impossible. The needed time depends on uses environment and used password encryption (or hash) algorithm of course.
Das gleiche ist ja auch bei z.B. EC-Karten der Fall.
The same with EC-cards.
Glaubt man der Bank, so ist es für die Angestellten nicht möglich eine vergessene Geheimzahl nachträglich herauszufinden.
According to bank, it's impossible to retrieve a forgotten PIN.
Wie schafft es denn dann der Geldautomat herauszufinden, ob ich die korrekte Geheimzahl eingegeben habe ???
But how the cash automate knows if I entered the correct PIN? Answer: In general, there are two possibilities: offline and online verification. Offline verification could be done in such a way: The pin number is calculated by the data stored on the card, and is encrypted by a secret key. The automate contains a hardware security module which contains the key in a safe way (i.e. it's impossible to read out that key, even with tricks). The automate could use that module to recalculate the PIN and check if it's match. The second if online verification. The automate uses a phone line to transfer the PIN to some serversystem and gets a positive or negative response (of course the transfer is encrypted, too). The serversystems knows about all the keys and is able to verify the PIN. This requires a online-link of course. In germany, all cash automates use online-verification to archive maximum security.
Dementrsprechend muß es doch auch (mehr oder weniger leicht) möglich sein, die Geheimzahl zu ermitteln, da es der Automat ja auch kann....
Question: then it should be possible to calculate the PIN, since the automate is able to do it. Answer: It's possible, but only if you have the secret key used for calculating the PIN. And that secret keys are secret. Even if you steal a hardware-security-module, you won't be able to retrive the keys, since the module destroys itself if it detects some attacks (i.e. magnetic fields and so on). So you will not get the key --> you will not be able to calculate the PIN.
Oder befinde ich mich da vollkommen auf dem Holzweg ???
Question: Or I am wrong? Answer: yes ;) oki, Steffen -- Dieses Schreiben wurde maschinell erstellt, es trägt daher weder Unterschrift noch Siegel.

On Sun, Dec 31, 2000 at 13:11 +0100, Claudia Arnold wrote:
Ich habe da eine kleine Verständnisfrage:
Stimmt. Die Mailingliste nutzt Englisch als "Amtssprache". :) Und vor dem Schreiben eine Weile mitzulesen oder in Archiven zu wuehlen hilft auch eine Menge. Dann stoesst Du auf Literaturlisten, FAQs, etc und koenntest Dir selbst noch schneller helfen als auf Antworten warten zu muessen (die nicht einmal stimmen muessen).
Wenn ein Passwort verschlüsselt ist (z.B. shadow) und man davon ausgeht, daß es Verschlüsselungsverfahren gibt, die nur schwer bzw. (momentan) gar nicht zu knacken sind, wie bekommt dann das System (z.B. bei Login-Passwort) das unverschlüsselte Passwort heraus ???
[ short translation: How will the system determine the clear text password at login / auth time to compare it against the given one when it's stored in encrypted form? ] Well, when you login (or do auth in some other context) the password you provide won't get compared against its original form. It just gets processed the same way as it got processed when you initially set it up and stored it. The assumption is that given the same input (your password) as well as the same algorithm (plus some initial state like SALT or stuff) will result in the same crypted representation. And of course that any deviation in the input (read: a wrong password or different state - think of S/Key - ) will lead to a different result and thus will mismatch. Since the password crypt algorithm is not reversible, the only (technical) form of getting the cleartext equivalent or an successful auth is to use brute force in an enormous trial and error loop. Doing this against a live login(8) program will be almost useless due to the delay every unsuccessful attempt will cause. To add to this every attempt gets logged and will raise some attention. Having access to the encrypted form will give the chance to do this brute force run "off line" and unnoticed. That's the most important motivation to move this field from /etc/passwd to /etc/shadow, where you can set more restictive access parameters. But when you don't protect those sensitive files ... Another method being even more promising is social engineering: What's the cat's birthday? How is the dog named? What's the most favourite word people use? When did they marry? etc pp There's no substitute for thinking and no technical means can solve problems caused by human laziness or even stupidity ...
Das gleiche ist ja auch bei z.B. EC-Karten der Fall. Glaubt man der Bank, so ist es für die Angestellten nicht möglich eine vergessene Geheimzahl nachträglich herauszufinden. Wie schafft es denn dann der Geldautomat herauszufinden, ob ich die korrekte Geheimzahl eingegeben habe ???
[ The bank makes me believe their stuff has no means of getting my PIN back in case I forgot. How does the cash money automat(id?) prove my PIN to be correct? ] The cheque card is quite another topic. Although there are four digits leading to a problem space of 1000 combinations in theory, in practice it's only some 150. And still the clear text password is not stored on the card, but a crypted form thereof. In this particular case the bank believes the algorithm to be secure because "(almost) nobody knows it" -- that's "security by obscurity" and leads to a false sense of security. That's even more dangerous and plain doesn't work, as you can read a few thousand times in the archives. Your only hope / chance is that the card gets blocked after three wrong attempts which makes brute forcing inappropriate, and that the algo really is a secret and will remain so. This should suffice for the risk of loosing "a little money". Unless you write down the password (PIN) on a piece of paper right next to the card or tell it to everyone to ask you. Or even scribble the PIN on the card itself. That's the "Think!" thing, again, see above ... virtually yours 82D1 9B9C 01DC 4FB4 D7B4 61BE 3F49 4F77 72DE DA76 Gerhard Sittig true | mail -s "get gpg key" Gerhard.Sittig@gmx.net -- If you don't understand or are scared by any of the above ask your parents or an adult to help you.
participants (5)
-
Claudia Arnold
-
Gerhard Sittig
-
Hubert Mantel
-
OKDesign oHG Security Webmaster
-
Steffen Dettmer