Menu

VeraCrypt must need administrative permission?

Rex
2023-07-28
2024-04-03
  • Rex

    Rex - 2023-07-28

    Hello,

    Do we need administrative permission to mount an encrypted volume with VeraCrypt? Can normal user create volume and then mount/dismount?

    I saw some topics mentioned the administrative permissions is only needed when using the portable version of VeraCrypt. Then where can I download the non-portable version?

    If compiled the source code with "All" or "All debug", the generated outputs are all portable versions? Then how to build the non-portable version?

    In the code, "A new instance of the application must be created with elevated privileges." Is that true?

    ifndef SETUP
    // UAC elevation moniker cannot be used in portable mode.
    // A new instance of the application must be created with elevated privileges.
    if (IsNonInstallMode () && !IsAdmin () && IsUacSupported ())
    {

    if (wcsstr (lpszCommandLine, L"/q UAC ") == lpszCommandLine)
    {
        Error ("UAC_INIT_ERROR", NULL);
        exit (1);
    }
    
    
    if (LaunchElevatedProcess (NULL, modPath, lpszCommandLine))
        exit (0);
    else
        exit (1);
    

    }
    endif

    Thanks in advance.

     
  • Mounir IDRASSI

    Mounir IDRASSI - 2023-07-28

    Hi @rexcheng,

    These are important questions and I will answer them one by one:

    1. Mounting Encrypted Volumes & Creating Volumes: You do not require administrative permissions to mount or dismount an encrypted volume with VeraCrypt when you're using the installed version. A non-admin user can create, mount, and dismount VeraCrypt volumes freely. The need for administrative permissions arises during the installation process of VeraCrypt or while using its portable version, which requires admin rights due to its nature of running directly from a folder without prior installation.

    2. Downloading the Non-Portable Version: The non-portable (or installable) version of VeraCrypt is designed to operate without the need for administrative permissions post-installation. You can easily download the standard version from the official VeraCrypt website's downloads page or here in Sourceforge under Files. Look for the the file VeraCrypt Setup_1.XX.exe. Please note that we also provide an MSI installer for VeraCrypt (look for "VeraCrypt_Setup_x64_1.xx.msi")

    3. Building Non-Portable Version from Source Code: When you compile the VeraCrypt source code with the "All" or "All debug" settings, you generate the portable executables by default. If you wish to create a standard installable version, you should execute the scripts sign.bat (after modification to point to your code signing certificate) or sign_test.bat found in the "Signing" folder. This will build the setup installer (name starting with "VeraCrypt Setup") along with the MSI installer (located under "Release\Setup Files\bin") and the portable one. Installing VeraCrypt using this setup installer or the MSI will grant users the ability to mount volumes without the need for admin rights.

    4. Code Query - Elevated Privileges: The segment of code you're referring to pertains to the portable version of VeraCrypt (the function IsNonInstallMode () returns TRUE). In portable mode, VeraCrypt needs to elevate to admin rights, and this is managed by launching a new instance with elevated privileges. However, for the installed version (through Setup or MSI), such elevation isn't required for mounting volumes.

    I hope these clarifications meet your needs and provide you with a more comprehensive understanding of VeraCrypt's workings.

     
    • Rex

      Rex - 2023-07-31

      Hi Mounir,
      Thank you for the explaination. I will have a try.

       
  • Stanimir Petrov

    Stanimir Petrov - 2024-04-01

    Hello,
    I have the following problem and would be very grateful if someone could help me solve it.
    I have created projects that are encrypted with VeraCrypt1.25.7 and they were stored on SSD E:/.... in my desktop computer. After a problem with the computer, it was necessary to reinstall Windows 10 (before the reinstallation, I was also using Windows 10). The SSD stays in the same slot, but the computer now recognizes it as F:/. I installed the same version of VeraCrypt, but I can't mount any of the projects because it says I don't have admin rights. I installed the latest version of VeraCrypt 1.26.7 but it shows me the same message.
    I would be very grateful if someone could tell me how I can solve this problem to use the information from the projects? If anyone can help me feel free to email me st5rov@gmail.com
    Thanks in advance.

     
  • Stanimir Petrov

    Stanimir Petrov - 2024-04-01

    By the way, I changed the location of the SSD from F:/ to Е:/ but I still can't open any of the projects :(

     

    Last edit: Stanimir Petrov 2024-04-01
  • RealTehreal

    RealTehreal - 2024-04-01

    I assume, that you try to mount a VeraCrypt container file? What's the filesystem of the partition? It's possibly a permission issue, because reinstalling Windows results in new user accounts being created. Therefore, you will likely not have access permissions to the container files. You could try to adjust file permissions for your container files.

    Greets

     
  • Enigma2Illusion

    Enigma2Illusion - 2024-04-01

    As RealTehreal said, this is going to be a Microsoft ownership and/or permission issue likely due to the user ID number (SID) is different than the old users ID numbers were on the previous Windows OS was using for your user name.

    Google search taking ownership of a file for Microsoft. Make sure to take ownership of the file container when dismounted and when mounted to take ownership of the directories and files.

     
  • Stanimir Petrov

    Stanimir Petrov - 2024-04-02

    Unfortunately, I don't have that much knowledge :( I'll probably have to forget that I have these projects :( :( (

     
    • RealTehreal

      RealTehreal - 2024-04-02

      You can somehow, via right clicking the volume file, take ownership of the file. Just google for taking ownership of files / folders in Windows. It's not unlikely to work again afterwards.

      Greets

       

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.