Friday, 7 October 2011

NSIS installer for 64-bit Windows

Here are some tips for creating (32-bit) NSIS installer which installs 64-bit application on 64-bit Windows.

There is no 64-bit NSIS Installer (yet) so only 32-bit version will be running on 64-bit host which means that 32-bit redirection will take place: by default its Installation Directory is "C:\Program Files (x86)" and it reads/writes only from HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node portion of the registry. This is not what we want so we need to enable access to native Win64 directories/registry for our Installer.

Our installer, as 32-bit application, will probably be used both for 32-bit and 64-bit installations. It therefore needs to be able to determine architecture of the CPU it runs on. x64 plug-in offers macro RunningX64 which returns true if installer is running on 64-bit Windows (under WoW64 emulation):

setup.nsi:
!include x64.nsh
...
${If} ${RunningX64}
   DetailPrint "Installer running on 64-bit host"
${EndIf}

Once we've detected 64-bit host, we need to:
  • set "C:\Program Files" as Installation Directory - use $PROGRAMFILES64 instead of $PROGRAMFILES
  • enable access to 64-bit registry - use SetRegView NSIS command

setup.nsi:
!include x64.nsh

;set initial value for $INSTDIR
InstallDir "$PROGRAMFILES\${MY_COMPANY}\${MY_APP}"
...
${If} ${RunningX64}
   DetailPrint "Installer running on 64-bit host"
   ; disable registry redirection (enable access to 64-bit portion of registry)
   SetRegView 64
   ; change install dir
   StrCpy $INSTDIR "$PROGRAMFILES64\${MY_COMPANY}\${MY_APP}"
${EndIf}

If installer needs to detect whether some 64-bit process is running, use FindProcDLL plug-in (there are couple of versions available but I found only this one - FindProcDLL_mod_by_hnedka.7z - working for me; please have a look at this forum thread). Download this archived file, unpack it and copy FindProcDLL.dll to your ..\NSIS\Plugins directory.

setup.nsi:
${If} ${RunningX64}
   FindProcDLL::FindProc "Some64BitProcess.exe"
   ${If} $R0 == 1
      DetailPrint "FindProcDLL::FindProc() returned 1 (process is running)"
   ${ElseIf} $R0 == 0
      DetailPrint "FindProcDLL::FindProc() returned 0 (process is not running)"
   ${Else}
      DetailPrint "FindProcDLL::FindProc() returned unexpected value"
   ${Endif}
${Else}
...

20 comments:

Unknown said...

If you need to install either a 32-bit or 64-bit file, you can do this:

${If} ${RunningX64}
File "/oname=MyFile.exe" "files\MyFile64.exe"
${Else}
File "files\MyFile.exe"
${EndIf}

If you need to register a DLL, you can do this:

${If} ${RunningX64}
ExecWait 'regsvr32.exe /s "$INSTDIR\MyDLL.dll"'
${Else}
RegDLL "$INSTDIR\MyDLL.dll"
${EndIf}

(Or use Library.nsh)

Linards said...

This is just 0,01 % of the whole story. Biggest pain is to compile / debug excisting script.

No Name said...

**SELLING SSN+DOB FULLZ**

CONTACT
Telegram > @leadsupplier
ICQ > 752822040
Email > leads.sellers1212@gmail.com

>>1$ each without DL/ID number
>>2$ each with DL
>>5$ each for premium (also included relative info)

*Will reduce price if buying in bulk
*Hope for a long term business

FORMAT OF LEADS/FULLZ/PROS

->FULL NAME
->SSN
->DATE OF BIRTH
->DRIVING LICENSE NUMBER WITH EXPIRY DATE
->COMPLETE ADDRESS
->PHONE NUMBER, EMAIL, I.P ADDRESS
->EMPLOYMENT DETAILS
->REALTIONSHIP DETAILS
->MORTGAGE INFO
->BANK ACCOUNT DETAILS

>Fresh Leads for tax returns & w-2 form filling
>Payment mode BTC, ETH, LTC, PayPal, USDT & PERFECT MONEY

''OTHER GADGETS PROVIDING''

>SSN+DOB Fullz
>CC with CVV
>Photo ID's
>Dead Fullz
>Carding Tutorials
>Hacking Tutorials
>SMTP Linux Root
>DUMPS with pins track 1 and 2
>Sock Tools
>Server I.P's
>HQ Emails with passwords

Email > leads.sellers1212@gmail.com
Telegram > @leadsupplier
ICQ > 752822040

THANK YOU

SCRUITNIZE said...

HIRE A CYBER SECURITY SPECIALIST / CRYPTANALYST

I’m Cyber Security Professional and do all kinds of related works and give 100% satisfaction and confidential to my clients

I am providing services to my valuable clients:-

* Crypto currency i.e. BTC / ETH / XRP
* Paypal Acc
* Bank Transfer
* Credit cards
* Spamming
* Carding
* Virus/Rate
* Private Root Scanner
* Private WHM Scanner

Contact details: scruitnizes@gmail.com

micheal pan said...

BE SMART AND BECOME RICH IN LESS THAN 3DAYS....It all depends on how fast 
you can be to get the new PROGRAMMED blank ATM card that is capable of
hacking into any ATM machine,anywhere in the world. I got to know about 
this BLANK ATM CARD when I was searching for job online about a month 
ago..It has really changed my life for good and now I can say I'm rich and 
I can never be poor again. The least money I get in a day with it is about 
$50,000.(fifty thousand USD) Every now and then I keeping pumping money 
into my account. Though is illegal,there is no risk of being caught 
,because it has been programmed in such a way that it is not traceable,it 
also has a technique that makes it impossible for the CCTVs to detect 
you..For details on how to get yours today, email the hackers on : (
atmmachinehackers1@gmail.com ). Tell your 
loved once too, and start to live large. That's the simple testimony of how 
my life changed for good...Love you all ...the email address again is ;
atmmachinehackers1@gmail.com

phillipsgrey said...

Here at Pot City Herbs Community , You can easily get various strains such as : Sour diesel , Lemon haze , Blue cookies , Blue Cookies Strain ,
Blue Cookies Strain Review , Platinum kush , Banana kush
Gelato #4 , Afghani strain , Wedding cake strain , Wedding crasher strain ,
Blue dream strain , Amnesia haze , purple Animal cookies strain
Gorilla glue #33, Purple punch strain, Strawnana Strain , Granddaddy purple,
Purple haze strain , Thin mints Cookies strain, Hindu Kush strain
blueberry headband strain ,Northern lights strain , White widows strain ,True OG
Silver haze strain, Big Bud Strain , Jack Herrer , American Dream , OG Kush.

BLUE COOKIES STRAIN

Wickr Me : Budboos
Email: Budboos@protonmail.com
Text/Call: +15672460706
Visit: Potcityherbs.com

NoveltyDMVExperts said...


Driving license test has always been hard for everyone to make it through but novelty DMV experts has put in place the best and easier ways for you to obtain a a drivers license of any country and Class from home without any stress with just a Click away . Fake driver license , How to get a fake drivers license that works , how to get a fake drivers license from the dmv , Fake license , FAKE DRIVER LICENSE
Buy fake driving license online , Fake drivers license , how to get a fake drivers license that works , fake driving, fake driving school, fake driving school full
fakedrivingschool .

PAPERWORK EXPERTS PROGRAMMERS said...

Very interesting article. Many articles I come across these days do not really provide anything that attracts others as yours, but believe me the way you interact is literally awesome I do respect that so much. I will instantly grab your rss feed to stay informed of any updates you make and as well take the advantage to share some latest information about

UNDETECTED FAKE BIRTH CERTIFICATE FOR FOREIGN PASSPORTS which many are not yet informed of the new and easiest way to get a dual citizenship through this birth certificate in any country and their advantages over the normal way. I will also take the advantage to ask for your permission to join our 179.3k members TELEGRAM GROUP
to share with us your ideas or any latest update on your blog.
Thanks I am Scott from Globex, we are expecting you on our platform
Thank so much for the great job. You can Call me Scott

Xploit.com said...



Hello all
am looking few years that some guys comes into the market
they called themselves hacker, carder or spammer they rip the
peoples with different ways and it’s a badly impact to real hacker
now situation is that peoples doesn’t believe that real hackers and carder scammer exists.
Anyone want to make deal with me any type am available.

Available Services

..Wire Bank Transfer all over the world

..Western Union Transfer all over the world

..Credit Cards (USA, UK, AUS, CAN, NZ)

..School Grade upgrade / remove Records

..Spamming Tool

..keyloggers / rats

..Social Media recovery

.. Teaching Hacking / spamming / carding (1/2 hours course)

discount for re-seller

Contact: 24/7

fixitrogers@gmail.com


BIG BROTHERS ILLU said...

Great specific article directly to the point. Many articles I come across these days do not really provide anything that attracts others as yours, but believe me the way you interact is literally awesome I do respect that so much. I will instantly get your link and stay informed of any updates you make and as well take the advantage to share some vital information regarding the. Hacked credit card numbers with cvv and zip code Here are easy ways, you can get a credit cards and code with high balance which can be use world-wild,I will also take the advantage to ask for your permission to join our TELEGRAM GROUP

Ethan Henry said...

I really appreciate the way you people freelance wordpress developer my plugin. Thanks!

Antonio Rainey said...

Wonderful piece you got here , I feel quite happy after I read your Article because I found out that we still have intelligent informative researchers who can still take time out of their busy schedule to put all this together I FOUND OUT HOW EASY IS TO SPOT A FAKE MALAYSIA PASSPORT I've bookmark your site and furthermore include RSS. keep us refreshed all the time.

Y’all don’t forget to join this EXPERTS TELEGRAM GROUP for more information about the Malaysian passport and and how to acquire them easily with no stress. You can also take advantage to learn and meet many Experts who will guide you on numerous techniques for anyone who love hacking and don’t know how to go about it .

Tools store said...






error404-store




- -- Spamming tools --




1-- cpanel https ssl secure
2-- shell ssl secure
3-- web-mail
4-- smtp
5-- rdp with send bluster
6-- scam pages
7-- ceo or cfo leads




-- Spy virus slinet Exploits --




1-- privet rat
2-- crypter exploits
3-- privet rdp hosting
4-- os andriod spy virus
5-- iso iPhone spy virus
6-- Nokia spy virus




- -- scanners brute-force ---




1-- linux roots
2-- cpanel scanner
3-- cpanel bruter
4-- shell scanner
5-- smtp scanner
6-- smtp bruter
7-- zimbra scanners


- -------------------


cpanel,shell,smtp,scampages,sender,ceo or cfo leads,rdp,spyvirus,crypter,exploits,scanners


Telegram:- @Donsmith000


icq :- @Donsmith000


https://error404-store.blogspot.com



Xploit.com said...







Hello all
am looking few years that some guys comes into the market
they called themselves hacker, carder or spammer they rip the
peoples with different ways and it’s a badly impact to real hacker
now situation is that peoples doesn’t believe that real hackers and carder scammer exists.
Anyone want to make deal with me any type am available

Available Services

..Wire Bank Transfer all over the world

..Western Union Transfer all over the world

..Credit Cards (USA, UK, AUS, CAN, NZ)

..School Grade upgrade / remove Records

..Spamming Tool

..keyloggers / rats

..Social Media recovery

.. Teaching Hacking / spamming / carding (1/2 hours course)

discount for re-seller

Contact: 24/7

fixitrogers@gmail.com




Unknown said...

I Never believe mobile spy and Mobile cloning works until i started suspecting my partner we have been together for the past 2years and we share most of all secret together then she feels to go join the gym for her to be doing some yoga and training but finial she fall for the dude tat trains her i was suspecting her the way she wake up early to Yugo gym and the way she goes during the evening time makes it to look more suspicious , I noticed at night my wife communicates with her Gym instructor via text messages and I have been really putting an eye on them but yet after her conversations she deletes all, and I keep asking my self what is going on which made me cross the line by going in search of a hacker to get  her phone checked for me SCHWARTZSOFTWAREHACKINGPROGRAM AT Gmail DOT com ,  the perfect hacker that could come through for me. This hacker provided me with all my wife deleted text messages that she has been deleting for the past 5 months since she stared this YAGO and after going through all her deleted messages with her YAGO instructor  at the gym it really came to my notice that my wife has been having a strong secret affair with her instructor  all thanks to SCHWARTZSOFTWAREHACKINGPROGRAM AT Gmail DOT com this hacker made my dream come through am really impressed with the kind of services he  to render to people.. Good job  message him on +1 704-313-9661

TIFFANY MURRAY said...

When I was down and I think that I have lost all my life savings out of the blues a friend refer me to the Great Wizard Brixton
I invested my life-saving in a bitcoin scheme and it grows very fast at a point I needed to withdraw part of my money so I could buy a small house for my family I found out it was a scam scheme so I contact Wizard Brixton to help me and recover my funds. he asked for the website and wallet of the Scheme and he gave me proof to show that my funds is in my wallet but they refused to let me withdraw it out Wizard Brixton helped me in Hacking into the wallet to recover my funds back contact him via Wizardbrixton at Gmail dot com WhatsApp : (+1- /807-23 ) 4-0428

Cyberz_Phoenix said...

We have the fresh and valid USA ssn leads
99% connectivity with quality
====================
*If you have any trust issue you can buy few to test
*Every leads are well checked and available 24 hours
*Fully cooperate with clients
====================
>> SSN+DOB
>> SSN+DOB+DL
>> Premium high score fullz (also included relative info)
====================
TUTORIALS AVAILABLE FOR
SPAMMING
CARDING
CASHOUTS
MOBILE DEPOSITS
>APPLE PAY & ANDROID TAP CASH
>BANK TRANSFER
>HOW TO CASHOUT DUMPS+PINS
>MOBILE DEPOSIT
====================
>SAFE SOCKS5 (USA)
>SMTP Linux Root
-->DUMPS+PINS
(How to use & create dumps with pins track 1 & 2)
=====================
Also SELLING
>SERVER I.P's & proxies in bulk
>USA EMAILS Combo
>Fresh Leads for tax returns & w-2 form filling
>CC's with CVV's (vbv & non-vbv)
>USA Photo ID'S (Front & back)
>Payment mode BTC, ETH, LTC, & USDT

Telegram : @Cyberz_Phoenix
ICQ : @1001829652
WICKR : @cyberzphoenix

Unknown said...

There aren’t enough words to describe or explain my wonderful experience with CYBERCREDITGURU a US based Russian h a c k e r s. In 2018, I had 205 BTC in my blockchain wallet but out of my carelessness I misplaced my password and recovery phrase. I really don’t know how to go about it until early this year, I came across a 5star review about them in a forum online by one Mrs. Kimberly and I reached out to them via text: +1 (650) 439 0624 and CYBERCREDITGURU (AT) GMAIL DOT COM. They responded immediately and helped recovered my lost BTC wallet within 4 days. Thanks to Team CyberGuru. I also had an extremely poor credit report of 403 with derogatory; late payment, repossession, collections and foreclosure. They also cleared all negative items from my credit report and upgraded my FICO score to 810 across all three major bureaus. Now with no doubts I can say 2022 is a great year for me as I am a proud owner of a new house and a car. All thanks to CYBERCREDITGURU once again. They are my messiah! I confidently recommend them to you.

Credit Credit Cards Developers said...

Fake-birth-certificate

A birth authentication is an essential record that archives the introduction of an individual. The expression "birth authentication" can allude to either the first archive ensuring the conditions of the birth or to a confirmed duplicate of or portrayal of the following enrollment of that birth
Much obliged for being honest, I will quickly share your blog on my Facebook and Instagram stage to numerous different individuals from my gathering and furthermore exploit to impart to you the new

UNDETECTED FAKE BIRTH CERTIFICATE FOREIGNER USE TO OBTAIN PASSPORTS ABROAD FREELY which many are ignorant of at the moment, it is also the easiest way to obtain dual nationality through this birth certificate in any country. I request your permission to join our 379.3k members TELEGRAM GROUP
to share with us your daily post for it to also reach my audience. Thanks, I am Scott from Globex, we await you on our platform to.
You can call me Scott.

DANIEL RAY said...

THE ONLY GENUINE AND GUARANTEED RECOVERY AGENT EVER ( MORRIS GRAY )

I was scammed of $573,000 worth of bitcoins with a scam forest investment unknowingly then, I didn’t know what to do.. I felt like committing suicide, but I fortunately for me I had a good start again after my friend introduced me to a cyber crime investigator ( Mr Morris Gray ) who helped me recovered all my stolen funds and profit that where held form me, by those bastard scammers, in just few days of working with him, if you feel scammed with fake forex company you don’t need to be worried, you can Text Him Via his Email: Morris Gray 830@ gmail . com or WhatsApp +1 (607) 698-0239. And he will recover your stolen coins back in your wallet account in full...he has all it takes and his a very straight forward person!!!
I recommend him too anyone out there, who has fall a victim of crypto scam before.