Click here to Skip to main content
15,890,527 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
I am trying to install a windows application using a setup file.

From what I could inderstand from various sources to launch the app automatically on install you need to create a custom action under install to run the primary action file and set its installer class property to false.

The setup works fine without this but does not launch the app.
Now when I run the setup I get the following error.
System.Security.Principal.IdentityNotMappedException: Some or all identity references could not be translated.
   at System.Security.Principal.NTAccount.Translate(IdentityReferenceCollection sourceAccounts, Type targetType, Boolean forceSuccess)
   at System.Security.Principal.NTAccount.Translate(Type targetType)
   at System.Security.AccessControl.CommonObjectSecurity.ModifyAccess(AccessControlModification modification, AccessRule rule, Boolean& modified)
   at System.Security.AccessControl.CommonObjectSecurity.AddAccessRule(AccessRule rule)
   at MyApp.Form1.Form1_Load(Object sender, EventArgs e)
   at System.Windows.Forms.Form.OnLoad(EventArgs e)
   at System.Windows.Forms.Form.OnCreateControl()
   at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   at System.Windows.Forms.Control.CreateControl()
   at System.Windows.Forms.Control.WmShowWindow(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ContainerControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WmShowWindow(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


Any suggestions please?
Posted
Comments
luisnike19 5-Mar-11 18:14pm    
Check the event log. Maybe we can have another clue
milenalukic 5-Mar-11 18:59pm    
I do not know if this is the right one. I found it under security - Audit Success. Nothing else seems to make sense.

What has been happening is that it gives the above error and an option to continue. When selecting continue it launches but does not close the installer.

Log Name: Security
Source: Microsoft-Windows-Security-Auditing
Date: 05/03/2011 22:35:06
Event ID: 4672
Task Category: Special Logon
Level: Information
Keywords: Audit Success
User: N/A
Computer: Fleur-PC
Description:
Special privileges assigned to new logon.

Subject:
Security ID: SYSTEM
Account Name: SYSTEM
Account Domain: NT AUTHORITY
Logon ID: 0x3e7

Privileges: SeAssignPrimaryTokenPrivilege
SeTcbPrivilege
SeSecurityPrivilege
SeTakeOwnershipPrivilege
SeLoadDriverPrivilege
SeBackupPrivilege
SeRestorePrivilege
SeDebugPrivilege
SeAuditPrivilege
SeSystemEnvironmentPrivilege
SeImpersonatePrivilege
Event Xml:
<event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<system>
<Provider Name="Microsoft-Windows-Security-Auditing" Guid="{54849625-5478-4994-A5BA-3E3B0328C30D}" />
<eventid>4672
<version>0
<level>0
<task>12548
<opcode>0
<keywords>0x8020000000000000
<timecreated systemtime="2011-03-05T22:35:06.512727200Z">
<eventrecordid>36395
<correlation>
<execution processid="552" threadid="5624">
<channel>Security
<computer>Fleur-PC
<security>

<eventdata>
S-1-5-18
SYSTEM
NT AUTHORITY
0x3e7
SeAssignPrimaryTokenPrivilege
SeTcbPrivilege
SeSecurityPrivilege
SeTakeOwnershipPrivilege
SeLoadDriverPrivilege
SeBackupPrivilege
SeRestorePrivilege
SeDebugPrivilege
SeAuditPrivilege
SeSystemEnvironmentPrivilege
SeImpersonatePrivilege



1 solution

Have a look at these similar discussions here:
Link 1[^]
Link 2[^]
Link 3[^]

If needed, do have other links here[^].
 
Share this answer
 
Comments
milenalukic 6-Mar-11 4:52am    
I am not using MOSS or Sharepoint - I found those articles.

The third one, I cannot really understand. The only thing I imagine could cause the problem would be that I modify the registry on load to be able to save usernames and passwords. Could this be the issue?
Sandeep Mewara 6-Mar-11 4:55am    
Might be. It is not necessary that you have to be using MOSS/Sharepoint to refer them. Links are for probably reasons kind of which are more of environent kind of thing common for all.

If there would be an issue trying it then think before doing it or else a quick check as suggested should be of no harm.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900