Menu

Problem mounting encrypted device (partition) after upgrading Windows 1.19 to 1.21

2017-07-16
2017-07-25
1 2 > >> (Page 1 of 2)
  • Jonas Hunziker

    Jonas Hunziker - 2017-07-16

    I have an issue with mounting a non-hidden encrypted partition after upgrading on Windows from VeraCrypt 1.19 to 1.21. The issue goes away after downgrade back to 1.19.

    Upon attempting a mount and after entering the password, I first receive "Incorrect function. Source:MountVolume:7989", followed by another dialog "The drive is damaged (there is a physical defect on it)..." Since the issue goes away after downgrade and there are no physical issues with drive or cabling, nor are there issues with the filesystem within the encrypted partition, I suspect it may have something to do with "Enhancements to driver handling of various disk IOCTL." listed in the release notes.

    What information do you need from me to pin-point the problem?

    Thanks!

     
  • Wojciech Czernek

    I have the same issue, but I cannot downgrade to 1.19, because my system drive is also encypted.

     

    Last edit: Wojciech Czernek 2017-07-19
  • Enigma2Illusion

    Enigma2Illusion - 2017-07-19

    What version of Windows are you running and is it 32-bit or 64-bit?

    Click on the lower left hand Windows icon and type winver then hit enter.

     
    • Wojciech Czernek

      64-bit

       
  • Mounir IDRASSI

    Mounir IDRASSI - 2017-07-20

    I can NOT reproduce the issue on test machine that run different Windows version. So the issue is certainly caused by an interaction with a driver running on the machine.
    In the past, such "Incorrect function" errors were found to be caused by Apple HFS drivers and the fix was to install alternative drivers from Paragon as indicated here https://sourceforge.net/p/veracrypt/discussion/technical/thread/f0c31aef/#1d1a.

    You are certainly not in this case since it was working with 1.19 and so another driver is responsible.
    It is difficult to analyze the problem without knowing more details but as Jonas mentionned this is certainly due to the new IOCTLs added to VeraCrypt.

    Can you please indicate:

    • Windows version details as asked by Enigma2Illusion
    • The filesystem used by the VeraCrypt volume you are trying to mount.
    • The characteristics of the disk (size, model, connection type...)
    • Any special software/driver installed that may access filesystems/low level disks (for example Apple HFS driver mentionned above is used to access HFS filesystem on Windows). This information will help see which software/driver is common to all users affected by the issue.

    Meanwhile, I will modify VeraCrypt to enable newly added IOCTLs only when option to enable extended IOCTLs is checked and I will publish a new Beta so that you can check if it fixes the problem.

     

    Last edit: Mounir IDRASSI 2017-07-20
    • Wojciech Czernek

      • Windows version details as asked by Enigma2Illusion
        • Windows 10 Pro X64
      • The filesystem used by the VeraCrypt volume you are trying to mount.
        • NTFS
      • The characteristics of the disk (size, model, connection type...)
        • Seagate ST1500DM003, 1.5TB, SATA III (connected to SATA II)
      • Any special software/driver installed that may access filesystems/low level disks (for example Apple HFS driver mentionned above is used to access HFS filesystem on Windows).
        • None
       
  • Mounir IDRASSI

    Mounir IDRASSI - 2017-07-20

    I meant I can NOT reproduce the issue...

     
  • Mounir IDRASSI

    Mounir IDRASSI - 2017-07-20

    I have uploaded a Windows installer for 1.22-BETA1-Build4 that can fix this issue if it is caused by the ,newly added IOCTLs. You can get it at https://sourceforge.net/projects/veracrypt/files/VeraCrypt%20Nightly%20Builds/.
    Can you please check if it fixes your problem?

    As I said earlier, this issue doesn't happen on clean Windows machine so you certainly have some other components on your system that filters all disk volumes (including VeraCrypt ones) and which have some incompatibility with the new IOCTLs. From the security points of view, it would be good to know who causes such problem (it can be a harmless driver or a malicious one).

     
  • Wojciech Czernek

    Installing beta version didn't help. Was I supposed to do anything else than just reinstall and try to mount the partition?

     
    • Mounir IDRASSI

      Mounir IDRASSI - 2017-07-21

      Normally it should have worked if the issue is linked to new IOCTLs but there are still things to try.

      1. First, can you please check the option "Enable extended disk control codes support" through the menu "Settings -> Performance/Driver Configuration", reboot the machine and try again? It is possible that the software that causes this issue need extra IOCTLs support from VeraCrypt.
      2. If this doesn't help, unchecked the above option, reboot and install the new beta I have prepared that includes a modification on 2 specific IOCTLs that existed before but which I changed. You can get the new installer from https://www.veracrypt.fr/downloads/1.22-BETA/VeraCrypt%20Setup%201.22-BETA2-Build0.exe. Does it fix the problem?

      If the new installer fixes the problem (with option "Enable extended disk..." unchecked), then it means that the software responsible for this problem doesn't call correctly the 2 IOCTLs I mentionned above.

      By the way, is it possible to know what kind of software you are using on this machine (for example, Antivirus). Standard Windows machines don't have this problem and it will be helpful to know what software is common between Wojciech and Jonas in order to find the culprit.

       
  • Jonas Hunziker

    Jonas Hunziker - 2017-07-22

    Sorry for the delay, only have time on week-ends. I will try the beta and report back as much data as possible. I do have various items running that could potentially be linking theirselves into this drive mounting process including Intel Rapid Storage driver, ASMedia 106x controller driver, ESET Smart Security, Hard Disk Sentinel, Samsung Magician, Dropbox client, WD Smartware, etc. I would not be surprised if the ASMedia driver is to blame as it's not the best of code...

     
  • Jonas Hunziker

    Jonas Hunziker - 2017-07-22

    Ok, tried all the suggestions but even with BETA2-Build0 and the "Enable extended disk control codes" option un-checked, it still does not work. I get "Incorrect function. Source:MountVolume:7993".

    System info:
    1. Windows 10 Pro Build 15063.483 en-US x64
    2. File system of volume is NTFS
    3. Disk that the volume is located on is a WD1003FZEX-00MK2A0, SATA 6G, connected to Intel 8 Series/C220 Chipset Family SATA AHCI Controller. Physical sector size is 4K, logical is 512 bytes. The veracrypt volume is located inside a 20GB raw partition that is located at the very beginning of this GPT disk and followed by 4 more ReFS and NTFS partitions on the same disk.
    4. Device stack for above HDD is as follows:
    \Driver\partmgr
    \Driver\Disk
    \Driver\SamsungRapidDiskFltr
    \Driver\ACPI
    \Driver\ACPI
    \Driver\iaStorA

    Lower filters on the above disk are:
    SamsungRapidDiskFltr
    EhStorClass

    Higher filters on the above disk are:
    partmgr
    edevmon

    If you need anything else, just let me know. Thanks!!

     
  • Mounir IDRASSI

    Mounir IDRASSI - 2017-07-23

    There was still one new IOCTL that was enabled by default (IOCTL_DISK_GET_DRIVE_GEOMETRY_EX) but it is pretty standard one and I didn't think it could be the cause.
    Anyway, I have now made this last one disabled by default and I also made some minor changes for better compatibility with non standard software.
    I have uploaded a new installer for 1.22-BETA2-Build1 to https://sourceforge.net/projects/veracrypt/files/VeraCrypt%20Nightly%20Builds/ that includes this.

    Can you please test with it and report the results?

    Thank you.

     
  • Wojciech Czernek

    I'm still unable mount the disk, but the error number changed to 8002

     

    Last edit: Wojciech Czernek 2017-07-23
    • Mounir IDRASSI

      Mounir IDRASSI - 2017-07-23

      Well, this is like fishing in the dark...I can't find any machine that has the same problem so this is becoming almost impossible to fix.

      As a last resort, I have done a modification to remove almost all features added to the driver and I have uploaded a new installer for 1.22-BETA2-Build2 to https://www.veracrypt.fr/downloads/1.22-BETA/VeraCrypt%20Setup%201.22-BETA2-Build2.exe. It should work now, do you confirm?

      After that, I will put back the new code piece by piece so that we can find which part is responsible. For that, I will need your collaboration.

       
      • Wojciech Czernek

        Thank you, It works now. You can count on my collabaration.

         
        • Mounir IDRASSI

          Mounir IDRASSI - 2017-07-24

          Thany you for the confirmation and for your valuable help.
          We can start the step by step process to identify the cause of the original issue.
          I have uploaded a new installer for 1.22-BETA2-Build3 to https://www.veracrypt.fr/downloads/1.22-BETA/VeraCrypt%20Setup%201.22-BETA2-Build3.exe. It contains the first small change.

          If it is still working with this Build3, I will prepare new build with extra addition. But if the issue reappears, it will mean that I found the cause and you can always downgrade to Build2.

          Thanks.

           
          • Jonas Hunziker

            Jonas Hunziker - 2017-07-25

            BETA2-Build3 works for me, no issues mounting that volume or any other.

             
            • Mounir IDRASSI

              Mounir IDRASSI - 2017-07-25

              @Jonas: thank you for the confirmation. I can now proceed to the next iteration step.
              I have uploaded an installer for 1.22-BETA2-Build4 that adds extra changes to https://www.veracrypt.fr/downloads/1.22-BETA/VeraCrypt%20Setup%201.22-BETA2-Build4.exe.
              Is it still working correctly?

               
              • Jonas Hunziker

                Jonas Hunziker - 2017-07-25

                BETA2-Build4 works as well.

                 
                • Mounir IDRASSI

                  Mounir IDRASSI - 2017-07-26

                  Thank you Jonas. To complete the test, do you have the error when you check "Enable extended disk control codes support" in VeraCrypt Performance/Driver Configuration.?

                  If it works with this option enabled, this will mean that I found the cause of the problem.

                   
                  • Jonas Hunziker

                    Jonas Hunziker - 2017-07-26

                    Yes, it works. I checked the option and rebooted to test and everything still worked perfectly.

                     
                    • Mounir IDRASSI

                      Mounir IDRASSI - 2017-07-26

                      Thank you Jonas.
                      The test results indicate that the issue is linked to the handling of IOCTL_DISK_GET_DRIVE_GEOMETRY_EX by your disk driver.
                      I have made the fix and I put back all new IOCTLs.
                      I have uploaded an installer for 1.22-BETA2-Build5 that contains cleaner code to https://sourceforge.net/projects/veracrypt/files/VeraCrypt%20Nightly%20Builds/. It should continue to work but just in case can you test it?

                      Thank you for your help in fixing this issue.

                       
                      • Jonas Hunziker

                        Jonas Hunziker - 2017-07-27

                        BETA2-Build5 with "Enable extended disk control codes support" checked works just fine, no errors. Am I supposed to uncheck the above option and test?

                         
1 2 > >> (Page 1 of 2)

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.