SlideShare ist ein Scribd-Unternehmen logo
1 von 56
Downloaden Sie, um offline zu lesen
“Secure Password Managers” and
         “Military-Grade Encryption” on
           Smartphones: Oh, Really?
                          Andrey Belenko and Dmitry Sklyarov
                                  Elcomsoft Co. Ltd.
                      {a.belenko, d.sklyarov}@elcomsoft.com


Friday, 16 March 12                                            1
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           2
Authentication: PC
                      • Trusted Platform Module



                      • Biometrics



                      • SmartCard + PIN



                      • Password/Passphrase

Friday, 16 March 12                                         3
Authentication: Smartphone
                      • Trusted Platform Module



                      • Biometrics



                      • SmartCard + PIN



                      • Password/Passphrase

Friday, 16 March 12                                  4
Authentication: Smartphone


                              Password is the only option
                                  on the smartphones

                             “Lock patterns” are essentially
                                   numeric passcodes




Friday, 16 March 12                                            5
Password Typing
                             PC:
                             • Full-sized keyboard,
                               motor memory
                             • Long and complex
                               passwords are easy

    Smartphone:
    • Touch keyboard
    • Long and complex
      passwords are hard

Friday, 16 March 12                                   6
Password Typing



                  It is fair to assume that passwords on the
                     smartphones are shorter than their PC
                                    counterparts




Friday, 16 March 12                                            7
Password Cracking
   Smartphone:
   • Relatively slow CPU
   • Complex password-
     to-key transforms will
     impact usability

                              PC:
                              • Fast CPU
                              • Can do complex
                                password-to-key
                                transforms
Friday, 16 March 12                               8
Password Handling
                     Password Cracking




           Offline attacks can utilize GPUs for attackers’
                             advantage
Friday, 16 March 12                                          9
Authentication Wrap Up
                       PC                    Smartphone
            Password entered not       Password entered every
            too often (usually just    time you need access
            after unlocking console)   data (after switching
                                       applications or after
                                       short time-out)

          •Handling passwords on smartphone is more
           difficult than on PC
          •Smartphone requires stronger password
           protection than PC but provides less
           capabilities for doing so!
Friday, 16 March 12                                             10
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           11
Threat Model
          Assumptions:
          1. Attacker has:
           • Physical access to the device, or
           • Backup of the device, or
           • Access to password manager database file
          2. Attacker wants to:
           • Recover master password for password
             manager(s) on the mobile device
           • Extract passwords stored by those
             managers
                      Are those assumptions fair at all?
Friday, 16 March 12                                        12
Physical Access
                            Computers are relatively
                            big. Thus, hard to steal
                                    or lose.
                             You know where it is
                            (well, most of the time).

   Lots of phones go in wrong
   hands every year. Many are
          left in the bars.
    Do you really know where
    exactly your phone is right
                now?
Friday, 16 March 12                                     13
Someone’s just
      got physical
     access to the
           device




Friday, 16 March 12   14
Device Backup

        Apple iOS:
         • Need device passcode or iTunes pairing
         • Optional encryption (enforced by device)
           • PBKDF2-SHA1 with 10’000 iterations
        BlackBerry:
          • Need device password
          • Optional encryption (not enforced)
            • PBKDF2-SHA1 with 20’000 iterations


Friday, 16 March 12                                   15
Database Files

        Apple iOS:
         • Via afc (need passcode or iTunes pairing)
         • Via SSH (jailbroken devices)
         • Via physical imaging (up to iPhone 4)
        BlackBerry:
          • Need device password




Friday, 16 March 12                                    16
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           17
BlackBerry Applications


         • BlackBerry Password Keeper
            • Included with OS 5
         • BlackBerry Wallet
            • Version 1.0 (for OS <= 5)
            • Version 1.2 (for OS > 5)




Friday, 16 March 12                             18
BlackBerry Password Keeper
        • Key is calculated by PBKDF2-SHA1 with 3 iterations
        • Encrypted payload is PKCS7-padded
          • Allows to quickly reject wrong keys (p ≈ 2-8)
          • Survived keys are checked by verifying SHA-1
                          Encrypted payload

                                 Data         SHA1 (Data)


        • Password verification is fast
          • 3 x PBKDF2-SHA1 + 1 x AES-256
          • ~5M passwords/sec on a CPU, ~20M with GPU



Friday, 16 March 12                                            19
PKCS7 Padding
        Plaintext padded to completely fill last block
         • Done even if block size divides plaintext length
         • Padding value == number of bytes appended
                      PKCS7 padding bytes

                      7 7 7 7 7 7 7                   3 3 3
                        6 6 6 6 6 6                       2 2
                           5 5 5 5 5                          1
                               4 4 4 4      D a t a B y   t   e 8 8 8 8 8 8 8 8
                         Block size                               PKCS7 padding bytes



           • After decryption padding verified and removed
           • Decryption with random key produces valid padding
             with p ≈ 2-8 (0.4%)
Friday, 16 March 12                                                                     20
BlackBerry Wallet
                      “Designed for BlackBerry smartphones,
                      BlackBerry Wallet helps make mobile,
                      online purchasing faster and easier”


            Version 1.0
            • Stores SHA-256 (SHA-256 (Password))
            • Password verification requires 2 x SHA-256
            • Very fast: ~6M on CPU, ~300M on GPU
            • No salt: Rainbow Tables may be built

Friday, 16 March 12                                           21
BlackBerry Wallet
                      “Designed for BlackBerry smartphones,
                      BlackBerry Wallet helps make mobile,
                      online purchasing faster and easier”
      Version 1.2
      • Similar to BB Password Keeper, but...
      • Password initially hashed with SHA-512
      • PBKDF2-SHA1 uses random number (50..100)
        of iterations
      • Password verification requires 1xSHA-512 +
        100xPBKDF2-SHA1 + 1xAES-256
      • Est. 200K p/s on CPU, 3200M on GPU
Friday, 16 March 12                                           22
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           23
iOS Free Apps
       Search App Store for “Password Keeper” and
       pick a few from top 20 free apps

       • Safe – Password (x3)
       • iSecure Lite
       • Secret Folder Lite
       • Ultimate Password Manager Free
       • My Eyes Only™ - Secure Password Manager
       • Keeper® Password & Data Vault
       • Password Safe – iPassSafe free version
       • Strip Lite - Password Manager
Friday, 16 March 12                                 24
[un]Safe Triplets
                      “FINALLY! THE SAFEST APP TO PROTECT
                      YOUR ALL PASSWORDS, BANK ACCOUNT,
                        CREDIT CARD, WEB LOGINS AND ETC.”

                      Safe – Password
                      by The Best Free, Lite and Pro Edition


                      Awesome Password Lite
                      by Easy To Use Products


                      Password Lock Lite
                      by chen kaiqian

Friday, 16 March 12                                               25
[un]Safe Triplets

         • All three are identical (except for names and
           background images)
         • Store data in SQLite database at
           Documents/Password_Keeper.sqlite
         • Master password is always 4 digits
         • No data encryption is involved at all
         • Master password is stored in plaintext

              SELECT ZPASSWORD FROM ZDBCONFIG;
Friday, 16 March 12                                        26
iSecure Lite - Password
                                            Manager
                           “You data is extremely secure, even you
                                   have lost your device or stolen”
           by Roland Yau



           • Stores data in SQLite database at
             Documents/app_creator.sqlite
           • Master Password of any length/chars
           • No data encryption is involved at all
           • Master Password is stored in plaintext

              SELECT passcode FROM preference;
Friday, 16 March 12                                                   27
Secret Folder Lite
                               “The BEST AND MOST ADVANCED
                             PHOTO & VIDEO PRIVACY APP in the
           by chen kaiqian                    App Store today”

       • Password-protect access to media files
       • Stores data in SQLite database at
         Documents/privatephototwo.sqlite
       • No data encryption is involved at all
       • All passwords are stored in plaintext

  SELECT ZDISPLAYNAME,ZPASSWORD FROM ZDBFILE;
Friday, 16 March 12                                              28
Ultimate Password Manager
                                              Free
                                   “The free version has the following
                                     limitations over the paid version:
    by Jean-Francois Martin                       - no data encryption”

  • Stores data in binary Property List at
      Library/Preferences/com.tinysofty.upmfree.plist
  • Master password is stored in plaintext

                      Are you interested in password manager
                        intentionally designed to be insecure,
                                    even if it’s free?
Friday, 16 March 12                                                       29
My Eyes Only™ - Secure
                                 Password Manager
                              “...allows personal information to be
                              stored on iPhones, iPods and iPads
                                 without the threat of unauthorized
      by Software Ops LLC
                                            access if lost or stolen”
     • Stores data in NSKeyArchiver files at
       Documents/*.archive, encrypted with RSA
     • Master password, public and private RSA keys
       are stored in keychain with attribute
       kSecAttrAccessibleWhenUnlocked

        Wow, RSA looks impressive for a password
                     keeper, isn’t it?
Friday, 16 March 12                                                     30
My Eyes Only™ - Secure
                           Password Manager
        • 512-bit RSA modulus: factorization is easy
        • Documents/MEO.archive holds RSA-
          encrypted master password
        • RSA private key is stored in the same file
        • Yes, RSA private key is stored along with
          encrypted data
        • Master password and everything else can be
          instantly decrypted
        • Whitfield Diffie wouldn’t probably like that )

Friday, 16 March 12                                        31
Keeper® Password & Data
                                                Vault
                               “With Keeper’s military-grade encryption,
                                 you can trust that no one else will have
            by Callpod Inc   access to your most important information”

    • Stores data in SQLite database at
      Documents/keeper.sql
    • MD5 of master password is stored in database
    • SHA1 of master password is used as AES key
    • Very fast password verification: 1 x MD5
      • ~60M p/s on CPU, 6’000M p/s on GPU
    • No salt: MD5 Rainbow Tables can be used
Friday, 16 March 12                                                         32
Password Safe - iPassSafe
                                           free version
                                “iPassSafe - To Be True Protected.
                               AES-256 Double Encryption Layers”
       by Netanel Software




        • Stores data in SQLite database at
          Documents/iPassSafeDB.sqlite
        • Prevents usage of “weak” passwords:
          0000 1234 2580 1111 5555
          0852 2222 1212 1998 5683


Friday, 16 March 12                                                  33
Password Safe - iPassSafe
                                           free version
                                “iPassSafe - To Be True Protected.
                               AES-256 Double Encryption Layers”
       by Netanel Software


  • Random master key (Mk)is used for encryption
  • Mk is encrypted with master password as a key
     • Password not hashed, only null-padded
     • PKCS7 padding allows to reject wrong keys
  • Very fast password verification: 1 x AES-256
    • ~20M on CPU, haven’t done AES on GPU yet :)
    • Rainbow Tables may be built
Friday, 16 March 12                                                  34
Strip Lite -
                                  Password Manager
                             “highly rated Password Manager and
                             Data Vault. Strip has been protecting
                                   sensitive information on mobile
            by Zetetic LLC
                                           devices for over 12 yrs.”

        • Stores data in SQLite database at
          Documents/strip.db
        • Whole database file is encrypted using
          open-source component sqlcipher
          developed by Zetetic

Friday, 16 March 12                                                    35
Strip Lite -
                         Password Manager

      • Database encryption key is derived from
        master password using PBKDF2-SHA1 with
        4’000 iterations
         • By far the most resilient app to password
           cracking
      • Password validation requires
        4000 x PBKDF2-SHA1 + 1 x AES-256
      • Est. 5K p/s on CPU, 160K on GPU


Friday, 16 March 12                                    36
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           37
iOS Paid Apps
       Google “Top Password Keepers for iOS” and
       pick a few from various reviews

       • SafeWallet - Password Manager
       • DataVault Password Manager
       • mSecure - Password Manager
       • LastPass for Premium Customers
       • 1Password Pro for iPhone
       • SplashID Safe for iPhone

Friday, 16 March 12                                38
SafeWallet -
               $3.99
                                    Password Manager
                             “Password Manager is the most secure
                                  and easy to use way to store your
   by SBSH Mobile Software
                               passwords and sensitive information”

        • Versions for Win, Mac, iOS, Android, BB…
        • Database format common for all platforms
        • Master key encrypted with master password
        • Data encrypted with AES-256, PKCS7
        • Password verification is fast
          •10 x PBKDF2-SHA1 + 1 x AES-256
          • Est. 1500K p/s on CPU, 20M on GPU
Friday, 16 March 12                                                   39
DataVault Password
                 $9.99
                                               Manager
                              “Leading Password Manager for iPhone,
                                iPad & iPod Touch ☆ AES Encryption”
             by Ascendo Inc


     • Data encrypted by the master password and
       stored in device keychain
        • Master password not hashed, only padded
     • SHA-256 of master password is stored in the
       keychain

      Keychain is used, so it should be hard to get
      hash to brute force master password, right?
Friday, 16 March 12                                               40
DataVault Password
                                   Manager

     • In iOS 4 keychain is a SQLite database
       • Data column is supposed to store passwords
         and is always encrypted
       • Other item attributes are not encrypted
     • Password hash stored as a ‘Comment’ attribute
     • Still, this is better than storing hash in a file

   Wait, I’ve heard iOS 5 encrypts all attributes in
            the keychain. Does that help?
Friday, 16 March 12                                        41
DataVault Password
                                      Manager

        • iOS 5 encrypts all keychain items’ attributes
          • But it stores SHA-1 hash of original attribute
            to facilitate search/lookup
        • So we have SHA-1 (SHA-256 (password))
        • Very fast password verification:
          • 1 x SHA-256 [+ 1 x SHA-1 in iOS 5]
          • 7M p/s on CPU, 500M on GPU
          • No salt: Rainbow Tables can be built

Friday, 16 March 12                                          42
mSecure -
                 $9.99
                                     Password Manager
                                       “used by almost a million users
                              worldwide, providing secure solution for
     by mSeven Software LLC
                                   storing your important information”

        • Stores data in NSKeyArchiver files at
          Documents/msecure.db.plist
        • Data encrypted with Blowfish
        • Master key is SHA-256 of master password
        • Fixed string encrypted on master key is
          stored for password verification

Friday, 16 March 12                                                      43
mSecure -
                 $9.99
                                     Password Manager
                                       “used by almost a million users
                              worldwide, providing secure solution for
     by mSeven Software LLC
                                   storing your important information”



        • Password verification:
          •1 x SHA-256 + 1 x Blowfish
          •300K p/s on CPU, no Blowfish on GPU yet



Friday, 16 March 12                                                      44
LastPass for Premium
                                            Customers
                $12/yr.         “...password data on your PC and your
                             iPhone seamlessly synced. Encrypted by
                                      AES-256 which is used by the US
               by LastPass     Government for Top Secret documents”

     • ‘Cloud’ service, local storage created after first login
     • Master key = SHA-256 (Username + Password)
     • SHA-256 of master key is encrypted with AES-256
       using master key and stored for verification
     • Off-line password validation is very fast:
        • 2 x SHA-256 + 1 x AES-256
        • 5M p/s on CPU, 20M on GPU
Friday, 16 March 12                                                     45
1Password Pro for iPhone
                $14.99
                                  “1Password Pro is a special edition of the
                                 award-winning 1Password application with
                                      more than 1 million users worldwide”
             by Agilebits Inc.




    • Versions for Mac, Win, iOS, Android
    • Two protection levels: master PIN and master
      password
    • Data encrypted with AES-128, key derived from
      master PIN or master password

Friday, 16 March 12                                                        46
1Password Pro for iPhone
      Read EncDatabaseKey and EncValidator from Database
      KEK := MD5 (Password + Salt)
      IV := MD5 (KEK + Password + Salt)
      DatabaseKey := AES-128-CBC (KEK, IV, EncDatabaseKey)
      Validator := AES-128-CBC (DatabaseKey, NULL, EncValidator)
      If Validator = DatabaseKey Then password is correct


    • Database key encrypted on itself is stored for
      PIN or password verification
       • PKCS7 padding allows to reject wrong keys
    • Password/PIN verification is very fast
       • 1 x MD5 + 1 x AES-128
       • 15M p/s on CPU, 20M p/s on GPU
Friday, 16 March 12                                                47
SplashID Safe for iPhone
                 $9.99        “the award-winning password manager with
                                    over 500’000 users worldwide, is now
                                 available for iPhone! The all new iPhone
              by SplashData   version 5 makes SplashID better than ever”

        • Versions for Win, Mac, iOS, Android, BB…
        • On iOS stores data in SQLite database at
          Documents/SplashIDDataBase.db
        • All sensitive data is encrypted with Blowfish
        • Master password is used as a Blowfish key
        • Master password is encrypted with...
Friday, 16 March 12                                                     48
SplashID Safe for iPhone

         • ...a random key (as per XKCD definition)




         • ‘Random’ key is g.;59?^/0n1X*{OQlRwy
         • Master password can be decrypted instantly



Friday, 16 March 12                                     49
Agenda

                      • Authentication: PC vs. Smartphone
                      • Threat Model
                      • BlackBerry Password Managers
                      • iOS Password Managers
                         • Free
                         • Paid
                      • Summary & Conclusions


Friday, 16 March 12                                           50
iOS Passcode
        • Starting with iOS 4 passcode is involved in
          encryption of sensitive data
        • Passcode key derivation is slowed down by
          doing 50’000 iterations
               • Each iteration requires talking to hardware AES
               • 6 p/s on iPhone 4
        • Can’t be performed off-line and scaled

                 Checking all 6-digit passcodes will take
                          more than 40 hours

Friday, 16 March 12                                                51
Cracking Passwords
                      Name                       Complexity               CPU p/s   GPU p/s   Len/24h

       Keeper® Password & Data Vault                1x MD5                 60 M     6000 M     14.7
       Password Safe - iPassSafe Free             1x AES-256               20 M      N/A       12.2
       Strip Lite - Password Manager    4000x PBKDF2-SHA1 + 1x AES-256     5000     160 K      10.1
       SafeWallet - Password Manager     10x PBKDF2-SHA1 + 1x AES-256     1500 K     20 M      12.2
       DataVault Password Manager            1x SHA-256 + 1x SHA-1         7M       500 M      13.6
       mSecure - Password Manager           1x SHA-256 + 1x Blowfish      300 K      N/A       10.4
       LastPass for Premium Customers       2x SHA-256 + 1x AES-256        5M        20 M      12.2
       1Password Pro                          1x MD5 + 1x AES-128          15 M      20 M      12.2
       BlackBerry Password Keeper        3x PBKDF2-SHA1 + 1x AES-256       5M        20 M      12.2
       BlackBerry Wallet 1.0                      2x SHA-256               6M       300 M      13.4
                                        1x SHA-512 + 100x PBKDF2-SHA1 +
       BlackBerry Wallet 1.2                       1x AES-256              200K     3200 K     11.4

        iOS passcode                      50000 iterations with HW AES      6         0         5.7




Friday, 16 March 12                                                                                     52
Conclusions

      • None of the tested password keepers offer
        reliable protection on top of OS security
      • Using them on improperly configured device
        may expose sensitive data
      • Paid apps are not necessarily more secure
        than free ones




Friday, 16 March 12                                  53
Our Wishlist
              Users:
               • Use passcode
               • Set backup password (complex one!)
               • Do not connect your phone to untrusted
                 devices
              Developers:
               • Use built-in OS security services
               • Don’t reinvent or misuse crypto
               • Really, don’t reinvent or misuse crypto

Friday, 16 March 12                                        54
THANK YOU




Friday, 16 March 12               55
PLEASE DO NOT FORGET
                         TO COMPLETE YOUR
                      FEEDBACK SURVEY FORMS!


Friday, 16 March 12                            56

Weitere ähnliche Inhalte

Ähnlich wie “Secure Password Managers” and “Military-Grade Encryption” on Smartphones: Oh, Really?

“Secure Password Managers” and “Military-Grade Encryption” on Smartphones:...
“Secure Password Managers” and   “Military-Grade Encryption” on  Smartphones:...“Secure Password Managers” and   “Military-Grade Encryption” on  Smartphones:...
“Secure Password Managers” and “Military-Grade Encryption” on Smartphones:...
Positive Hack Days
 
Mr. Andrey Belenko - secure password managers and military-grade encryption o...
Mr. Andrey Belenko - secure password managers and military-grade encryption o...Mr. Andrey Belenko - secure password managers and military-grade encryption o...
Mr. Andrey Belenko - secure password managers and military-grade encryption o...
nooralmousa
 
Belenko, sklyarov dark and bright sides of i cloud (in)security
Belenko, sklyarov   dark and bright sides of i cloud (in)securityBelenko, sklyarov   dark and bright sides of i cloud (in)security
Belenko, sklyarov dark and bright sides of i cloud (in)security
DefconRussia
 

Ähnlich wie “Secure Password Managers” and “Military-Grade Encryption” on Smartphones: Oh, Really? (20)

“Secure Password Managers” and “Military-Grade Encryption” on Smartphones:...
“Secure Password Managers” and   “Military-Grade Encryption” on  Smartphones:...“Secure Password Managers” and   “Military-Grade Encryption” on  Smartphones:...
“Secure Password Managers” and “Military-Grade Encryption” on Smartphones:...
 
Mr. Andrey Belenko - secure password managers and military-grade encryption o...
Mr. Andrey Belenko - secure password managers and military-grade encryption o...Mr. Andrey Belenko - secure password managers and military-grade encryption o...
Mr. Andrey Belenko - secure password managers and military-grade encryption o...
 
Five Lessons Learned From Breaking Into A Casino: Confessions of a Penetratio...
Five Lessons Learned From Breaking Into A Casino: Confessions of a Penetratio...Five Lessons Learned From Breaking Into A Casino: Confessions of a Penetratio...
Five Lessons Learned From Breaking Into A Casino: Confessions of a Penetratio...
 
Creating secure apps using the salesforce mobile sdk
Creating secure apps using the salesforce mobile sdkCreating secure apps using the salesforce mobile sdk
Creating secure apps using the salesforce mobile sdk
 
Baking Security into the Company Culture (2017)
Baking Security into the Company Culture (2017) Baking Security into the Company Culture (2017)
Baking Security into the Company Culture (2017)
 
eSecurity! Keeping your Business and Customers Safe
eSecurity! Keeping your Business and Customers SafeeSecurity! Keeping your Business and Customers Safe
eSecurity! Keeping your Business and Customers Safe
 
Emerging Threats and Attack Surfaces
Emerging Threats and Attack SurfacesEmerging Threats and Attack Surfaces
Emerging Threats and Attack Surfaces
 
Digital Hygiene for Nomads
Digital Hygiene for NomadsDigital Hygiene for Nomads
Digital Hygiene for Nomads
 
Behind The Code // by Exness
Behind The Code // by ExnessBehind The Code // by Exness
Behind The Code // by Exness
 
Belenko, sklyarov dark and bright sides of i cloud (in)security
Belenko, sklyarov   dark and bright sides of i cloud (in)securityBelenko, sklyarov   dark and bright sides of i cloud (in)security
Belenko, sklyarov dark and bright sides of i cloud (in)security
 
Hacking Smartcards & RFID
Hacking Smartcards & RFIDHacking Smartcards & RFID
Hacking Smartcards & RFID
 
Designing and Attacking DRM (RSA 2008)
Designing and Attacking DRM (RSA 2008)Designing and Attacking DRM (RSA 2008)
Designing and Attacking DRM (RSA 2008)
 
Security.ppt
Security.pptSecurity.ppt
Security.ppt
 
CyberLink MediaShow 5
CyberLink MediaShow 5CyberLink MediaShow 5
CyberLink MediaShow 5
 
Corporations - the new victims of targeted ransomware
Corporations - the new victims of targeted ransomwareCorporations - the new victims of targeted ransomware
Corporations - the new victims of targeted ransomware
 
Login cat tekmonks - v3
Login cat   tekmonks - v3Login cat   tekmonks - v3
Login cat tekmonks - v3
 
Refugees on Rails Berlin - #2 Tech Talk on Security
Refugees on Rails Berlin - #2 Tech Talk on SecurityRefugees on Rails Berlin - #2 Tech Talk on Security
Refugees on Rails Berlin - #2 Tech Talk on Security
 
Strong Authentication (Michal Sobiegraj)
Strong Authentication (Michal Sobiegraj)Strong Authentication (Michal Sobiegraj)
Strong Authentication (Michal Sobiegraj)
 
Wfh security risks - Ed Adams, President, Security Innovation
Wfh security risks  - Ed Adams, President, Security InnovationWfh security risks  - Ed Adams, President, Security Innovation
Wfh security risks - Ed Adams, President, Security Innovation
 
Droidcon it-2014-marco-grassi-viaforensics
Droidcon it-2014-marco-grassi-viaforensicsDroidcon it-2014-marco-grassi-viaforensics
Droidcon it-2014-marco-grassi-viaforensics
 

Kürzlich hochgeladen

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Kürzlich hochgeladen (20)

ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 

“Secure Password Managers” and “Military-Grade Encryption” on Smartphones: Oh, Really?

  • 1. “Secure Password Managers” and “Military-Grade Encryption” on Smartphones: Oh, Really? Andrey Belenko and Dmitry Sklyarov Elcomsoft Co. Ltd. {a.belenko, d.sklyarov}@elcomsoft.com Friday, 16 March 12 1
  • 2. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 2
  • 3. Authentication: PC • Trusted Platform Module • Biometrics • SmartCard + PIN • Password/Passphrase Friday, 16 March 12 3
  • 4. Authentication: Smartphone • Trusted Platform Module • Biometrics • SmartCard + PIN • Password/Passphrase Friday, 16 March 12 4
  • 5. Authentication: Smartphone Password is the only option on the smartphones “Lock patterns” are essentially numeric passcodes Friday, 16 March 12 5
  • 6. Password Typing PC: • Full-sized keyboard, motor memory • Long and complex passwords are easy Smartphone: • Touch keyboard • Long and complex passwords are hard Friday, 16 March 12 6
  • 7. Password Typing It is fair to assume that passwords on the smartphones are shorter than their PC counterparts Friday, 16 March 12 7
  • 8. Password Cracking Smartphone: • Relatively slow CPU • Complex password- to-key transforms will impact usability PC: • Fast CPU • Can do complex password-to-key transforms Friday, 16 March 12 8
  • 9. Password Handling Password Cracking Offline attacks can utilize GPUs for attackers’ advantage Friday, 16 March 12 9
  • 10. Authentication Wrap Up PC Smartphone Password entered not Password entered every too often (usually just time you need access after unlocking console) data (after switching applications or after short time-out) •Handling passwords on smartphone is more difficult than on PC •Smartphone requires stronger password protection than PC but provides less capabilities for doing so! Friday, 16 March 12 10
  • 11. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 11
  • 12. Threat Model Assumptions: 1. Attacker has: • Physical access to the device, or • Backup of the device, or • Access to password manager database file 2. Attacker wants to: • Recover master password for password manager(s) on the mobile device • Extract passwords stored by those managers Are those assumptions fair at all? Friday, 16 March 12 12
  • 13. Physical Access Computers are relatively big. Thus, hard to steal or lose. You know where it is (well, most of the time). Lots of phones go in wrong hands every year. Many are left in the bars. Do you really know where exactly your phone is right now? Friday, 16 March 12 13
  • 14. Someone’s just got physical access to the device Friday, 16 March 12 14
  • 15. Device Backup Apple iOS: • Need device passcode or iTunes pairing • Optional encryption (enforced by device) • PBKDF2-SHA1 with 10’000 iterations BlackBerry: • Need device password • Optional encryption (not enforced) • PBKDF2-SHA1 with 20’000 iterations Friday, 16 March 12 15
  • 16. Database Files Apple iOS: • Via afc (need passcode or iTunes pairing) • Via SSH (jailbroken devices) • Via physical imaging (up to iPhone 4) BlackBerry: • Need device password Friday, 16 March 12 16
  • 17. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 17
  • 18. BlackBerry Applications • BlackBerry Password Keeper • Included with OS 5 • BlackBerry Wallet • Version 1.0 (for OS <= 5) • Version 1.2 (for OS > 5) Friday, 16 March 12 18
  • 19. BlackBerry Password Keeper • Key is calculated by PBKDF2-SHA1 with 3 iterations • Encrypted payload is PKCS7-padded • Allows to quickly reject wrong keys (p ≈ 2-8) • Survived keys are checked by verifying SHA-1 Encrypted payload Data SHA1 (Data) • Password verification is fast • 3 x PBKDF2-SHA1 + 1 x AES-256 • ~5M passwords/sec on a CPU, ~20M with GPU Friday, 16 March 12 19
  • 20. PKCS7 Padding Plaintext padded to completely fill last block • Done even if block size divides plaintext length • Padding value == number of bytes appended PKCS7 padding bytes 7 7 7 7 7 7 7 3 3 3 6 6 6 6 6 6 2 2 5 5 5 5 5 1 4 4 4 4 D a t a B y t e 8 8 8 8 8 8 8 8 Block size PKCS7 padding bytes • After decryption padding verified and removed • Decryption with random key produces valid padding with p ≈ 2-8 (0.4%) Friday, 16 March 12 20
  • 21. BlackBerry Wallet “Designed for BlackBerry smartphones, BlackBerry Wallet helps make mobile, online purchasing faster and easier” Version 1.0 • Stores SHA-256 (SHA-256 (Password)) • Password verification requires 2 x SHA-256 • Very fast: ~6M on CPU, ~300M on GPU • No salt: Rainbow Tables may be built Friday, 16 March 12 21
  • 22. BlackBerry Wallet “Designed for BlackBerry smartphones, BlackBerry Wallet helps make mobile, online purchasing faster and easier” Version 1.2 • Similar to BB Password Keeper, but... • Password initially hashed with SHA-512 • PBKDF2-SHA1 uses random number (50..100) of iterations • Password verification requires 1xSHA-512 + 100xPBKDF2-SHA1 + 1xAES-256 • Est. 200K p/s on CPU, 3200M on GPU Friday, 16 March 12 22
  • 23. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 23
  • 24. iOS Free Apps Search App Store for “Password Keeper” and pick a few from top 20 free apps • Safe – Password (x3) • iSecure Lite • Secret Folder Lite • Ultimate Password Manager Free • My Eyes Only™ - Secure Password Manager • Keeper® Password & Data Vault • Password Safe – iPassSafe free version • Strip Lite - Password Manager Friday, 16 March 12 24
  • 25. [un]Safe Triplets “FINALLY! THE SAFEST APP TO PROTECT YOUR ALL PASSWORDS, BANK ACCOUNT, CREDIT CARD, WEB LOGINS AND ETC.” Safe – Password by The Best Free, Lite and Pro Edition Awesome Password Lite by Easy To Use Products Password Lock Lite by chen kaiqian Friday, 16 March 12 25
  • 26. [un]Safe Triplets • All three are identical (except for names and background images) • Store data in SQLite database at Documents/Password_Keeper.sqlite • Master password is always 4 digits • No data encryption is involved at all • Master password is stored in plaintext SELECT ZPASSWORD FROM ZDBCONFIG; Friday, 16 March 12 26
  • 27. iSecure Lite - Password Manager “You data is extremely secure, even you have lost your device or stolen” by Roland Yau • Stores data in SQLite database at Documents/app_creator.sqlite • Master Password of any length/chars • No data encryption is involved at all • Master Password is stored in plaintext SELECT passcode FROM preference; Friday, 16 March 12 27
  • 28. Secret Folder Lite “The BEST AND MOST ADVANCED PHOTO & VIDEO PRIVACY APP in the by chen kaiqian App Store today” • Password-protect access to media files • Stores data in SQLite database at Documents/privatephototwo.sqlite • No data encryption is involved at all • All passwords are stored in plaintext SELECT ZDISPLAYNAME,ZPASSWORD FROM ZDBFILE; Friday, 16 March 12 28
  • 29. Ultimate Password Manager Free “The free version has the following limitations over the paid version: by Jean-Francois Martin - no data encryption” • Stores data in binary Property List at Library/Preferences/com.tinysofty.upmfree.plist • Master password is stored in plaintext Are you interested in password manager intentionally designed to be insecure, even if it’s free? Friday, 16 March 12 29
  • 30. My Eyes Only™ - Secure Password Manager “...allows personal information to be stored on iPhones, iPods and iPads without the threat of unauthorized by Software Ops LLC access if lost or stolen” • Stores data in NSKeyArchiver files at Documents/*.archive, encrypted with RSA • Master password, public and private RSA keys are stored in keychain with attribute kSecAttrAccessibleWhenUnlocked Wow, RSA looks impressive for a password keeper, isn’t it? Friday, 16 March 12 30
  • 31. My Eyes Only™ - Secure Password Manager • 512-bit RSA modulus: factorization is easy • Documents/MEO.archive holds RSA- encrypted master password • RSA private key is stored in the same file • Yes, RSA private key is stored along with encrypted data • Master password and everything else can be instantly decrypted • Whitfield Diffie wouldn’t probably like that ) Friday, 16 March 12 31
  • 32. Keeper® Password & Data Vault “With Keeper’s military-grade encryption, you can trust that no one else will have by Callpod Inc access to your most important information” • Stores data in SQLite database at Documents/keeper.sql • MD5 of master password is stored in database • SHA1 of master password is used as AES key • Very fast password verification: 1 x MD5 • ~60M p/s on CPU, 6’000M p/s on GPU • No salt: MD5 Rainbow Tables can be used Friday, 16 March 12 32
  • 33. Password Safe - iPassSafe free version “iPassSafe - To Be True Protected. AES-256 Double Encryption Layers” by Netanel Software • Stores data in SQLite database at Documents/iPassSafeDB.sqlite • Prevents usage of “weak” passwords: 0000 1234 2580 1111 5555 0852 2222 1212 1998 5683 Friday, 16 March 12 33
  • 34. Password Safe - iPassSafe free version “iPassSafe - To Be True Protected. AES-256 Double Encryption Layers” by Netanel Software • Random master key (Mk)is used for encryption • Mk is encrypted with master password as a key • Password not hashed, only null-padded • PKCS7 padding allows to reject wrong keys • Very fast password verification: 1 x AES-256 • ~20M on CPU, haven’t done AES on GPU yet :) • Rainbow Tables may be built Friday, 16 March 12 34
  • 35. Strip Lite - Password Manager “highly rated Password Manager and Data Vault. Strip has been protecting sensitive information on mobile by Zetetic LLC devices for over 12 yrs.” • Stores data in SQLite database at Documents/strip.db • Whole database file is encrypted using open-source component sqlcipher developed by Zetetic Friday, 16 March 12 35
  • 36. Strip Lite - Password Manager • Database encryption key is derived from master password using PBKDF2-SHA1 with 4’000 iterations • By far the most resilient app to password cracking • Password validation requires 4000 x PBKDF2-SHA1 + 1 x AES-256 • Est. 5K p/s on CPU, 160K on GPU Friday, 16 March 12 36
  • 37. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 37
  • 38. iOS Paid Apps Google “Top Password Keepers for iOS” and pick a few from various reviews • SafeWallet - Password Manager • DataVault Password Manager • mSecure - Password Manager • LastPass for Premium Customers • 1Password Pro for iPhone • SplashID Safe for iPhone Friday, 16 March 12 38
  • 39. SafeWallet - $3.99 Password Manager “Password Manager is the most secure and easy to use way to store your by SBSH Mobile Software passwords and sensitive information” • Versions for Win, Mac, iOS, Android, BB… • Database format common for all platforms • Master key encrypted with master password • Data encrypted with AES-256, PKCS7 • Password verification is fast •10 x PBKDF2-SHA1 + 1 x AES-256 • Est. 1500K p/s on CPU, 20M on GPU Friday, 16 March 12 39
  • 40. DataVault Password $9.99 Manager “Leading Password Manager for iPhone, iPad & iPod Touch ☆ AES Encryption” by Ascendo Inc • Data encrypted by the master password and stored in device keychain • Master password not hashed, only padded • SHA-256 of master password is stored in the keychain Keychain is used, so it should be hard to get hash to brute force master password, right? Friday, 16 March 12 40
  • 41. DataVault Password Manager • In iOS 4 keychain is a SQLite database • Data column is supposed to store passwords and is always encrypted • Other item attributes are not encrypted • Password hash stored as a ‘Comment’ attribute • Still, this is better than storing hash in a file Wait, I’ve heard iOS 5 encrypts all attributes in the keychain. Does that help? Friday, 16 March 12 41
  • 42. DataVault Password Manager • iOS 5 encrypts all keychain items’ attributes • But it stores SHA-1 hash of original attribute to facilitate search/lookup • So we have SHA-1 (SHA-256 (password)) • Very fast password verification: • 1 x SHA-256 [+ 1 x SHA-1 in iOS 5] • 7M p/s on CPU, 500M on GPU • No salt: Rainbow Tables can be built Friday, 16 March 12 42
  • 43. mSecure - $9.99 Password Manager “used by almost a million users worldwide, providing secure solution for by mSeven Software LLC storing your important information” • Stores data in NSKeyArchiver files at Documents/msecure.db.plist • Data encrypted with Blowfish • Master key is SHA-256 of master password • Fixed string encrypted on master key is stored for password verification Friday, 16 March 12 43
  • 44. mSecure - $9.99 Password Manager “used by almost a million users worldwide, providing secure solution for by mSeven Software LLC storing your important information” • Password verification: •1 x SHA-256 + 1 x Blowfish •300K p/s on CPU, no Blowfish on GPU yet Friday, 16 March 12 44
  • 45. LastPass for Premium Customers $12/yr. “...password data on your PC and your iPhone seamlessly synced. Encrypted by AES-256 which is used by the US by LastPass Government for Top Secret documents” • ‘Cloud’ service, local storage created after first login • Master key = SHA-256 (Username + Password) • SHA-256 of master key is encrypted with AES-256 using master key and stored for verification • Off-line password validation is very fast: • 2 x SHA-256 + 1 x AES-256 • 5M p/s on CPU, 20M on GPU Friday, 16 March 12 45
  • 46. 1Password Pro for iPhone $14.99 “1Password Pro is a special edition of the award-winning 1Password application with more than 1 million users worldwide” by Agilebits Inc. • Versions for Mac, Win, iOS, Android • Two protection levels: master PIN and master password • Data encrypted with AES-128, key derived from master PIN or master password Friday, 16 March 12 46
  • 47. 1Password Pro for iPhone Read EncDatabaseKey and EncValidator from Database KEK := MD5 (Password + Salt) IV := MD5 (KEK + Password + Salt) DatabaseKey := AES-128-CBC (KEK, IV, EncDatabaseKey) Validator := AES-128-CBC (DatabaseKey, NULL, EncValidator) If Validator = DatabaseKey Then password is correct • Database key encrypted on itself is stored for PIN or password verification • PKCS7 padding allows to reject wrong keys • Password/PIN verification is very fast • 1 x MD5 + 1 x AES-128 • 15M p/s on CPU, 20M p/s on GPU Friday, 16 March 12 47
  • 48. SplashID Safe for iPhone $9.99 “the award-winning password manager with over 500’000 users worldwide, is now available for iPhone! The all new iPhone by SplashData version 5 makes SplashID better than ever” • Versions for Win, Mac, iOS, Android, BB… • On iOS stores data in SQLite database at Documents/SplashIDDataBase.db • All sensitive data is encrypted with Blowfish • Master password is used as a Blowfish key • Master password is encrypted with... Friday, 16 March 12 48
  • 49. SplashID Safe for iPhone • ...a random key (as per XKCD definition) • ‘Random’ key is g.;59?^/0n1X*{OQlRwy • Master password can be decrypted instantly Friday, 16 March 12 49
  • 50. Agenda • Authentication: PC vs. Smartphone • Threat Model • BlackBerry Password Managers • iOS Password Managers • Free • Paid • Summary & Conclusions Friday, 16 March 12 50
  • 51. iOS Passcode • Starting with iOS 4 passcode is involved in encryption of sensitive data • Passcode key derivation is slowed down by doing 50’000 iterations • Each iteration requires talking to hardware AES • 6 p/s on iPhone 4 • Can’t be performed off-line and scaled Checking all 6-digit passcodes will take more than 40 hours Friday, 16 March 12 51
  • 52. Cracking Passwords Name Complexity CPU p/s GPU p/s Len/24h Keeper® Password & Data Vault 1x MD5 60 M 6000 M 14.7 Password Safe - iPassSafe Free 1x AES-256 20 M N/A 12.2 Strip Lite - Password Manager 4000x PBKDF2-SHA1 + 1x AES-256 5000 160 K 10.1 SafeWallet - Password Manager 10x PBKDF2-SHA1 + 1x AES-256 1500 K 20 M 12.2 DataVault Password Manager 1x SHA-256 + 1x SHA-1 7M 500 M 13.6 mSecure - Password Manager 1x SHA-256 + 1x Blowfish 300 K N/A 10.4 LastPass for Premium Customers 2x SHA-256 + 1x AES-256 5M 20 M 12.2 1Password Pro 1x MD5 + 1x AES-128 15 M 20 M 12.2 BlackBerry Password Keeper 3x PBKDF2-SHA1 + 1x AES-256 5M 20 M 12.2 BlackBerry Wallet 1.0 2x SHA-256 6M 300 M 13.4 1x SHA-512 + 100x PBKDF2-SHA1 + BlackBerry Wallet 1.2 1x AES-256 200K 3200 K 11.4 iOS passcode 50000 iterations with HW AES 6 0 5.7 Friday, 16 March 12 52
  • 53. Conclusions • None of the tested password keepers offer reliable protection on top of OS security • Using them on improperly configured device may expose sensitive data • Paid apps are not necessarily more secure than free ones Friday, 16 March 12 53
  • 54. Our Wishlist Users: • Use passcode • Set backup password (complex one!) • Do not connect your phone to untrusted devices Developers: • Use built-in OS security services • Don’t reinvent or misuse crypto • Really, don’t reinvent or misuse crypto Friday, 16 March 12 54
  • 55. THANK YOU Friday, 16 March 12 55
  • 56. PLEASE DO NOT FORGET TO COMPLETE YOUR FEEDBACK SURVEY FORMS! Friday, 16 March 12 56