[cpp-sp] 01/02: CPPSP-53 Replace Windows Installer with Bat and C program (for registry operations)

Codeberg noreply at shibboleth.net
Wed Apr 29 14:42:55 UTC 2026


This is an automated email from the git hooks/post-receive script.

codeberg pushed a commit to branch main
in repository cpp-sp.

View the commit online:
https://codeberg.org/Shibboleth/cpp-sp/commit/3fdd5fb023e2e0636858a05d0e1a1cbc2db4d5c7

commit 3fdd5fb023e2e0636858a05d0e1a1cbc2db4d5c7
Author: Rod Widdowson <rdw at steadingsoftware.com>
AuthorDate: Wed Apr 15 16:06:42 2026 +0100

    CPPSP-53 Replace Windows Installer with Bat and C program (for registry operations)
    
    https://shibboleth.atlassian.net/browse/CPPSP-53
    
    Turns off a lot of noise to stdout
---
 WindowsInstall/doupdate.bat | 28 ++++++++++++++--------------
 WindowsInstall/install.bat  |  4 ++--
 2 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/WindowsInstall/doupdate.bat b/WindowsInstall/doupdate.bat
index 2f232e50..21744045 100644
--- a/WindowsInstall/doupdate.bat
+++ b/WindowsInstall/doupdate.bat
@@ -1,4 +1,4 @@
-Rem @echo off
+ at echo off
 Rem Update SP agent
 
 setlocal
@@ -11,7 +11,7 @@ set TargetDir=%cd%
 cd /d %~dp0
 set SourceDir=%cd%
 cd ..
-echo "Installing from %cd%"
+echo Installing from %cd%
 
 Rem Grab version as string
 for /f "delims=" %%a IN (version.txt) do (set /a Version=%%a)
@@ -57,22 +57,22 @@ robocopy /xc /xn /xo /njs /njh etc "%targetdir%\etc\shibboleth-sp"
 Rem Set registry
 Rem Firstly the "have I been installed" setting
 
-reg import dist-bin\regkeys.txt
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v DisplayIcon /t REG_SZ /d "%SourceDir%\shib.ico,0"
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v InstallSource /t REG_SZ /d "%SourceDir%"
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v Version /t REG_DWORD /d %Version%
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v DisplayVersion /t REG_SZ /d "%VersionString%"
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v VersionMinor /t REG_DWORD /d %MinorVersion%
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v InstallLocation /t REG_SZ /d "%TargetDir%"
+reg import dist-bin\regkeys.txt 1> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v DisplayIcon /t REG_SZ /d "%SourceDir%\shib.ico,0" 1> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v InstallSource /t REG_SZ /d "%SourceDir%" 1> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v Version /t REG_DWORD /d %Version% 2> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v DisplayVersion /t REG_SZ /d "%VersionString%" 1> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v VersionMinor /t REG_DWORD /d %MinorVersion% 1> nul:
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v InstallLocation /t REG_SZ /d "%TargetDir%" 1> nul:
 Rem note double quoting for "
-reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v UninstallString /t REG_SZ /d "cmd /c ""%targetdir%\bin\uninstall.bat"""
+reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{D9DA52E3-F96E-4C84-B153-C3B17C34F730} /f /v UninstallString /t REG_SZ /d "cmd /c ""%targetdir%\bin\uninstall.bat""" 1> nul:
 
 Rem
 Rem now the event viewer
 Rem
-reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v CategoryCount /t REG_DWORD /d 0
-reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v TypesSupported /t REG_DWORD /d 7
-reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v CategoryMessageFile /t REG_SZ /d "%TargetDir%\lib\shibboleth-sp\NTEventLogAppender.dll"
-reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v EventMessageFile /t REG_SZ /d "%TargetDir%\lib\shibboleth-sp\NTEventLogAppender.dll"
+reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v CategoryCount /t REG_DWORD /d 0  1> nul:
+reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v TypesSupported /t REG_DWORD /d 7  1> nul:
+reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v CategoryMessageFile /t REG_SZ /d "%TargetDir%\lib\shibboleth-sp\NTEventLogAppender.dll"  1> nul:
+reg add "HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Shibboleth\Shibboleth Service Provider" /f /v EventMessageFile /t REG_SZ /d "%TargetDir%\lib\shibboleth-sp\NTEventLogAppender.dll"  1> nul:
 
 exit /b
diff --git a/WindowsInstall/install.bat b/WindowsInstall/install.bat
index f2270a8a..afcd029c 100644
--- a/WindowsInstall/install.bat
+++ b/WindowsInstall/install.bat
@@ -1,4 +1,4 @@
-Rem @echo off
+ at echo off
 Rem Install SP agent
 
 setlocal
@@ -27,7 +27,7 @@ if exist "%TargetDir%\lib\shibboleth-sp" (
 
 Rem Call generic "install/update" bat file shipped with this release
 
-mkdir  "%targetDir%"
+if not exist "%targetDir%" mkdir  "%targetDir%"
 cmd /c dist\dist-bin\doupdate.bat "%targetDir%"
 
 Rem Detect IIS and configure if there

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list