<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://nsis.sourceforge.io/mediawiki/index.php?action=history&amp;feed=atom&amp;title=Simple_IsDomainMember_Test</id>
	<title>Simple IsDomainMember Test - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://nsis.sourceforge.io/mediawiki/index.php?action=history&amp;feed=atom&amp;title=Simple_IsDomainMember_Test"/>
	<link rel="alternate" type="text/html" href="https://nsis.sourceforge.io/mediawiki/index.php?title=Simple_IsDomainMember_Test&amp;action=history"/>
	<updated>2026-04-23T21:32:58Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.17</generator>
	<entry>
		<id>https://nsis.sourceforge.io/mediawiki/index.php?title=Simple_IsDomainMember_Test&amp;diff=20041&amp;oldid=prev</id>
		<title>Zinthose: /* About */  Spelling Corrections</title>
		<link rel="alternate" type="text/html" href="https://nsis.sourceforge.io/mediawiki/index.php?title=Simple_IsDomainMember_Test&amp;diff=20041&amp;oldid=prev"/>
		<updated>2011-05-24T23:12:13Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;About: &lt;/span&gt;  Spelling Corrections&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;â† Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 23:12, 24 May 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot;&gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{PageAuthor|Zinthose}}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{PageAuthor|Zinthose}}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== About ==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== About ==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is a very basic domain &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;memnership &lt;/del&gt;testing macro intended for use in companies that use &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;nsis &lt;/del&gt;to repackage software.  This has been &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;successuly &lt;/del&gt;tested on Windows XP and Windows XP x64 but should work fine on Windows 2000 and newer.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;This is a very basic domain &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;membership &lt;/ins&gt;testing macro intended for use in companies that use &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;NSIS &lt;/ins&gt;to repackage software.  This has been &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;successfully &lt;/ins&gt;tested on Windows XP and Windows XP x64 but should work fine on Windows 2000 and newer.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;I also added a precompiler check to automatically add the dependencies if the code is pasted into the global namespace.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;I also added a precompiler check to automatically add the dependencies if the code is pasted into the global namespace.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key n22049_wiki-wiki_:diff::1.12:old-18087:rev-20041 --&gt;
&lt;/table&gt;</summary>
		<author><name>Zinthose</name></author>
	</entry>
	<entry>
		<id>https://nsis.sourceforge.io/mediawiki/index.php?title=Simple_IsDomainMember_Test&amp;diff=18087&amp;oldid=prev</id>
		<title>Zinthose: Initial Release</title>
		<link rel="alternate" type="text/html" href="https://nsis.sourceforge.io/mediawiki/index.php?title=Simple_IsDomainMember_Test&amp;diff=18087&amp;oldid=prev"/>
		<updated>2010-02-05T21:42:50Z</updated>

		<summary type="html">&lt;p&gt;Initial Release&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{PageAuthor|Zinthose}}&lt;br /&gt;
== About ==&lt;br /&gt;
This is a very basic domain memnership testing macro intended for use in companies that use nsis to repackage software.  This has been successuly tested on Windows XP and Windows XP x64 but should work fine on Windows 2000 and newer.&lt;br /&gt;
&lt;br /&gt;
I also added a precompiler check to automatically add the dependencies if the code is pasted into the global namespace.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&amp;lt;highlight-nsis&amp;gt;/*  Don&amp;#039;t forget to add these!&lt;br /&gt;
    --------------------------&lt;br /&gt;
      !include &amp;quot;LogicLib.nsh&amp;quot;&lt;br /&gt;
      !include &amp;quot;StrFunc.nsh&amp;quot;&lt;br /&gt;
      ${StrStr}&lt;br /&gt;
      ${StrRep}&lt;br /&gt;
    --------------------------*/&lt;br /&gt;
Section IsDomainMember_Example&lt;br /&gt;
    &lt;br /&gt;
    ${If} ${IsDomainMember} &amp;quot;internal.microsoft.com&amp;quot;&lt;br /&gt;
        MessageBox MB_OK &amp;#039;This will NEVER run!&amp;#039;&lt;br /&gt;
    ${Else}&lt;br /&gt;
        MessageBox MB_OK &amp;#039;Hello normal people!&amp;#039;&lt;br /&gt;
    ${EndIf} &lt;br /&gt;
    &lt;br /&gt;
SectionEnd&amp;lt;/highlight-nsis&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Macro ==&lt;br /&gt;
&amp;lt;highlight-nsis&amp;gt;/*  IsDomainMember LogicLib Extention&lt;br /&gt;
    Example:&lt;br /&gt;
        ${If} ${IsDomainMember} &amp;quot;internal.mycompany.com&amp;quot;&lt;br /&gt;
    ----------------------------------------*/&lt;br /&gt;
    !ifmacrondef _IsDomainMember&lt;br /&gt;
        !ifndef LOGICLIB | STRFUNC | StrStr_INCLUDED | StrRep_INCLUDED&lt;br /&gt;
            !ifdef __GLOBAL__&lt;br /&gt;
                !ifndef LOGICLIB&lt;br /&gt;
                    !include &amp;quot;LogicLib.nsh&amp;quot;&lt;br /&gt;
                !endif&lt;br /&gt;
                !ifndef STRFUNC&lt;br /&gt;
                    !include &amp;quot;StrFunc.nsh&amp;quot;&lt;br /&gt;
                !endif&lt;br /&gt;
                !ifdef STRFUNC&lt;br /&gt;
                    !ifndef StrStr_INCLUDED&lt;br /&gt;
                         ${StrStr}&lt;br /&gt;
                    !endif&lt;br /&gt;
                    !ifndef StrRep_INCLUDED&lt;br /&gt;
                         ${StrRep}&lt;br /&gt;
                    !endif&lt;br /&gt;
                !endif&lt;br /&gt;
            !else&lt;br /&gt;
                !error `The IsDomainMember LogicLib extention is missing a required dependancy: LogicLib.nsh | StrFunc.nsh [StrStr &amp;amp; StrRep]`&lt;br /&gt;
            !endif&lt;br /&gt;
        !endif&lt;br /&gt;
        !macro _IsDomainMember _a _b _t _f&lt;br /&gt;
            !insertmacro _LOGICLIB_TEMP&lt;br /&gt;
            /*  Get the System&amp;#039;s Distinguished Name from the registry&lt;br /&gt;
                -----------------------------------------------------*/&lt;br /&gt;
                SetRegView 64&lt;br /&gt;
                ClearErrors&lt;br /&gt;
                ReadRegStr $_LOGICLIB_TEMP HKLM `SOFTWARE\Microsoft\Windows\CurrentVersion\Group Policy\State\Machine` `Distinguished-Name`&lt;br /&gt;
                SetRegView lastused&lt;br /&gt;
                &lt;br /&gt;
            /*  If we were unable to get the Distinguished Name so we&amp;#039;ll&lt;br /&gt;
                asume the system is not a member of a domain.&lt;br /&gt;
                --------------------------------------------------------*/&lt;br /&gt;
                IfErrors `${_f}`&lt;br /&gt;
&lt;br /&gt;
            /*  Parse the DistinguishedName for the system&amp;#039;s domain name.&lt;br /&gt;
                -------------------------------------------------------*/  &lt;br /&gt;
                ${StrStr} $_LOGICLIB_TEMP $_LOGICLIB_TEMP &amp;quot;DC=&amp;quot;&lt;br /&gt;
                IfErrors `${_f}`&lt;br /&gt;
                ${StrRep} $_LOGICLIB_TEMP $_LOGICLIB_TEMP &amp;quot;,DC=&amp;quot; &amp;quot;.&amp;quot;&lt;br /&gt;
                IfErrors `${_f}`&lt;br /&gt;
                StrCpy $_LOGICLIB_TEMP $_LOGICLIB_TEMP ${NSIS_MAX_STRLEN} 3&lt;br /&gt;
                IfErrors `${_f}`&lt;br /&gt;
&lt;br /&gt;
            /*  Do we have a match?&lt;br /&gt;
                -------------------------------------------------------*/  &lt;br /&gt;
                !insertmacro _== $_LOGICLIB_TEMP ${_b} `${_t}` `${_f}`&lt;br /&gt;
                &lt;br /&gt;
        !macroend&lt;br /&gt;
        !ifndef IsDomainMember&lt;br /&gt;
            !define IsDomainMember `&amp;quot;&amp;quot; IsDomainMember`&lt;br /&gt;
        !endif&lt;br /&gt;
    !endif&amp;lt;/highlight-nsis&amp;gt;&lt;br /&gt;
[[Category:System Related Functions]]&lt;/div&gt;</summary>
		<author><name>Zinthose</name></author>
	</entry>
</feed>