Posts

Showing posts from 2006

VMWare is cool!

My first implementation of VMWare in a test environment, went quite smooth. I was pleased to see the installer resembled that of RedHat or Fedora. Very comforting, warm, fuzzy feelings came over me as I ran the install script...;) I installed a Windows 2003 member server, and a Nagios sample image found on the VMWare website. Quite easy to install guest os's and especially the images, as no installation process is needed, just configuring the guest os once the image is deposited and added to the list of guests available to boot. I only wish I could have had a better host, as it was only a dual PIII, with less than a Gb of RAM.

Website Design

Just realized with all my sporadic posts to "brag" about my tech-exploits, that I should note that I've got two websites I've designed. One is McDermotts Photo (web archive link...did that one a few years ago), and the other is Lord of Life Lutheran Church (quite recent). Lord of Life is a Joomla implimentation, and the theme is heavily modified from the creator, Shayne Bartlette . McDermott's was from scratch, using DreamWeaver and a few other tools, and much design help from my wife, Kristen. I've also set my own Joomla site up at pcnorb.homelinux.org , on an old PIII 450, that's getting too tired to serve the pages of my son I keep pumping into Menalto's Gallery implementation. Seems to be the latest and greatest CMS, according to Packt Publishing . That's good, because I just convinced the Racine Art Museum , one of my customers, to switch their web over to it. Their site was getting stale, over 5 years old, and needs a serious update,
Well, I found the vulnerability the same day I posted the last entry. It was the a6_credit addon, so I removed it...

I've been hacked...

I feel used. Defiled. Maculate. Impure. Unclean. (Thank you oOo Thesaurus..:-|) Seems someone is Turkey that goes by the handle "MDX" found a vulnerability in my Joomla implementation for www.lordoflifekenosha.org. Nice. Must be some 30 year old virgin that still lives with his parents, has his own room in the basement, listens to 80's Modonna's "Like a Virgin" at full volume on his Close 'N Play, while masterbating to JC Penny's women's lingerie section. Now we seem to be denouncing the US and Israel, naming them as Terrorists. Next we'll be pushing porn...IF I don't find the exploit. I'll just create a local installation of the site on my Dell laptop, that dual boots Windows and the shiny new Novell SuSE 10.1. Which friggen ROCKS, IMHO...almost completely done away with using the Windows install... More when I patch the snot out of the site, and see what breaks...

Importing User Data Into Joomla

I had a need to import user data into Joomla with the Community Builder RC1 component installed. After a bit of discovery I found a method. First, I had to export my users from a proprietory Access database to something I could import using phpMyAdmin. I ultimately found that MySQL seems to like tab delimited files better, since phpMyAdmin likes to have a character set surrounding each cell for import purposes, and Excel doesn't export csv that way (at least not to my knowledge). Before any of these changes were attempted, I exported the tables marked for updating. Backups are good juju.... Once that was done, I had to form the data to prepare for import. The first table I imported was jos_users. I used a nice php script found somewhere on the net. Replace $TABLENAME, $FILENAME, $DATABASENAME, $PASSWORD, $USERNAME, and $HOSTNAME with appropriate values. # first get a mysql connection $dbh=mysql_connect ("$HOSTNAME", "$USERNAME", "$PASSWORD") or di

Output MS Publisher to PRN files

I needed a method to programatically check a series of directories for .pub and save as .prn for later batch processing to .pdf through Distiller. There were hundreds, and I just couldn't make myself do it by hand... After a little Googling, I found some useful code snippets from MS, and Google groups. Comments and credits were left intact in the functions I borrowed, as well as my own. Hope someone finds this as useful as I did. Option Explicit Function GetFiles(strPath As String, _ dctDict As Scripting.Dictionary, _ Optional blnRecursive As Boolean) As Boolean ' This procedure returns all the files in a directory into ' a Dictionary object. If called recursively, it also returns ' all files in subfolders. Dim fsoSysObj As Scripting.FileSystemObject Dim fdrFolder As Scripting.Folder Dim fdrSubFolder As Scripting.Folder Dim filFile As Scripting.Fil

Automated CD Burning using AutoMount

One recent project for my employer was to create a headless (pc with no keyboard, mouse, or monitor) CD burner that automagically detects an inserted flash card, renames the files, and burns them to a CD along with a Flash Projector application that plays the images on PC's or Mac's. My solution was to use the AutoFS automounter daemon, and shell scripts. Much of the scripting ideas borrowed heavily from the BashBurn project. The hardware used was commodity workstations, and a 9-in-one flashcard reader configured as a SCSI device. See the following articles for interesting info: http://www.grack.com/news/2003/Atech9-in-1CardReader.html http://www.cs.sfu.ca/~ggbaker/personal/cf-linux The file test.sh is run by cron every 20 seconds, piping the command through sleep: * * * * * root sleep 0; /usr/local/copydisk/test.sh && sleep 20; /usr/local/copydisk/test.sh && sleep 40; /usr/local/copydisk/test.sh Test.sh contents: #!/bin/bash if [ -f /usr/local/copydisk/

Windows VBS Automated Maintenance Scripts

I had a need to automate a number of tasks for remote administration, and used Visual Basic Scripting and Windows Scripting Host Objects, since I am fairly comfortable with VB/VBA. This is an automated defragmentation script that uses dirms.exe, a defragmentation utility found here . Option Explicit Dim FSO, Drive, oShell, WshShell, BtnCode, rtn, hd, stComp Set WshShell = WScript.CreateObject("WScript.Shell") Set FSO = CreateObject("Scripting.FileSystemObject") Set oShell = WScript.CreateObject ("WScript.shell") '''' ''''''''''''''''''' DIRMS.EXE USAGE ' dirms c -q : Do free space evaluation, defragment, and quickly move files to the front of the drive ' dirms c DEFRAG -q : Defragment files only ' dirms c CoMpAcT -q : C ompact only ' dirms c COMFRAG -q : Perform partial compaction (quickly) on all fragmented files ' dirms c COMFRAG c:\filena