This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new 69b6c8c025 Use the full path when calling icacls.exe
69b6c8c025 is described below
commit 69b6c8c025cb3635bc7ab83a81f57e1fe5d41bc3
Author: Mark Thomas <[email protected]>
AuthorDate: Wed Jun 4 11:12:00 2025 +0100
Use the full path when calling icacls.exe
---
res/install-win/tomcat.nsi | 6 +++---
webapps/docs/changelog.xml | 4 ++++
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/res/install-win/tomcat.nsi b/res/install-win/tomcat.nsi
index 6a3605cffb..b694914d85 100644
--- a/res/install-win/tomcat.nsi
+++ b/res/install-win/tomcat.nsi
@@ -368,7 +368,7 @@ Section -post
; S-1-5-11 Authenticated users
;
; Grant admins, LocalService and Local System full control full control
- nsExec::ExecToStack 'icacls "$INSTDIR" /inheritance:r /grant
*S-1-5-19:(OI)(CI)(F) /grant *S-1-5-32-544:(OI)(CI)(F) /grant
*S-1-5-18:(OI)(CI)(F)'
+ nsExec::ExecToStack '$SYSDIR\icacls "$INSTDIR" /inheritance:r /grant
*S-1-5-19:(OI)(CI)(F) /grant *S-1-5-32-544:(OI)(CI)(F) /grant
*S-1-5-18:(OI)(CI)(F)'
Pop $0
Pop $1
StrCmp $0 "0" SetGroupPermissionsOk
@@ -381,7 +381,7 @@ Section -post
ClearErrors
; Make the icon readable to all authenticated users so it appears correctly
in the uninstall UI
- nsExec::ExecToStack 'icacls "$INSTDIR\tomcat.ico" /inheritance:e /grant
*S-1-5-11:(R)'
+ nsExec::ExecToStack '$SYSDIR\icacls "$INSTDIR\tomcat.ico" /inheritance:e
/grant *S-1-5-11:(R)'
Pop $0
Pop $1
StrCmp $0 "0" SetIconPermissionsOk
@@ -394,7 +394,7 @@ Section -post
ClearErrors
; Make the uninstaller readable and executable to all authenticated users so
the user that installed Tomcat can also uninstall it
- nsExec::ExecToStack 'icacls "$INSTDIR\Uninstall.exe" /inheritance:e /grant
*S-1-5-11:(RX)'
+ nsExec::ExecToStack '$SYSDIR\icacls "$INSTDIR\Uninstall.exe" /inheritance:e
/grant *S-1-5-11:(RX)'
Pop $0
Pop $1
StrCmp $0 "0" SetUninstallerPermissionsOk
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index ed4edbc784..f002a30119 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -304,6 +304,10 @@
<update>
Update Checkstyle to 10.25.0. (markt)
</update>
+ <fix>
+ Use the full path when the installer for Windows sets calls
+ <code>icacls.exe</code> to set file permissions. (markt)
+ </fix>
</changelog>
</subsection>
</section>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]