How WanaCrypt Encrypts Your Files - Computerphile

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 พ.ค. 2024
  • Wanacrypt works super fast and even when you're offline. Dr Pound explains how hybrid ransomware systems work.
    Original Wana Decrypt0r video: • Wana Decrypt0r (Wanacr...
    The Perfect Code: • The Perfect Code - Com...
    / computerphile
    / computer_phile
    This video was filmed and edited by Sean Riley.
    Computer Science at the University of Nottingham: bit.ly/nottscomputer
    Computerphile is a sister project to Brady Haran's Numberphile. More at www.bradyharan.com

ความคิดเห็น • 627

  • @matthewvillage
    @matthewvillage 7 ปีที่แล้ว +489

    imagine if someone made ransomware that doesnt ask for money but forces you to play cookie clicker or flappy bird to get points to decrypt files as you play.

    • @Charharr
      @Charharr 7 ปีที่แล้ว +58

      Now that really is criminal ;)

    • @recklessroges
      @recklessroges 7 ปีที่แล้ว +7

      um, then I just use CookieMonster to play cookie clicker for me.

    • @matthewvillage
      @matthewvillage 7 ปีที่แล้ว +12

      it could look bad on the charities behalf if the creators of the program are holding peoples data wanting donations to that charity.

    • @Patan77xD
      @Patan77xD 7 ปีที่แล้ว +59

      Check out "Rensenware" its a ransomware forcing you to get a high score in a game.

    • @akmazaary9197
      @akmazaary9197 7 ปีที่แล้ว +2

      flappy bird are going to be twice the stress

  • @evansenicar
    @evansenicar 7 ปีที่แล้ว +1030

    If this dude was my professor, I might have actually attended class.

    • @fnvtyjkusg
      @fnvtyjkusg 7 ปีที่แล้ว +26

      His lectures are really interactive which is nice

    • @evansenicar
      @evansenicar 7 ปีที่แล้ว +14

      Computer science? He seems like he'd be fun to bs with during office hours. Actually, that's probably something I'll miss the most after school.

    • @Michael-rl2ff
      @Michael-rl2ff 7 ปีที่แล้ว +19

      Ben Chand agreed! best lecturer at UoN, shame I've only had one module with him

    • @FriedEgg101
      @FriedEgg101 7 ปีที่แล้ว +7

      You mean to say that there is a student at nottingham uni with the internet handle "dank memes"? I don't know how to feel about that.

    • @Michael-rl2ff
      @Michael-rl2ff 7 ปีที่แล้ว +22

      FriedEggSandwich it's only so I can shitpost in peace. already stumbled across another student on reddit

  • @longliveriley21
    @longliveriley21 7 ปีที่แล้ว +400

    The videos we want to see with the guy who explains it best. Kudos

    • @Correctrix
      @Correctrix 7 ปีที่แล้ว +8

      I'm not sure if you're sending him cuddles or kudos.

    • @mduckernz
      @mduckernz 7 ปีที่แล้ว +4

      longliveriley21 Why not both? 🦀

    • @GCOSBenbow
      @GCOSBenbow 7 ปีที่แล้ว +2

      Its a toddler cuddle.

  • @GodBreathed77
    @GodBreathed77 7 ปีที่แล้ว +45

    I am a Unix admin in a large company, and our Windows guys are so busy patching the several thousand Windows servers, they have enlisted us to help, needless to say I want to cry.

    • @MasonJuarez
      @MasonJuarez 7 ปีที่แล้ว +11

      needless to say you WanaCry

    • @GodBreathed77
      @GodBreathed77 7 ปีที่แล้ว +10

      That's the joke lol

    • @deivisony
      @deivisony 6 ปีที่แล้ว +1

      The Windows guys can relax from their busy time by playing minesweeper GET REKT

  • @DrachenYT
    @DrachenYT 7 ปีที่แล้ว +185

    WanaCrypt has proved one of the more interesting pieces of malware in awhile. Thanks for these, Computerphile!

    • @UXXV
      @UXXV 7 ปีที่แล้ว

      Just. The Michelangelo of the 10's

    • @helmutsvanags5236
      @helmutsvanags5236 7 ปีที่แล้ว +8

      lesselp true. ransomware is constantly being spread by hackers. wannacrypt is becoming notorious because of it's attack vector. also like it was said in the video a lot of ransomware requires for you to be online. wannacrypt does not.

    • @blockhet
      @blockhet 7 ปีที่แล้ว +3

      It's interesting you still came here to watch a second video of it then.

  • @stensoft
    @stensoft 7 ปีที่แล้ว +14

    There is also important reason for why each file has its own AES key. If you extract the AES key being used at the moment (which is not that hard TBH), you will get key for only one file. All files that were already encrypted will have their AES key encrypted already.

    • @RandomUser2401
      @RandomUser2401 10 หลายเดือนก่อน +2

      thx so much for this answer, I was wondering why the heck a separate AES key if you cannot get any of them without the private client key. But it all makes sense now.. Sandbox the process while it is still encrypting and boom you're out.

  • @misconstrudel
    @misconstrudel 7 ปีที่แล้ว +189

    How did the wannacry hackers get away?
    They ran somewhere

  • @Thats_Handle0
    @Thats_Handle0 3 หลายเดือนก่อน

    it took me like um idk about hour more or less to understand how thet encryption chain works..very tough to understand it for the first time, but this dude explained it in a very good way. Thanks !

  • @szabiakanich
    @szabiakanich 7 ปีที่แล้ว +8

    Love these videos with Dr. Pound. He can explain stuff in an engaging way and looks like a generally cool guy to hang out with.

  • @szymon308
    @szymon308 2 ปีที่แล้ว +2

    I could listen to this guy talking about encryption all day, please make more videos :)

  • @carakintz3536
    @carakintz3536 3 ปีที่แล้ว +1

    I love the explainations! The 20 min videos are great, and someone that writes it out with pen, makes it easier to memorize :)

  • @jms019
    @jms019 7 ปีที่แล้ว

    Very well explained indeed. Worth noting that ideally your filesystem is setup so either you CANNOT change existing files or they are versioned (Files-11, ZFS). Some useful protection can be effected with common file systems by locking files and directories with an administrative account such that your everyday account simply cannot damage them. And of course backup, backup, backup

  • @mrgrey91
    @mrgrey91 5 ปีที่แล้ว

    This guy is really good in explaining things, I‘m impressed!

  • @jony7779
    @jony7779 7 ปีที่แล้ว

    Dr Pound is just about the only guest on computerphile that provides both interesting and accurate information. Keep these kinds of videos coming!

  • @Embedonix
    @Embedonix 7 ปีที่แล้ว +236

    The title should have been "How NOT to develop a BAD ransomware!"

    • @Lttlemoi
      @Lttlemoi 7 ปีที่แล้ว +8

      Why though? The only objective of ransomware is to extract money from its victims. Last I heard, it was pretty successful, having made already several tens of thousands of dollars.
      Why would the criminal(s) care whether the victims can get their files back? It's like a bank robber paying for the glass window they broke when they drove their truck into the building.

    • @nrxpaa8e6uml38
      @nrxpaa8e6uml38 7 ปีที่แล้ว +31

      They would care because if people weren't getting their files back after paying the ransom, it would quickly spread that paying is not an option anyway. Ideally, you would provide as much customer service as you can to ensure people are getting their files back.

    • @Lttlemoi
      @Lttlemoi 7 ปีที่แล้ว +17

      The advice to ransomware has always been to not pay, but take preventative measures such as creating backups, upholding general vigilance and not letting anyone touch anything they don't understand (which is damn near impossible nowadays).
      Besides, like the guy in the video said, there are always going to be people who stop thinking with their brain and start acting on emotion when faced with this kind of situation. Statistically speaking, some degree of success is therefore guaranteed.
      "customer service" I have to admit I chuckled.

    • @pyromen321
      @pyromen321 7 ปีที่แล้ว +14

      Some ransomeware groups have actually provided excellent customer service, going so far as to decrypt the files of people in poorer countries for free.

    • @MrFloris
      @MrFloris 7 ปีที่แล้ว +2

      Lttlemoi backups are only usable if they are not on the network and are not connected to the system. Ransomware can spread over the network and encrypt usb connected devices. The backup has to be offline at the least. Most people still backup to connected drives and then leave them connected.

  • @Logatog
    @Logatog 7 ปีที่แล้ว +3

    I certainly agree that a series of Dr. Pound speaking on the .onions would be very enjoyable!

  • @thatha137
    @thatha137 7 ปีที่แล้ว

    Keep doing videos with this guy please!

  • @Krunked
    @Krunked 7 ปีที่แล้ว

    i've nerded out with Dr Pound for hours of content now. keep it comin!

  • @Derbauer
    @Derbauer 7 ปีที่แล้ว +1

    More awesome content like this from the doctor please.

  • @federicoguerrero
    @federicoguerrero 7 ปีที่แล้ว

    I had my files encrypted with teslacrypt some time ago... had the luck of decrypt it with the help of a LEGEND in github that made a phyton script to retrieve the public key from one of the files!
    then used msieve to reconstruct the private key... i was SOOO happy that after a couple of days of of banging my head against the wall.. 160 bits was the length of the private key.. took about 5hs using cuda msieve, with the cpu (fx6300@4.5) got to 20hs and nothing... praise the gpu's!!
    also i had a close encounter with locky on a client pc, but it didnt erased shadowcopies so it was a piece of cake to restore.
    Now i've learn my lesson... double backup with 1 hard drive off site (on a drawer :P)

  • @user-tq1cm
    @user-tq1cm 7 ปีที่แล้ว

    This guy is awesome. Please make more videos!

  • @thatradkid
    @thatradkid 5 ปีที่แล้ว

    this was so cool! you're a great Lecturer!

  • @SageLukahn
    @SageLukahn 7 ปีที่แล้ว +2

    Snapshots on a file server basically eliminate the risk from a server standpoint, which is super nice. I wish Windows had a file system that allowed for better snapshotting.

  • @bertugolu
    @bertugolu 7 ปีที่แล้ว

    Excellent video as usual.

  • @lightsidemaster
    @lightsidemaster 7 ปีที่แล้ว

    I concur, a video on how Tor works would be really welcome!

  • @pinklady7184
    @pinklady7184 7 ปีที่แล้ว +12

    A few years ago, a hacker broke into my PC with ransomware. The moment when I saw a black screen with skull and cross bones, I immediately pulled out the plug while the ransomware was running. Hours later, I switched on my PC and chose a restore point of time. My PC was ok after that.

    • @sethadkins546
      @sethadkins546 4 ปีที่แล้ว

      Can't some malware contain code that deletes restore points?

    • @k0pstl939
      @k0pstl939 3 ปีที่แล้ว

      @@sethadkins546 Yes, but this particular one must not have

    • @Kitulous
      @Kitulous 3 ปีที่แล้ว

      that's why i do full system and data backups once every two days
      if ransomware blocks me out of a computer (winlocker kind of thing) or encrypts my data (wanacry kind of thing) i can at most lose two days of work
      and this backup drive is not connected at all times so ransomware cannot affect it, it's turned off and is kept on a shelf
      the only problem is the data stealers but i have two pieces of antivirus software working against that :)

  • @baldeepbirak
    @baldeepbirak 6 ปีที่แล้ว +2

    Great explanation. So has the master key been found?

  • @jamie_ar
    @jamie_ar 7 ปีที่แล้ว +1

    Interestingly, regarding the Windows Crypt API and reversing the encryption, a tool has been released that claims to retrieve the pair of primes used by the API for key generation from memory. AFAIK it has only been shown to work on XP and Windows 7 and of course requires the tool be run almost immediately after encryption has taken place so as to minimise the risk of the initial primes being overwritten in memory.

  • @oaklyfoundation
    @oaklyfoundation 7 ปีที่แล้ว

    This is the best Host ever in this show! :D

  • @shady4tv
    @shady4tv 7 ปีที่แล้ว

    THANK YOU!
    I was wondering how this worked!!!!

  • @daft_punker
    @daft_punker 7 ปีที่แล้ว

    More videos with this dude! I love every video that he is in. I learn so much.

  • @Nyamiou
    @Nyamiou 7 ปีที่แล้ว

    A disk rack with a cloning feature is the best way IMO to do backups, you just backup regulary on a disk on the drive A, and once in a while you get a drive on the drive B you clone the drive A on it, you disconnect the second drive and you store it in a safe location.

  • @MyTube4Utoo
    @MyTube4Utoo 6 ปีที่แล้ว

    I love Dr. Pound. Okay, I really like his videos. I guess there's a difference.

  • @sensei0101
    @sensei0101 7 ปีที่แล้ว

    Awesome video! Well made

  • @goo_user
    @goo_user 7 ปีที่แล้ว +40

    You should do a video on Peer-to-Peer

  • @sabersworn
    @sabersworn 7 ปีที่แล้ว +2

    Very informative. Thank you for the video! You hear it a lot, but you really are a great channel.

  • @OmikronPsy
    @OmikronPsy 7 ปีที่แล้ว +2

    Please make a whole Video about different Backup systems and how to best do it.

  • @Acid113377
    @Acid113377 7 ปีที่แล้ว

    Two questions which I would direct to Dr. Pound (if I could):
    1.) If we were to have recorded the exact state of memory of the computer which was infected with wannacry (over the duration of the installation of wannacry and the encryption of the files), would we be able to "replay" and analyse the execution and thereby fish out the keys generated and decrypt the files?
    2.) I see wannacry adds an extension to the filename of the encrypted files. What happens when it reaches the windows maximum filename size (of I think 256 characters)?
    If you ever get to read this Dr. Pound, I would appreciate your insight.
    P.S: Your name is pretty boss.

  • @WizardNumberNext
    @WizardNumberNext 6 ปีที่แล้ว +1

    it is not operating system which prevents other processes to access memory not owned by them, but actually processor itself and it is quite hard to circumvent this protection (kernel can do it as it can access all memory, but it now complicated then just that)

  • @victorgiovannoni
    @victorgiovannoni 7 ปีที่แล้ว

    I love this guy's videos! They're incredible

  • @daggawagga
    @daggawagga 7 ปีที่แล้ว

    If as stated in 14:55 it's quite hard to access memory of other processes in Windows and Linux, how does it happen in memory editors (such as CheatEngine for example)?
    Do processes have to specify some sort of security policy to enforce that protection?
    Do memory editors exploit some vulnerability to access other processes' memory?

  • @meneldal
    @meneldal 7 ปีที่แล้ว +1

    Could you manage to find out all the AES keys assuming you managed to intercept some of them? Like, while the program is still running, an antivirus or something would intercept the keys, and when you have a few generated keys in order, you could crack the "random" key generation algorithm. Or are they smart enough to use an entropic system that can't be easily cracked?

  • @fernandomattar
    @fernandomattar 7 ปีที่แล้ว

    Extremely lay question. Is numerical, brute force decryption of just the symmetric part of this process (the AES part, that uses the referenced generic key Kf) completely infeasible in reasonable timeframes with standard computing power?

  • @fsacer
    @fsacer 7 ปีที่แล้ว

    Just a note. There is already a decryption tool wannawiki which works on XP, Win7 because those keep private key in memory when wannacry is running. They didn't clean them from memory. So if you haven't shutdown PC you can get to your private key and decrypt your files. blog.comae.io/wannacry-decrypting-files-with-wanakiwi-demo-86bafb81112d

  • @surgeon23
    @surgeon23 7 ปีที่แล้ว

    love this guy

  • @Primence
    @Primence 7 ปีที่แล้ว

    Will you make another video on the breakthrough of decrypting wanacryptor files?

  • @m0rtale195
    @m0rtale195 7 ปีที่แล้ว

    Does the server necessary have to hold a "Hard Copy" of the code? Can't it just have an algorithm that solves the "S priv8" key upon some identity from the user (like hwid, assigned btc address etc) and thus decrypting files. On the other hand, the encryption process don't have to be done with like 770MB/SEC, can't it just have a modification OS sided that when a file is activated, it will shut it and thus further encrypt it?(my wording is a bit off, I have bad English skill) and also if the ransomware is runned upon launching of windows, can't we just close the internet and see what packet were sent from the computer and thus record the domain? (Correct me if I am wrong, I have bad English skill)

  • @Seth4All
    @Seth4All 7 ปีที่แล้ว +1

    Ohhhh - is that a scrambled Ghost Cube I spy up on the shelf? Nice!

  • @icantfindafreeytname
    @icantfindafreeytname 6 ปีที่แล้ว

    wouldn't it be possible, if one has multiple not encrypted copies of encrypted files, to identify the part of the encrypted files which hold the key. Once the individual keys have been identified, one could build the not encrypted keys by comparing the files, and lastly reverse engineer the key to encrypt the file specific key. If there are enough files present?

  • @MovingThePicture
    @MovingThePicture 7 ปีที่แล้ว

    Where can I find the "best way to do backup" video which is teased in the end?

  • @TyDreacon
    @TyDreacon 7 ปีที่แล้ว

    Just a naive thought:
    Is it not possible to have some kind of UAC-like control on a system's file encryption that could give users an intervention method? Or does it already exist and things like WanaCrypt already bypass it?

  • @ufon3000
    @ufon3000 7 ปีที่แล้ว

    Is it possible to find a Ks if you have a copy of the encrypted file which is not encrypted...? Something like comparsion....

  • @aungthuhein007
    @aungthuhein007 7 ปีที่แล้ว +1

    Great video! Can you also make a video about how anti-virus software detect malware in the same way that you guys explain things? Thanks

  • @justprogramming4966
    @justprogramming4966 4 ปีที่แล้ว +2

    I have 2 questions on the implementation of WannaCry. The first being what is the benefit of creating an AES key per file why not just one AES key per client. The second what is the benefit of creating the client RSA keys? If the AES key just gets encrypted with the public CnC key that comes with the executable wouldn't that achieve the same result?

    • @mrrobot6404
      @mrrobot6404 2 ปีที่แล้ว +1

      I had been thinking exactly same so i checked Comments but unfortunately i haven't found the answer
      So if you are reading this comment plz answer me

    • @mrrobot6404
      @mrrobot6404 2 ปีที่แล้ว

      After thinking a little bit i think this way the aes key isn't stored for a long time while the virus is running
      Anyway i don't have any idea why I'm replying to a comment from the last year lol

  • @LarsHarmsen1337
    @LarsHarmsen1337 7 ปีที่แล้ว

    So what benefits brings the asynchronous encryption on client side?
    I can just generate an AES key, encrypt all files and then store the AES key encrypted with the servers public key.
    When someone pays me, they send me there encrypted AES key and I can decrypt it with may servers private key and give them their individual AES key.

  • @FusionDeveloper
    @FusionDeveloper 7 ปีที่แล้ว

    I wonder if it is possible, to have a tool, that prevents software from encrypting files, without authorization. Maybe it could use your Windows login password to authorize only specific activities, such as "deleting volume/shadow backups" and "encryption". If it is impossible to distinguish simply modifying a file and encrypting a file, then maybe it could just protect specific folders from having the files be modified without a password or authorization (such as clicking a pattern).

  • @Everspy
    @Everspy 7 ปีที่แล้ว +4

    I think it actually can be reversed if the computer hasn't been restarted. The prime numbers used to generate the keys are still stored in memory.

    • @beta5770
      @beta5770 7 ปีที่แล้ว

      Matt Brown yep you're right

  • @olfmombach260
    @olfmombach260 7 ปีที่แล้ว

    I love how there are only books in the shelf where the camera sees it :D
    (Yes I know it is where he can grab the books)

  • @sethapex9670
    @sethapex9670 7 ปีที่แล้ว +4

    would it be possible to write software that prevents your computer from encrypting any files that are stored to your hard disk without your explicit and informed permission?

    • @ily1422
      @ily1422 ปีที่แล้ว +1

      if you still read this use "protected folders in windows 10"
      and dont listen to this clown crying about linux

  • @makers_lab
    @makers_lab 7 ปีที่แล้ว +1

    Was wondering if it affects the previous versions of files that you can sometimes find via file properties "previous versions".

    • @mateusmuller8100
      @mateusmuller8100 6 ปีที่แล้ว

      From what he said, the ransonware makes a copy of the file it encrypts and delete the original. So my guess is no.

  • @Marci124
    @Marci124 7 ปีที่แล้ว

    No mention of air-gapped backups at the end?

  • @averasko
    @averasko 6 ปีที่แล้ว

    at 4:30+ -- not clear how does wannacry still allow access to the files during the encryption; it must have the private key somewhere, if not on the disk -- then, at least in memory; but what happens if computer gets rebooted while still not completely encrypted?

  • @hugo-s
    @hugo-s 7 ปีที่แล้ว

    Love how he looks at the camera guy for a second then goes... *riiiight. xD

  • @Ragaaci
    @Ragaaci 7 ปีที่แล้ว

    So i have a question. What if my files on my computer are already encrypted by myself with veracrypt, can wannacry still encrypt or access my files ? Thanks.

  • @farnoodp
    @farnoodp 7 ปีที่แล้ว

    amazing video!! please keep uploading cool educational stuff like this

  • @thecaveofthedead
    @thecaveofthedead ปีที่แล้ว

    Was Dr. Pound using a mini-disc player in like 2017?! And was anyone surprised who's seen more than two of the videos he's previously been featured in that he leaves an unsolved cube on his shelf to annoy people?

  • @real1cytv
    @real1cytv 6 ปีที่แล้ว

    Is it possible to extract the private key from the server with the encrypted and unencrypted client private key?

  • @VauxhallViva1975
    @VauxhallViva1975 7 ปีที่แล้ว

    Triple redundant backup. That's what I use. One local copy, one on the server, and one on the cloud. In my case, Dropbox, but I hear that WannaCrypt will happily encrypt your Dropbox or any other cloud storage that is accessible from the filesystem tree, although, those cloud storage businesses would be able to restore to the last update you did. However, the most recent copy of the files would be toast.

  • @xgeneralzimx
    @xgeneralzimx 6 ปีที่แล้ว

    To address the point of the private key being held in memory, would the newly discovered Spectre & Meltdown exploits, assuming the host system is unpatched, allow you to exfiltrate the private key from memory that way? Obviously, this is also assuming you can somehow get to it before it's encrypted. It seems like it happens so fast, that it's a moot point
    I'm just coming to this video now that it's been discovered that it can be possible to access memory for other processes due to these exploits

  • @Daniel14550
    @Daniel14550 7 ปีที่แล้ว

    What problems would arise from instead of burying a symmetric key inside the ransomware that's the same for everybody, you put in some code that generated a random number and used that?

  • @eahere
    @eahere 7 ปีที่แล้ว

    So, in essence:
    1. Encrypt the entire computer using the fast AES
    2. Encrypt the AES key using the public key of the attacker
    3. Send the encrypted key file to your attacker so that he can decrypt it and send it back to you.
    Is there no way to figure out the private key if you have the decrypted file and the encrypted one?

  • @ankoorshah6821
    @ankoorshah6821 7 ปีที่แล้ว

    I really like this guy

  • @blipman17
    @blipman17 7 ปีที่แล้ว

    Are there libraries that perfrom this on the client? I can imagine this also being verry usefull for lisence services or for encrypted backups.

    • @C3nturyFox
      @C3nturyFox 7 ปีที่แล้ว

      lol generating RSA keys isnt hard, you could even do it by hand.

    • @blipman17
      @blipman17 7 ปีที่แล้ว

      Wasn't talking about generating rsa keys. I meant making some lisense file, encrypting it by a key, storing it on local disk, read it on every boot, send it to an authentification server (together with som MAC address or other for of UUID data), and verify you are actually allowed to run this software. I'm a lazy programmer. I also recognise that if I write this myself and I want to have waterproof lisensing for some reason that I would probably will have some bugs in it. Using a library which does this for you might be an option if you A: Don't want to maintain the code yourself, B: Recognise that you don't know all the edge-cases and weird quirks of the design, C: Don't like bugs and only want battle-proven code.

  • @Sekuroon1
    @Sekuroon1 7 ปีที่แล้ว

    Curious since my understanding of encryption is poor. If you had a few known files before encryption would you be able to reverse engineer the encryption key since you would then have a few examples of before and after?

  • @kelvinjones2414
    @kelvinjones2414 7 ปีที่แล้ว

    If Microsoft had made it so that all programs or processes needed initial permission to access its encryption libraries, would this have helped to stop the problem? Or forced the software to contain the encryption libraries within themselves - making them accessible to us at some point? Microsoft like prompting for permissions, why not in this case?

  • @breyonsamuel6251
    @breyonsamuel6251 7 ปีที่แล้ว

    Does WanaCrypt encrypt each file with a different AES key or generate a single AES key then encrypt all files with it?

  • @mikeselectricstuff
    @mikeselectricstuff 7 ปีที่แล้ว +18

    So if it's using Windows' services to generate keys, might a protection against future attacks be for Windows to keep a log of all the keys it has generated?

    • @karlcloudy
      @karlcloudy 7 ปีที่แล้ว +35

      If they did that, you couldn't rely on the security of those algorithms, since inevitably an exploit would be found to extract the keys from the log. These libraries are used for other encryption tasks where you certainly don't want records of the keys hanging around to be stolen by hackers, etc.
      In addition, if this was the case, the authors would then simply implement their own version of the encryption algorithm that didn't log the keys (if you're lucky, maybe they'd screw it up and make it insecure in the process).

    • @harleyspeedthrust4013
      @harleyspeedthrust4013 2 ปีที่แล้ว +1

      Lol if that happened every sensible windows user would immediately switch to any other OS, and that might even be illegal

  • @jwrusty
    @jwrusty 7 ปีที่แล้ว

    Can you please explain why we need to generate a client side key pair at all?
    If we encrypt the AES key (Kf) using the server's public key, all should work exactly the same.
    The command centre will just need to decrypt Kf rather than Cpriv.

    • @C3nturyFox
      @C3nturyFox 7 ปีที่แล้ว +2

      -1.) There is a Kf for every file, so the CnC has to decrypt thousands of Kf per Victim instead of only 1 Cpriv.
      -2.) The CnC cant distinguish which Victim has which Kfs. So only one guy has to pay and just send the Kfs of all Victims.

    • @jwrusty
      @jwrusty 7 ปีที่แล้ว

      Thank you for this. I was assuming there is one Kf per machine rather than per file. If each file has a separate AES key, then this would make perfect sense.

  • @sfabiocruz
    @sfabiocruz 5 ปีที่แล้ว

    If we have a very large amount of files, how can the ransomware encrypt so fast all of them? can we save some files from being encrypted if we turn off the computer at the moment?

  • @chrisjon
    @chrisjon 7 ปีที่แล้ว +5

    I wonder if it would be helpfull/possible to decrypt lets say a 10KB file if you have an exact unencrypted version of that file.

    • @cezarcatalin1406
      @cezarcatalin1406 7 ปีที่แล้ว

      chrisjon to work your way around the encription ? hummm ...

    • @recklessroges
      @recklessroges 7 ปีที่แล้ว

      I don't know of any way that that would help with AES. Nice idea though. There might be something in there.

    • @chrisjon
      @chrisjon 7 ปีที่แล้ว +2

      My assumption is just that if the file is small enough, i guess the possible combinations would be small, or if the small encrypted file was a picture of 1 color, however this is totally uneducated thinking.

    • @Madinko12
      @Madinko12 7 ปีที่แล้ว

      Nope. Not possible, unless there is a flaw in the encryption algorithm used. AFAIK, none similar flaw has been discovered in AES, and if you found one, you'd be able to make a lot of money out of it.
      Moreover, even if it were possible, the only thing you could deduce from this is that a plain file you have is the same as an encrypted one. But you won't be able to decrypt any other file since they all use different keys.
      As stated in this video, if WannaCrypt was done the right way, there's absolutely no way to ever ever be able to retrieve any information about your unencrypted files (apart from a tiny hint on their size). The only hope is that the attacker private key leaks some day, or that people updates their computer in a regular basis. But the former has a lot more chance to happen than the latter, unfortunately 😊

  • @klafbang
    @klafbang 7 ปีที่แล้ว

    Amusingly, for WannaCry, there's now a tool which picks the private key out of memory and allows you to decrypt your files.

  • @Yhigma
    @Yhigma 7 ปีที่แล้ว +1

    What software/tools are used to edit the videos?
    The animations with the keys are really cool and I'd like to know more about how that works!

  • @eky
    @eky 7 ปีที่แล้ว

    Yes, talk more on the topics of tor, dark web, hidden servers please

  • @Ubeogesh
    @Ubeogesh 7 ปีที่แล้ว

    So can like earth's best supercomputer can go and crunch that factorization problem and get that server private key? Or that gonna take million years?

  • @ultort
    @ultort 7 ปีที่แล้ว

    Because of a flaw in Windows XP encryption system, it is possible to retrieve the encryption key from memory if the computer is not rebooted.

  • @Squidward1314
    @Squidward1314 7 ปีที่แล้ว

    At 13:40
    How can AES encryption be so quick? Around 700MBit/s ? I mean ok, if the CPU supports it on the hardware thats cool but don't the files have to be rewritten? Doesn't the hard-drive / SSD speed limit the encryption process? And most SSDs should be limited by SATA3 600MBit/s transfer speeds. Even still it's not like one big sequential file transfer... can someone explain that to me? :)

  • @audacity1375
    @audacity1375 7 ปีที่แล้ว +1

    why not just encrypt the AES key with the server public key? why the extra stage?

  • @KingOfDuckz
    @KingOfDuckz 7 ปีที่แล้ว +274

    World gets hit by a ransomware:
    Milks it for 2 vids in a row.
    I'm only joking. This was informative and entertaining. Next, teach us all how to write a ransomware ;)

    • @TehDMBfan
      @TehDMBfan 7 ปีที่แล้ว +11

      KingOfDuckz reported for crimes

    • @furrane
      @furrane 7 ปีที่แล้ว +38

      He just did it, you didn't pay attention.

    • @goeiecool9999
      @goeiecool9999 7 ปีที่แล้ว +16

      Yeah what furrane said... All you need to do now is "git clone openssl", "make" and then "git gud scrub"

    • @123FireSnake
      @123FireSnake 7 ปีที่แล้ว +6

      he just did precisely that unless you need further instruction on programming itself:D

    • @espanadorada7962
      @espanadorada7962 7 ปีที่แล้ว

      FireSnake yeah but only like .001% of ppl can do that

  • @Rudxain
    @Rudxain 3 ปีที่แล้ว

    What if a user tried to search the hard disk free space in order to get past copies of their unencrypted files? Does WannaCrypt wipes or overwrites all that data?

  • @Xershade
    @Xershade 5 ปีที่แล้ว +1

    And this is why my secure/really important files are on a completely offline computer, and can only transfer files VIA CD-Rs. Pain in the foot but security is worth it.

  • @MacoveiVlad
    @MacoveiVlad 7 ปีที่แล้ว +1

    Actually someone managed to create a decryption tool that gets the key from memory. So it was not such a bad research direction. Now, the number of people that would know not to shut the PC down and search for a decryption tool is probably very very small. I guess that if such an attack happens in a business environment even if the IT guy know what to do the person that gets the PC infected will shut it down and then call the IT department. So it does not really help, but it is technically possible.

  • @Flankymanga
    @Flankymanga 7 ปีที่แล้ว +1

    5:05 - What if the ransomware is only activated once it has connection to the command server. Command server will generate the public private key par and send only the public key to the ransomeware to encrypt files?

    • @mateusmuller8100
      @mateusmuller8100 6 ปีที่แล้ว

      Not a bad solution, but the one presented IS better. Just because you don't need internet at all

  • @Ubeogesh
    @Ubeogesh 7 ปีที่แล้ว +1

    Which folders or files does WannaCrypt encrypt? Surely not "all", or windows would just stop working.

  • @squeegie-beckenheim
    @squeegie-beckenheim 4 ปีที่แล้ว

    Mike Pound: "Anyone disassembling this code, and researchers do this within minutes, will immediately find this string"
    Me on my 3rd hour of a beginner CTF reversing challenge: ...

  • @smurfendrek4791
    @smurfendrek4791 7 ปีที่แล้ว +23

    Why not just encrypt the aes keys with the server public keys? Why add an extra layer of rsa on the aes keys?

    • @cezarcatalin1406
      @cezarcatalin1406 7 ปีที่แล้ว +3

      Smurf En Drek because the video would have been too short

    • @smurfendrek4791
      @smurfendrek4791 7 ปีที่แล้ว

      No, i'm asking why didn't wncry use this?

    • @SameerVijaykar
      @SameerVijaykar 7 ปีที่แล้ว +24

      Here's the best answer I can come up with. If it continues to use a separate AES key for each file, then it would need to upload a huge number of encrypted keys to the CnC server, and send lots of those back decrypted after the ransom was paid. I would assume the ransomware wants to minimize the amount of data sent over the wire to avoid any issues from network activity.
      If the same AES key was used for all files, then the key would have to persist in memory a lot longer, meaning a slightly higher chance of the key being extracted from memory. Also, not sure if this would be a weakness with AES, but some cryptosystems are susceptible to cryptanalysis, given a large amount of ciphertext encrypted with the same key.
      Of course both these alternatives still assume a unique AES key for each infected computer. Obviously using the same AES key for all infected computers would mean only 1 ransom would ever have to be paid.

    • @aybmnn
      @aybmnn 7 ปีที่แล้ว +7

      because then if they if wncry wants to decrypt someone's files, everyone can decrypt they're file using the same key.
      That extra layer is to make sure each computer files get encrypted using different key so if one computer pays and get its "extra layer" key decrypted that key would still not work for the other infected computers (that's giving that there is one "extra layer" key per computer it could be one key per file")

    • @jp10a
      @jp10a 7 ปีที่แล้ว +4

      The only thing that comes to my mind is:
      If I understood correctly, for every file it generates a new AES key Kf. So, if someone pays the ransom and the people behind it decide to give him his files back, they would have to decrypt every single Kf with the server private key.

  • @Hotmustardgas20
    @Hotmustardgas20 7 ปีที่แล้ว

    Please make a video about services like tor

  • @__mk_km__
    @__mk_km__ 7 ปีที่แล้ว

    This feeling, when there is a panic all around the world about WannaCrypt0r and your laptop does not support SMB.

  • @CurtisSmale
    @CurtisSmale 7 ปีที่แล้ว

    I have a couple questions about this. First: Suggest a person has multiple drives (partitions or external drives), do they get affected? Second: Suppose someone already has their data encrypted, can they be double encrypted or are they untouchable?

    • @Thorpe
      @Thorpe 7 ปีที่แล้ว

      Curtis Smale Usually specific files (documents, images, videos) are targeted in the user's home folder and then other files on any connected drives and possibly the network if write access.

  • @WingXBlade
    @WingXBlade 7 ปีที่แล้ว

    If the maker of the ransomware bury ks in the software, and it's already the end product, how can people find out whats inside of it without having the source code in hand?

  • @Natsukashii-Records
    @Natsukashii-Records 6 ปีที่แล้ว

    correct me if I'm wrong(which I am) but if you had 2 copies of the exact same file, one encrypted and the other not encrypted, wouldn't you be able to compare them and find how the file was encrypted and hence the key?

    • @SamWoodcock
      @SamWoodcock 6 ปีที่แล้ว +1

      You could but it would take a rather long time

    • @wildwest1832
      @wildwest1832 3 ปีที่แล้ว

      No.