|
![]() |
|
Thread Tools | Search this Thread | Display Modes |
![]() |
#1 | ||
Junior Member
Join Date: Jul 2011
Posts: 9
|
In 64bit installer AccessControl fail to set registry permission
I was using NSIS AccessControl plug-in to grant registry access permission
Quote:
and SetRegView 64 Now Quote:
Any help will be greatly appreciated Thank you, Riju |
||
![]() |
![]() |
![]() |
#2 | |
Major Dude
|
Are you running 32bit application on x64 machine?
If yes then this situation is correct because 32bit applications use Wow6432Node in Registry. Your assumption is wrong: Quote:
Cool looking installers with custom design: www.graphical-installer.com Create Setup Pages easily: www.install-designer.com Build installers in Visual Studio 2005-2022: www.visual-installer.com or RAD Studio 2009 - 11 Alexandria: www.rad-installer.com |
|
![]() |
![]() |
![]() |
#3 | ||
Junior Member
Join Date: Jul 2011
Posts: 9
|
Hi T. Slappy,
I am upgrading the installer script with guideline provided in this link http://bojan-komazec.blogspot.com/20...t-windows.html I am able to read\write registry from HKLM\Software\Demo after using "SetRegView 64". Quote:
Quote:
Thank you, Riju |
||
![]() |
![]() |
![]() |
#4 |
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
Could it be that the AccessControl plugin cannot handle x64 registry yet?
|
![]() |
![]() |
![]() |
#5 |
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
Could it be that the AccessControl plugin doesn't support x64 registry yet?
|
![]() |
![]() |
![]() |
#6 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
AccessControl plug-in needs updating to handle SetRegView. I will do it when I have some time (maybe tomorrow).
Stu |
![]() |
![]() |
![]() |
#7 |
Junior Member
Join Date: Jul 2011
Posts: 9
|
Hi Stu,
So nice of you ![]() Thank you, Riju |
![]() |
![]() |
![]() |
#8 |
Junior Member
Join Date: Jul 2011
Posts: 9
|
What i read from internet in order to accomplish this; we need to use advapi32.dll's RegSetKeySecurity in the AccessControl plugin.
|
![]() |
![]() |
![]() |
#9 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
It took a little longer than expected due to SetNamedSecurityInfo/GetNamedSecurityInfo complete lack of support for KEY_WOW64_64KEY (as you pointed out) so a lot of the code had to be changed quite drastically. It may also mean the plug-in will no longer work on Windows 2000, but we may have to live with that.
v1.0.5.0 - 25th January 2012 ~ Afrow UK
Stu |
![]() |
![]() |
![]() |
#10 |
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,548
|
IMHO the Ansi version needs to support NT4/Win95 (I don't know what the old behavior was but it can just return ok on 9x) and the unicode build 2000+ (It is unclear at this point if NT4 will be supported as unicode)
IntOp $PostCount $PostCount + 1 |
![]() |
![]() |
![]() |
#11 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
When was ConvertSidToStringSid/ConvertStringSidToSid added to Windows? The plug-in has been using those for some time. Now it's using RegOpenKeyEx as well.
Stu |
![]() |
![]() |
![]() |
#12 |
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,548
|
RegOpenKeyEx was added in Win95/NT4 IIRC and I don't remember off the top of my head but I'm guessing ConvertSidToStringSid was added in 2000 (You cannot trust MSDN, you must check the dll exports)
IntOp $PostCount $PostCount + 1 |
![]() |
![]() |
![]() |
#13 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
How about RegSetKeySecurity? I will look into writing replacements for ConvertSidToStringSid/ConvertStringSidToSid.
Stu |
![]() |
![]() |
![]() |
#14 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
v1.0.6.0 - 26th January 2012 - Afrow UK
http://nsis.sourceforge.net/AccessControl_plug-in Stu |
![]() |
![]() |
![]() |
#15 |
Major Dude
Join Date: Oct 2006
Posts: 1,892
|
Hate to be a nagger, but... Wasn't NT4 also unicode? Not that I feel strongly about NT4 support one way or the other, but yeah.
|
![]() |
![]() |
![]() |
#16 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
As Anders says I don't think Unicode NSIS supports below Windows 2000 anyway so there is no point the Unicode plug-in doing so.
Edit: If someone needs the Unicode build for NT4 they can just rebuild with ACCESS_CONTROL_NT4 preprocessor directive. Otherwise the Unicode build links to the native Windows 2000+ API's to save on code size. Stu |
![]() |
![]() |
![]() |
#17 |
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,548
|
I did not check out the code yet but I hope you are only going down the wow64 path on NT5.2+, I don't know what happens if you pass the WOW64 flag to older registry functions...
IntOp $PostCount $PostCount + 1 |
![]() |
![]() |
![]() |
#18 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
According to MSDN KEY_WOW64_64KEY is ignored on 32-bit Windows (and Windows 2000) so I assume that means older versions of Windows too. The registry functions are only used if SetRegView 64 is set but I suppose a test for a 64-bit OS would be good too.
Stu |
![]() |
![]() |
![]() |
#19 |
Junior Member
Join Date: Jul 2011
Posts: 9
|
Thank you Stu... i will test it tomorrow and let you know the feedbacks
Riju |
![]() |
![]() |
![]() |
#20 |
Senior Member
Join Date: May 2007
Location: Maple Grove, Minnesota
Posts: 134
|
![]()
Is there a NSIS 64 bit compiled engine/install available somewhere for download?
|
![]() |
![]() |
![]() |
#21 |
Moderator
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
|
No. Why do you need it?
Stu |
![]() |
![]() |
![]() |
#22 |
Moderator
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,548
|
IntOp $PostCount $PostCount + 1 |
![]() |
![]() |
![]() |
|
Tags |
accesscontrol, registry, x64 |
Thread Tools | Search this Thread |
Display Modes | |
|
|