<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mark's Website</title>
	<atom:link href="http://mark.inderhees.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://mark.inderhees.net</link>
	<description></description>
	<lastBuildDate>Sun, 17 Jan 2010 09:26:16 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Asia pictures up</title>
		<link>http://mark.inderhees.net/2010/01/17/asia-pictures-up/</link>
		<comments>http://mark.inderhees.net/2010/01/17/asia-pictures-up/#comments</comments>
		<pubDate>Sun, 17 Jan 2010 09:26:16 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=127</guid>
		<description><![CDATA[My pictures from yet another trip to Asia are now up, check them out.
]]></description>
			<content:encoded><![CDATA[<p>My <a href="http://mark.inderhees.net/asia-trip-jan-2010/">pictures from yet another trip to Asia</a> are now up, check them out.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2010/01/17/asia-pictures-up/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Synergy Client &#8220;When Computer Starts&#8221; Fix</title>
		<link>http://mark.inderhees.net/2009/12/20/synergy-client-when-computer-starts-fix/</link>
		<comments>http://mark.inderhees.net/2009/12/20/synergy-client-when-computer-starts-fix/#comments</comments>
		<pubDate>Mon, 21 Dec 2009 00:17:15 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=87</guid>
		<description><![CDATA[If you use the wonderful tool Synergy to share your keyboard and mouse over the network, you have probably noticed that starting with Windows Vista and now Windows 7 that setting the client to run &#8220;When Computer Starts&#8221; no longer works like it did with XP.  Unfortunately, this project has become unmaintained so I [...]]]></description>
			<content:encoded><![CDATA[<p>If you use the wonderful tool <a href="http://synergy2.sourceforge.net/">Synergy</a> to share your keyboard and mouse over the network, you have probably noticed that starting with Windows Vista and now <a href="http://www.microsoft.com/windows/windows-7/">Windows 7</a> that setting the client to run &#8220;When Computer Starts&#8221; no longer works like it did with XP.  Unfortunately, this project has become unmaintained so I updated the source code to work with Vista/Win7 now.  <strong>Note</strong>, setting the Synergy Server to run &#8220;When Computer Starts&#8221; is still broken and will cause your mouse to freeze, maybe I&#8217;ll look into that bug too.</p>
<p>Here&#8217;s the fix.  Unzip and replace the three files into your Synergy folder under Program Files.  This is distributed under the <a href="http://synergy2.sourceforge.net/license.html">current license of Synergy</a>.<br />
<strong>Download</strong>: <a href="http://mark.inderhees.net/wp-content/uploads/2009/12/synergy.zip">Synergy.zip</a></p>
<p>Also, check out <a href="http://code.google.com/p/synergy-plus/">Synergy+</a> as they are now working on this project.</p>
<p>Source code: <a href="http://mark.inderhees.net/wp-content/uploads/2009/12/SynergyClientFixDiff.txt">diff of changes to Synergy2 tag 1.3.1</a>.</p>
<h3>Technoblable</h3>
<p>Some people think that Synergy stopped working as a service, i.e. not being able to type in your user name and password at the log in prompt, because Vista had created a better security model.  This is just not correct<span id="more-87"></span>, as it would be impossible to protect your computer at this screen if you have installed a program with admin rights.  That&#8217;s why it&#8217;s so important to know what programs you put on your computer, if you install something with admin privileges it basically has full access to your computer minus encrypted data.  That&#8217;s just how OS are, even Linux is susceptible as soon as you install a program with sufficient privileges.</p>
<p>What changed starting with Vista was how <a href="http://en.wikipedia.org/wiki/Windows_service">Windows Services</a> have access to your desktop.  Services are things designed to run in the background of your PC, but they still could create a window on your screen.  Microsoft wanted to separate the Services from the user, so they create a <a href="http://www.microsoft.com/whdc/system/sysinternals/Session0Changes.mspx">Windows Session</a> for services.  Windows Sessions are basically a logged in user, so on your Vista/Win7 machine right now there are at least two sessions: Session 0 for services and Session 1 for the first user logged into the system.  In XP, services and the first logged in user both shared Session 0.</p>
<p>How this broke Synergy is that the synergy client service is started in Session 0 and connects to that desktop. You can actually access this desktop by forcing a window to appear there; use <a href="http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx">psexec</a> tool and run something like <i>psexec -s -i 0 mspaint.exe</i>.  You&#8217;ll be prompted about an <a href="http://msdn.microsoft.com/en-us/library/ms683502%28VS.85%29.aspx">Interactive Service</a> and if you click on the button to view the message you&#8217;ll see a shell that looks like Windows 95, mspaint running, and your Synergy Client will work here!  Synergy can also be broken in a similar manor on Windows XP.  On XP, <a href="http://support.microsoft.com/kb/279765">enable fast user switching</a> and switch to a new account.  You&#8217;ll notice that Synergy no longer works as this user is running in Session 1.</p>
<p>The fix to get this working is to have the service start the Synergy Client in the user&#8217;s session.  This can be done using the function <a href="http://msdn.microsoft.com/en-us/library/ms682429%28VS.85%29.aspx">CreateProcessAsUser</a>.  To get this working I used the following strategy.</p>
<p><strong>Starting a Service&#8217;s Process in User&#8217;s Session</strong></p>
<p><a href="http://msdn.microsoft.com/en-us/library/aa378729%28VS.85%29.aspx">ImpersonateSelf</a> to assign LocalSystem&#8217;s access token to the calling thread.<br />
<a href="http://msdn.microsoft.com/en-us/library/aa379296%28VS.85%29.aspx">OpenThreadToken</a> to get the access token.<br />
<a href="http://msdn.microsoft.com/en-us/library/aa383835%28VS.85%29.aspx">WTSGetActiveConsoleSessionId</a> to get the user session ID, this is most usually just 1.<br />
<a href="http://msdn.microsoft.com/en-us/library/aa379591%28VS.85%29.aspx">SetTokenInformation</a> to change the LocalSystem&#8217;s Session ID from 0 to the user&#8217;s Session ID.<br />
<a href="http://msdn.microsoft.com/en-us/library/ms682429%28VS.85%29.aspx">CreateProcessAsUser</a> to launch the Synergy Client.</p>
<p>I edited <a href="http://synergy2.svn.sourceforge.net/viewvc/synergy2/tags/1.3.1/">Synergy2 tag version 1.3.1</a>.  To see all of my changes and a more detailed explaination of the above referer to the function CArchDaemonWindows::createProcessOnCurrentSession() in my <a href="http://mark.inderhees.net/wp-content/uploads/2009/12/SynergyClientFixDiff.txt">Synergy Client fix diff file</a>.</p>
<p>Unfortunately, this either caused a regression or exposed a bug in the Synergy Server code.  If you try and run the server as a service, when you move the mouse to switch screens the mouse will stop working.  The keyboard will work and you can escape to the host pc by pressing ctrl+alt+delete.  The guys at <a href="http://code.google.com/p/synergy-plus/">Synergy+</a> are <a href="http://code.google.com/p/synergy-plus/issues/detail?id=26&#038;colspec=ID%20Stars%20Type%20Status%20Priority%20Milestone%20Owner%20Summary">working on a fix to the client and server service issues</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/12/20/synergy-client-when-computer-starts-fix/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Car Radio Auxiliary Input</title>
		<link>http://mark.inderhees.net/2009/02/10/car-radio-auxiliary-input/</link>
		<comments>http://mark.inderhees.net/2009/02/10/car-radio-auxiliary-input/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 05:22:14 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=83</guid>
		<description><![CDATA[I did a small mod to my car, check it out on my page Car Radio.
]]></description>
			<content:encoded><![CDATA[<p>I did a small mod to my car, check it out on my page <a href="/car-radio/">Car Radio</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/02/10/car-radio-auxiliary-input/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Rotating Posts</title>
		<link>http://mark.inderhees.net/2009/02/08/rotating-posts/</link>
		<comments>http://mark.inderhees.net/2009/02/08/rotating-posts/#comments</comments>
		<pubDate>Mon, 09 Feb 2009 01:00:38 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=75</guid>
		<description><![CDATA[I made another plugin for WordPress called Rotating Posts. This plugin allows you to easily create customizable rotating posts like those seen on popular news sites.
See a demo
See a customized CSS version
Please post questions on the wordpress.org forum at http://wordpress.org/tags/rotating-posts.
]]></description>
			<content:encoded><![CDATA[<p>I made another plugin for WordPress called <a href="http://wordpress.org/extend/plugins/rotating-posts/">Rotating Posts</a>. This plugin allows you to easily create customizable rotating posts like those seen on popular news sites.</p>
<p><a href="http://demo.inderhees.net/">See a demo</a><br />
<a href="http://www.weareecs.com">See a customized CSS version</a></p>
<p>Please post questions on the wordpress.org forum at <a href="http://wordpress.org/tags/rotating-posts">http://wordpress.org/tags/rotating-posts</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/02/08/rotating-posts/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Asia trip pictures up</title>
		<link>http://mark.inderhees.net/2009/02/03/asia-trip-pictures-up/</link>
		<comments>http://mark.inderhees.net/2009/02/03/asia-trip-pictures-up/#comments</comments>
		<pubDate>Wed, 04 Feb 2009 04:27:32 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=72</guid>
		<description><![CDATA[It only took me 2+ weeks, but my trip pictures are now up. Enjoy!
]]></description>
			<content:encoded><![CDATA[<p>It only took me 2+ weeks, but my <a href="/asia-trip-jan-2009/">trip pictures</a> are now up. Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/02/03/asia-trip-pictures-up/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>iCal for Events Calendar</title>
		<link>http://mark.inderhees.net/2009/02/03/ical-for-events-calendar/</link>
		<comments>http://mark.inderhees.net/2009/02/03/ical-for-events-calendar/#comments</comments>
		<pubDate>Tue, 03 Feb 2009 18:40:31 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=34</guid>
		<description><![CDATA[I coded a plugin for WordPress called iCal for Events Calendar. It creates an iCalendar feed for the Events Calendar plugin.
]]></description>
			<content:encoded><![CDATA[<p>I coded a plugin for WordPress called <a href="http://wordpress.org/extend/plugins/ical-for-events-calendar/">iCal for Events Calendar</a>. It creates an iCalendar feed for the <a href="http://wordpress.org/extend/plugins/events-calendar/">Events Calendar</a> plugin.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/02/03/ical-for-events-calendar/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Welcome</title>
		<link>http://mark.inderhees.net/2009/01/20/welcome/</link>
		<comments>http://mark.inderhees.net/2009/01/20/welcome/#comments</comments>
		<pubDate>Tue, 20 Jan 2009 08:17:22 +0000</pubDate>
		<dc:creator>Mark</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://mark.inderhees.net/?p=3</guid>
		<description><![CDATA[Welcome to my blog.  Don&#8217;t expect many updates here.
]]></description>
			<content:encoded><![CDATA[<p>Welcome to my blog.  Don&#8217;t expect many updates here.</p>
]]></content:encoded>
			<wfw:commentRss>http://mark.inderhees.net/2009/01/20/welcome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
