Enable concurrent Remote Desktop sessions on Windows XP

It’s possible after all.  XP Pro’s Remote Desktop can be hacked to give concurrent sessions.


To explain:  Windows XP’s Remote Desktop rocks, as does its ability to give me my console session later (with my work uninterrupted) from another machine.  Glaring in its absence, though, is the ability to remotely-rock while someone is locally-rocking the machine.  This can stink in a big way. 


For example, too often I’ve remotely logged in for something quick, only to see this nuisance:


---------------------------
Logon Message
---------------------------
The user --- is currently logged on to this computer. If you continue this user's Windows Session will end and any un-saved data will be lost. Do you want to continue?
---------------------------
Yes   No
---------------------------


Rather inconvenient.  Even worse, though, I’ve often been logged in and working remotely, when someone locally logs in.  No warnings or explanations, just *bam* disconnected!  (At least the first situation confirms the handover with both people.)


For history:  Remote Desktop’s daddy was Windows 2000 Server’s Terminal Services in Remote Administration Mode, which did allow (limited) concurrent sessions.  Microsoft added the console-session flexibility to XP’s Remote Desktop, but dropped the concurrent sessions.  Then 2003 Server’s (renamed) Remote Administration wrapped in XP’s console flexibility.  Later, XP’s SP1 promised concurrent access, then SP2 did.  Two strikes.  It did make an SP2 beta though, before being yanked later…


The silver lining:  Thanks to the termsrv.dll from that SP2 beta, it’s possible to hack XP for concurrent Remote Desktop sessions in a few minutes.  Just change a registry setting, reboot to Safe Mode, replace the DLL, and boot back into homebrewed XP Remote Administration goodness.


For the do-it-yourselfers:  Don’t wait for Longhorn (or whenever-they-may-get-to-it): here’s the how-to article, and here’s the needed termsrv.dll file.

Update:
I just stumbled on sala source’s Terminal Server Patch, which wraps up the whole process in a single convenient patch.  Very cool.

 

My first 10 random songs

Hm.. mixed feelings about participating in a meme, and moreso since the last few posts have been borderline shirking.


(But wait, how can I shirk?  Did I made an regular-original-content-creation-committment?!)


Anyway, it’s a fun one via Ed Bott: load your entire music collection, randomize, and list the first 10 songs, uncensored. 


Here’s what I got:


Porcupine Tree – Every Home Is Wired
Spin Doctors – Someday All This Will Be Road
Blind Guardian & Iced Earth – The Whistler
Flower Kings – Rumble Fish Twist
Earth Wind and Fire – Shining Star
The Fixx – Red Skies
Andy Grube – I Surrender
Audio Adrenaline – I’m Not The King
King’s X – Mississippi Moon
Galactic Cowboys – Kaptain Krude


(Wow, rand()/fate was kind — nary a Raffie or bubblegum pop song in the lot!)

SBS2003 VPN: What were they thinking?!

I thought I’d share some Small Business Server 2003 security silliness.  Following is a series of Internet Explorer dialogs when you setup VPN via the Remote Web Workplace:

---------------------------
Microsoft Internet Explorer
---------------------------
After you install Connection Manager, ensure that all users of this computer have strong passwords to protect the security of your Windows Small Business Server network.
---------------------------
OK   
---------------------------

---------------------------
File Download - Security Warning
---------------------------
Do you want to run or save this file?
    Name: sbspackage.exe
    Type: Application, 503 KB
    From: ---
---------------------------
Run   Save   Cancel
---------------------------
While files from the Internet can be useful, this file type can potentially harm your computer. If you do not trust the source, do not run or save this software. What's the risk?

---------------------------
Internet Explorer
---------------------------
The publisher could not be verified.  Are you sure you want to run this software?
         Name: sbspackage.exe
    Publisher: Unknown Publisher
---------------------------
Run   Don't Run
---------------------------
This file does not have a valid digital signature that verifies its publisher. You should only run software from publishers you trust. How can I decide what software to run?

---------------------------
Connect to Small Business Server
---------------------------
Do you wish to install the connection to Small Business Server?
---------------------------
Yes   No   
---------------------------

Notice the Big Red Flag??  Microsoft’s SBS team never signed the VPN installer (sbspackage.exe), so IE on XPSP2 (and presumably 2003SP1 now) does its scary “don’t take candy from strangers” warning.  (How long has Microsoft been touting executable signing now?!?) 

*sigh*

 

Getter/Setter Properties in OO Javascript

I just asked a guru of advanced Object-Oriented Javascript, Douglas Crockford the following question.  For posterity, and for other possible takers, I’m posting it here too.


Also, for the record, this has nothing to do with IE’s proprietary — but wonderful — setExpression method or CSS expression capabilities.  Those dynamic properties only apply to DOM objects, not custom Javascript objects.






Do you know of a way to define dynamic object properties in Javascript?


For example, VBScript lets us define classes such as this:


CLASS myClass
PUBLIC phrase
PUBLIC PROPERTY GET firstword ‘get first word from phrase
firstword = left(phrase, instr(phrase, ” “))
END PROPERTY
PUBLIC PROPERTY LET firstword(v) ‘set phrase’s new first word
phrase = v & ” ” & phrase
END PROPERTY
END CLASS

This demonstrates two important features:
1. the firstword property can return dynamic results (depending on the current value of the phrase property). 
2. setting the firstword property can run other code (which dynamically prepends to the phrase property).


We can fully accomplish #1 (Property Get) in Javascript, by reassigning the toString method/property to a function like so:


function myConstructor(){
var self = this; //preserve object’s context
this.phrase = ”;
this.firstword = function(v){
if(v){self.phrase = v + ‘ ‘ + self.phrase}; //LET
return self.phrase.substring(0, self.phrase.indexOf(‘ ‘)); //GET
}
this.firstword.toString = this.firstword;
}

…But I’ve found no way to achieve #2 (Property Let or Set) in Javascript.  I can set firstword as a method, but setting the property value overwrites the method definition (and all subsequent GETs return that static value).


I’ve extensively searched, but found no answer (at least not before Javascript 2.0, which doesn’t yet exist).  Any ideas from the experts?

Update: Douglas Crockford responded that he doesn’t care for getter/setter properties, since “it allows simple assignment to have side effects, which I think works against reliability.”  (I take that as a “No, it’s not possible.”)
    My current need is that I’m patterning my custom object after part of the DOM, whose objects certainly do have getter/setters.  I agree with Douglas that getter/setter side effects can be dangerous (esp. in the hands of a poor coder, as with any powerful code construct), but I think the use of methods -vs- getter/setter properties should be in the realm of “best practice” rather than a language limitation.