Skip navigation

Alive and KiXing

Don't underestimate the power of KiXtart scripting

Downloads
47893.zip

One of the premier scripting languages under Windows is KiXtart, developed by Ruud van Velsen of Microsoft Netherlands. KiXtart was originally intended as a logon script processor, but it has since proven itself to be a powerful and versatile tool: Many scripters are using it heavily for a wide variety of tasks, including Help desk and centralized computer administration, Active Directory (AD) management, and software deployment.

You might consider KiXtart the little brother of VBScript, the dominant scripting language under Windows. Although ActiveState's Perl and Tcl are also prominent, particularly in heterogeneous Windows-Linux environments, KiXtart is easier to understand, especially for novice scripters. KiXtart also comes with fewer security implications than VBScript and Windows Script Host (WSH), which many corporate networks are disabling to decrease the spread of viruses and other malicious files.

Versatile, powerful, and easy to master, KiXtart has a bright future as an excellent scripting option for systems administrators. In this article, I give you an overview of the current state of KiXtart and its associated applications. Although KiXtart is a small executable, you shouldn't underestimate its power.

The Scripting Engine
KiXtart has reached a mature version 4.50, which now features an encryption and pre-tokenization engine (i.e., a means with which to convert commands/functions into smaller tokens representing the commands/functions), thereby permitting the distribution of encrypted and tokenized scripts. Pre-tokenizing scripts leads to faster execution time because fewer bytes need to be transferred, and the scripting engine itself no longer handles the task of tokenizing the scripts. Tokenization also protects the script: The source code isn't easily readable unless someone translates the tokens.

KiXtart 4.x fully supports the COM interface, permitting interaction with and control of Active Directory Service Interfaces (ADSI) and Windows Management Instrumentation (WMI). Therefore, you can perform complete remote management of AD and computers from a central administrative workstation. You can even remotely execute commands under specific account credentials, as with SysInternal's PSEXEC utility.

KiXtart supports calling and embedding of user-defined functions (UDFs). Thus, scripts can reference a whole library of functions that greatly expand the KiXtart functionality. The central KiXtart.org Web site, for example, provides more than 540 such UDFs, all written to a stringent coding standard and vetted by veteran coders. Functions range from simply deleting mapped printers to complex tasks such as application installations, database interactions, and numerous ADSI and WMI tasks and queries.

With a small amount of code, you can accomplish simple tasks such as mapping drives based on group memberships or manipulating registry settings, as you can see in Listing 1. However, complex scripts exceeding 10,000 lines of code have also been written—for example the KiXtart Systems Management Server (http://www.kixtart.org/ubbthreads/showflat.php?Cat=&Number=68489), a central client-server application for the management of a departmental network, featuring functions such as remote software installations. There's also the MyComputerInfo script (http://www.kixhelp.com), which obtains comprehensive information about computers and displays it as HTML files.

KiXforms GUI Engine
One major improvement in KiXtart 4.x is the inclusion of full COM automation instead of the older OLE automation. This new feature prompted devoted KiXtart scripter Shawn Tassie to update his KIXBGI32 and KIXWIN32 DLLs to a COM object called KiXforms, which is part of the KiXtart COM namespace.

The original KIXBGI DLL was a simple OLE DLL that could create rudimentary GUIs with KiXtart. KiXforms, on the other hand, is a COM object that closely follows Microsoft .NET standards and features more than 40 GUI controls, including the ProgressBar, Menu, Button, Tab, ListView, and ImageList.

KiXforms 2.3.045 is currently available, and it includes Windows Installer for Group Policy Object (GPO)–based deployment and an extensive .chm Help file that explains all GUI controls, including their methods, event handlers, and properties. KiXforms also supports a socket DLL that lets scripters use TCP/IP to write their own client-server applications. Users have already utilized this socket functionality to develop a KiXtart/KiXforms instant messenger (IM) service and a rudimentary Web server.

Efforts are underway to create KiXforms 3.0, featuring full .NET support. Figure 1 shows a KiXforms GUI for a KiXtart script that integrates a new computer image (created through SysPrep) into a domain and optionally installs selected drivers and software packages.

ScriptLogic Administration
ScriptLogic has developed a commercial application framework for easy desktop administration and logon script creation that incorporates the KiXtart scripting engine. Working closely with Ruud van Velsen to incorporate new feature requests from the KiXtart community, ScriptLogic produced ScriptLogic 4.0 and Desktop Authority 6.5, a GUI-based application that can accommodate both novice and veteran scripters. Although ScriptLogic doesn't require that you have a coding background to use the product effectively, you can enhance the scripts it produces with custom scripts. ScriptLogic also provides extensive support options for its users.

Admin Script Editor
The Admin Script Editor from iTripoli is a KiXtart/VBScript script editor with several unique features, such as the ability to create executables out of a KiXtart script and the ability to run the scripts under alternative credentials—and optionally in an encrypted mode by taking advantage of the Encrypting File System (EFS). The editor has wizards for commonly used KiXtart functions such as MessageBox() and ReadProfileString(), as well as an extensive online Help resource.

The folks behind the Admin Script Editor are also hard at work on the Visual KiXforms Designer, currently available in a beta release. The designer permits drag-and-drop creation of KiXforms GUIs, including the associated KiXtart scripts and event-handler routines.

The KiXtart Community
KiXtart wouldn't have enjoyed such growth and success without the volunteers who provide online support to the KiXtart community. Multiple Web sites, newsgroups, and forums exist for the support of KiXtart and related technologies and applications. The premier KiXtart forum—affectionately called the KiXtart Mothership—resides at the main KiXtart Web site and features near–real-time responses (less than 5 minutes from initial post) and a library of more than 540 ready-to-use KiXtart UDFs in a standardized format.

ScriptLogic and iTripoli also operate forums, although they tend to focus on the support of their own products while providing general KiXtart support. They also feature script exchanges similar to the ones you'll find at the KiXtart site. The KiXforms Web site features a forum dedicated to the KiXforms DLL and welcomes all scripters, whether they're using KiXforms with KiXtart or VBScript/WSH. For a list of KiXtart resources, see the Web-exclusive sidebar "KiXtart Articles and Web Sites," InstantDoc ID 47893.

The boundaries between the online resources can be a bit blurry—a core group of KiXtarters can often be found on all the forums. It's not uncommon to be referenced from one forum to another, where a similar problem has already been discussed and solutions provided.

The KiXtart Future
Looking at some of the KiXtart scripting projects currently underway, you might say that there's nothing KiXtart can't do. Whether it's a GUI for AD management, support for SysPrep image distribution, an IM or Web server service, or even strategy (Quinto) and arcade (KiXlander) games, it's all feasible with the help of a tiny 250KB executable called KiXtart.

KiXtart Articles and Web Sites
If I've piqued your interest about KiXtart and you want to learn more, you'll find a wealth of KiXtart-related resources just moments away. Start with the following Windows Scripting Solutions articles:
"KiXtart User Logons," July 2002, InstantDoc ID 25276
"Creating Logon Scripts with KiXtart," February 1999, InstantDoc ID 4817
"Manipulate the Registry and Access Files with KiXtart," April 1999, InstantDoc ID 5124
 
Then follow up with these Web resources for more information:
The official KiXtart home page, http://www.kixtart.org
The KiXforms Web site, http://www.kixforms.org
ScriptLogic's site, for information about ScriptLogic and Desktop Authority, http://www.scriptlogic.com
iTripoli's site, for information about Admin Script Editor, http://www.itripoli.com
KiXtart HelpDesk, http://helpdesk.kixtart.org
KiXHelp Web site, http://www.kixhelp.com
Quinto, http://www.kixforms.org/forum/viewtopic.php?t=182
KiXlander, http://www.kixforms.org/forum/viewtopic.php?t=603



Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish