[wix-users] localized names for NT AUTHORITY\NETWORK SERVICE and BUILTIN\Administrators

Edwin Castro egcastr at gmail.com
Thu Nov 18 10:06:22 PST 2021


I think those properties are set via an MSI custom action but it looks like
you're building a burn bundle. That might explain why nothing happens.

To try to keep concepts separate, burn bundles use <Variable/> not
<Property/>.

I suspect you'll need to update your BA to set similar variables yourself.
For a native BA you'll likely need to use CreateWellKnownSid
and LookupAccountSidW.

I'm not sure if there is an existing managed API to get these if you are
using a managed BA.

https://docs.microsoft.com/en-us/windows/win32/api/securitybaseapi/nf-securitybaseapi-createwellknownsid
https://docs.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-lookupaccountsidw

--
Edwin G. Castro


On Thu, Nov 18, 2021 at 5:58 AM Evan Ross via wix-users <
wix-users at lists.wixtoolset.org> wrote:

>  Sorry I grabbed the wrong parameter from my VS-generated command line.  I
> definitely see WixUtilExtension in there though.
> -ext "C:\Program Files (x86)\WiX Toolset v3.11\bin\\WixNetFxExtension.dll"
> -ext "C:\Program Files (x86)\WiX Toolset v3.11\bin\\WixUtilExtension.dll"
> -ext "C:\Program Files (x86)\WiX Toolset v3.11\bin\\WixBalExtension.dll"
> Bundle.wxs
>
>     On Thursday, November 18, 2021, 08:51:44 AM EST, Mike Henseler <
> m.henseler at simfront.com> wrote:
>
>
> I believe, you Should see
>
> light.exe  (-ext "C:\Program Files (x86)\WiX Toolset
> v3.11\bin\\WixUtilExtension.dll")
>
> you still may not have it linking correctly
>
>
>
> You are showing WixNetFxExtension.dll as per your message below, I believe
> this is a different library.
>
>
>
> I don’t use VisualStudio all my builds are done from cmd line and use
> WixUtilExtension all the time.
>
>
>
>
>
> From: Evan Ross <eross99 at yahoo.com>
> Sent: November 18, 2021 8:34 AM
> To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>; Mike
> Henseler <m.henseler at simfront.com>
> Subject: Re: [wix-users] localized names for NT AUTHORITY\NETWORK SERVICE
> and BUILTIN\Administrators
>
>
>
> I believe that I am linking WixUtilExtensions properly.  I'm using the
> Visual Studio 2019 extension and have the reference to WixUtilExtension.dll
> (v3.11) in there.  I can see the reference to it in my light.exe  (-ext
> "C:\Program Files (x86)\WiX Toolset v3.11\bin\\WixNetFxExtension.dll")
>
>
>
> Also have the namespace reference (xmlns:util="
> http://schemas.microsoft.com/wix/UtilExtension") in there
>
>
>
> Thanks
>
> Evan
>
>
>
> On Thursday, November 18, 2021, 07:21:56 AM EST, Mike Henseler <
> m.henseler at simfront.com> wrote:
>
>
>
>
>
> Did you include WixUtilExtensions when linking?
> https://wixtoolset.org/documentation/manual/v3/customactions/osinfo.html
>
>
> -----Original Message-----
> From: wix-users <wix-users-bounces at lists.wixtoolset.org> On Behalf Of
> Evan Ross via wix-users
> Sent: November 17, 2021 11:17 PM
> To: wix-users at lists.wixtoolset.org
> Cc: Evan Ross <eross99 at yahoo.com>
> Subject: [wix-users] localized names for NT AUTHORITY\NETWORK SERVICE and
> BUILTIN\Administrators
>
> Hi all,
> New to the list and I'm trying to solve a problem with a SQL Server
> bootstrapper install on a PC that might not be English Language.
> Because of this I need to be able to refer to the NT AUTHORITY\NETWORK
> SERVICE and BUILTIN\Administrators accounts in the InstallCommand line in
> their localized names on the machine. (for example
> NT-AUTORITÄT\NETZWERKDIENST on a German language machine)
>
>
> I have the following fragment after my bundle to handle the SQL install
> <Fragment>
>     <PropertyRef Id="WIX_ACCOUNT_ADMINISTRATORS"/>
>     <PropertyRef Id="WIX_ACCOUNT_NETWORKSERVICE"/>
>
>     <PackageGroup Id="SQLSERVER">
>       <ExePackage Id="Sql2019Express"
>                 DisplayName="SQL Server 2019 Express"
>                 Cache="yes"
>                 Compressed="yes"
>                 PerMachine="yes"
>                 Permanent="no"
>                 Vital="yes"
>                 Name="SQLEXPR_x64_ENU.exe"
>                 SourceFile="Resources\SQLEXPR_x64_ENU.exe"
>                 InstallCommand="/ACTION=Install
>                                 /INSTANCENAME=$(var.InstanceName)
>                                 /FEATURES=SQL
>                                 /SECURITYMODE=SQL
>                                 /SAPWD=[SqlVariable]
>                                 /TCPENABLED=1
>
> /SQLSVCACCOUNT="[WIX_ACCOUNT_NETWORKSERVICE]"
>                                 /SQLSVCSTARTUPTYPE=Automatic
>
> /SQLSYSADMINACCOUNTS=[WIX_ACCOUNT_ADMINISTRATORS]
>                                 /ADDCURRENTUSERASSQLADMIN=FALSE
>                                 /Q
>                                 /IAcceptSQLServerLicenseTerms"
>                 UninstallCommand="/Action=Uninstall
> /INSTANCENAME=$(var.InstanceName) /FEATURES=SQL /Q ">
>
>         <ExitCode Value ="3010" Behavior="forceReboot" />
>       </ExePackage>
>     </PackageGroup>
>   </Fragment>
>
> For whatever reason the values for WIX_ACCOUNT_NETWORKSERVICE and
> WIX_ACCOUNT_ADMINISTRATORS are returning nothing as seen in the install log
> (see SQLSVCACCOUNT and SQLSYSADMINACCOUNTS )
>
> C:\ProgramData\Package
> Cache\004A55528A3D38224B71C2DE0D1A3291DAEF5E0F\SQLEXPR_x64_ENU.exe,
> arguments: '"C:\ProgramData\Package
> Cache\004A55528A3D38224B71C2DE0D1A3291DAEF5E0F\SQLEXPR_x64_ENU.exe"
> /ACTION=Install /INSTANCENAME=***** /FEATURES=SQL /SECURITYMODE=SQL
> /SAPWD=***** /TCPENABLED=1 /SQLSVCACCOUNT="" /SQLSVCSTARTUPTYPE=Automatic
> /SQLSYSADMINACCOUNTS= /ADDCURRENTUSERASSQLADMIN=FALSE /Q
> /IAcceptSQLServerLicenseTerms'
>
> Am I not getting the PropertyRef at the right time?  I'm probably a little
> confused about how it works and what it should refer to.
>
> Any help or ideas here will be greatly appreciated.  Thanks!
>
>
>
>
>
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
>
>
>
> ***** This email was sent outside of your organization *****
>
>
>
>
>
> ***** This email was sent outside of your organization *****
>
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/



More information about the wix-users mailing list