Live data from Hacker News

Crypto 101 – Introductory course on cryptography

crypto101.io

81–90 of 148 posts

Re: Crypto 101 – Introductory course on cryptography

#81

Can any crypto people here on HN verify that this gets it right?

A nitpick: When discussing hash function properties (p. 111), his definition of property #1 ("[it should be hard to] modify a message without changing the hash") is, to me, equivalent to second-preimage resistance ("[Given] a message m, it should be difficult to find another message m' with the same hash"), which he discusses as a separate property under prop #3.

In the explanation of prop #1, he makes it clear that he is talking about the "avalanche effect," so it might be better to say that explicitly in the definition.

Disclaimer: I'm not a crypto person, so it's better if the author comments on this as well.

I think the book is great, by the way, especially the writing style and the choice of what to focus on. Thanks, lvh, for doing this.

Re: Crypto 101 – Introductory course on cryptography

#82
post #26

When I was taking Aikido, there was a day when the sensei was going through all of our techniques and showed how the uke (initiator of the attack, receiver of the technique) could turn things around on the tori . (receiver of the attack, initiator of the technique) It seemed like there were a half dozen ways each that a technique could go seriously wrong, and that many of them didn't require much skill, only determin…

This is slightly tangential since you specified a conspirator on the inside, but how easy is it to break a homegrown encryption algorithm if you don't have the source code? I assume there are tools (what are they?) that will break a simple caesar cipher if you have more than a sentence or so of plain text to work with. But if you strung together 2-3 broken algorithms and your attacker doesn't know which ones, is it s…

I've seen a few fun articles about people breaking home grown encryption. The question is mostly about how motivated someone might be to find a problem.

Making a secure encryption algorithm requires a lot of presence of mind, and a lot of industry knowledge. If your threat model is incomplete, you lose. If you forgot one tiny thing at one tiny point in the algorithm, you lose.

If you don't have people checking your work, how do you know? If someone is determined to break your encryption, they are capable of spending a lot more time analyzing it than you spent building it. And they only need to find one mistake.

It's definitely better to use the tools that experts have spent lots of time, lots of breadth of knowledge, and lots of depth of knowledge inspecting.

Re: Crypto 101 – Introductory course on cryptography

#83

When I was taking Aikido, there was a day when the sensei was going through all of our techniques and showed how the uke (initiator of the attack, receiver of the technique) could turn things around on the tori . (receiver of the attack, initiator of the technique) It seemed like there were a half dozen ways each that a technique could go seriously wrong, and that many of them didn't require much skill, only determin…

There are penetration testing classes, but doubt that they are bundled together with classical CS, thought never know what some uni or courses may add. And there are project like those for practicing, few pointers:

- https://sourceforge.net/projects/metasploitable/

- https://github.com/ethicalhack3r/DVWA

- https://www.vulnhub.com/

If you go this direction you will find much more applications prepared for Capture The Flag competitions. Some people are even posting walk-throughs how to hack and fix them. It is very interesting & hard.

Re: Crypto 101 – Introductory course on cryptography

#84

Why is the url a hash? Also I'm getting privacy error on chrome mobile. Thanks for this, seems pretty useful.

Hi! I'm the author. It's hosted on a CDN; I don't choose that URL. Sorry about the privacy error; could you take a screenshot and submit a ticket on https://www.github.com/Crypto101/book? Thanks!

Re: Crypto 101 – Introductory course on cryptography

#85
post #79
post #77

Whenever I have taken the small amount of cryptography knowledge I already have and tried to use it in a project, I've often been shutdown with "the system already does that" when it doesn't, or "this will be too complicated for the user, instead lets just roll our own [ad-hoc cryptography method]". For those reading: How do you convince people that it's worth using best practices? Is there a good heuristic to measur…

For normal application work, you should use NaCL (or it's repackaged version, libsodium) to the exclusion of all else.

Why the hell is this being downvoted?

Re: Crypto 101 – Introductory course on cryptography

#86
Maybe I am being too harsh, but it is clear the author does not have a formal education in the subject [0] nor any track in breaking non-toy crypto implementations [1]. This alone makes me a bit wary of any recommendation one may read in the material.

There seems to be more attention to listing all the beasts in the cryptographic zoo than to the few fundamental tools required to really understand the mechanics (e.g. birthday paradox, PRFs, some prime number theory).

Sure, I can't spot anything fundamentally wrong and it all reads pretty smoothly, but calling this a "course" is highly misleading. If the intention is to guide people in selecting good crypto primitives, then maybe "guide" is a more honest word?

For those interested, I would strongly recommend to bite the bullet and dedicate time to Boneh's course on Coursera.

[0] I don't have any either [1] Ditto

Re: Crypto 101 – Introductory course on cryptography

#87

Maybe I am being too harsh, but it is clear the author does not have a formal education in the subject [0] nor any track in breaking non-toy crypto implementations [1]. This alone makes me a bit wary of any recommendation one may read in the material. There seems to be more attention to listing all the beasts in the cryptographic zoo than to the few fundamental tools required to really understand the mechanics (e.g.…

lvh (https://lvh.io), care to weigh in?

I was under the impression he was formally educated in cryptography.

This ebook has been cited by many computer security university courses.

Re: Crypto 101 – Introductory course on cryptography

#88

Maybe I am being too harsh, but it is clear the author does not have a formal education in the subject [0] nor any track in breaking non-toy crypto implementations [1]. This alone makes me a bit wary of any recommendation one may read in the material. There seems to be more attention to listing all the beasts in the cryptographic zoo than to the few fundamental tools required to really understand the mechanics (e.g.…

Hi! I'm the author. You're mistaken about [0] and [1]. I'd like to address your specific point about being a guide rather than a course. I agree that a crypto zoo would be a guide and not a course; although I disagree that either the book or the talk are a zoo. It's possible that that hasn't come through effectively enough. I could understand why someone might think that from looking at the table of contents for example; it's certainly a lot clearer in the talk. The approach is instead to walk someone through the kinds of primitives that exist, but more importantly, why they exist. In that context, when I say "primitive", I mean "block cipher" or "MAC"; not something like "AES". That includes incidentally talking about PRFs, although I dance around that term and use terminology they're going to find in their crypto libraries. Similarly, there's an appendix on modular arithmetic; but I try not to get too lost in proofs about group theory.

I could say "IND-CCA2" with a formal description, but in my experience that makes people's eyes glaze over. It's a lot easier to show them a bunch of reasonably-looking-yet-fatally-broken unauthenticated encryption to drive the point home. My target audience is curious programmers, not new academic cryptographers. If that's your criticism, that's absolutely valid. If you want to be the person to design SHA-4; this book isn't for you.

It's true that I take a different approach than Dan Boneh does. That's not a criticism: Boneh's course is great, it's just different. I think showing people how to break stuff is a useful educational tool. If your threat model is random web apps that have the letters "AES" or "MD5" in their code, I think it's a more effective one than a rigorous mathematical approach that will quickly dissuade the curious programmer.

Re: Crypto 101 – Introductory course on cryptography

#90

Earlier quoted context omitted.

Ciphers aren't the place where security most often fails. The failures have to do with implementation. More commonly, they have to do with implementation of protocols and systems using the protocols.

I agree, but I replied to someone who talked about ciphers.

Of course. I was also (mainly) posting for the benefit of 3rd parties.
Post reply on HN