Skip to content

A modern, self-hosted backup solution for secure, encrypted backups across local and cloud storage.

fix: inaccessibility of windows keyring due to missing vcredist dependency.

towfiqi1b758f9b2017
diff --git a/installers/windows/pluton-setup.iss b/installers/windows/pluton-setup.iss
index 3696983..ce08dae 100644
--- a/installers/windows/pluton-setup.iss
+++ b/installers/windows/pluton-setup.iss
@@ -69,6 +69,10 @@ Source: "..\..\dist\executables\pluton-win-x64\drizzle\*"; DestDir: "{app}\drizz
; NSSM for service management (Assumes you have downloaded nssm.exe to installers/windows/tools/)
Source: "tools\nssm.exe"; DestDir: "{app}"; Flags: ignoreversion
+; Visual C++ Redistributable (required for native Node.js modules like @napi-rs/keyring)
+; Download from: https://aka.ms/vs/17/release/vc_redist.x64.exe
+Source: "tools\vc_redist.x64.exe"; DestDir: "{tmp}"; Flags: ignoreversion deleteafterinstall; Check: not IsVCRedistInstalled
+
; Application icon for shortcuts
Source: "setup.ico"; DestDir: "{app}"; DestName: "pluton.ico"; Flags: ignoreversion
@@ -87,6 +91,9 @@ Root: HKLM; Subkey: "SYSTEM\CurrentControlSet\Control\Session Manager\Environmen
; They will be configured via the web interface and stored securely in Windows Credential Manager.
[Run]
+; Install Visual C++ Redistributable if not already installed (required for native Node.js modules)
+Filename: "{tmp}\vc_redist.x64.exe"; Parameters: "/install /quiet /norestart"; StatusMsg: "Installing Visual C++ Redistributable..."; Flags: waituntilterminated; Check: not IsVCRedistInstalled
+
; Install the service using NSSM (will fail silently if service already exists on upgrade - that's OK)
Filename: "{app}\nssm.exe"; Parameters: "install {#MyAppServiceName} ""{app}\{#MyAppExeName}"""; Flags: runhidden; StatusMsg: "Installing service..."
; Set service description
@@ -123,6 +130,31 @@ var
// Variables to store inputs
ServerPort, MaxConcurrentBackups: string;
+// Check if Visual C++ Redistributable 2015-2022 (x64) is installed
+// Required for native Node.js modules compiled with MSVC (e.g., @napi-rs/keyring)
+function IsVCRedistInstalled: Boolean;
+var
+ Version: String;
+begin
+ Result := False;
+ // Check for VC++ 2015-2022 Redistributable (x64) - version 14.x
+ // The minimum version we need is 14.0 (VS 2015), but newer versions are backward compatible
+ if RegQueryStringValue(HKLM, 'SOFTWARE\Microsoft\VisualStudio\14.0\VC\Runtimes\x64', 'Version', Version) then
+ begin
+ Log('VC++ Redistributable found: ' + Version);
+ Result := True;
+ end
+ else if RegQueryStringValue(HKLM, 'SOFTWARE\WOW6432Node\Microsoft\VisualStudio\14.0\VC\Runtimes\x64', 'Version', Version) then
+ begin
+ Log('VC++ Redistributable found (WOW6432Node): ' + Version);
+ Result := True;
+ end
+ else
+ begin
+ Log('VC++ Redistributable not found - will install');
+ end;
+end;
+
// Check if service exists by querying its status
function ServiceExists(ServiceName: String): Boolean;
var
diff --git a/installers/windows/tools/vc_redist.x64.exe b/installers/windows/tools/vc_redist.x64.exe
new file mode 100644
index 0000000..ef26bb5
Binary files /dev/null and b/installers/windows/tools/vc_redist.x64.exe differ