Accessing the UTK LDAP server

9/25/2009 – I have graduated from UTK and my personal webspace does not exist anymore. Hence, the links in [1] below do not work. The script is copy-pasted below for reference, in case you would like to try it out.

Previously, I have tried accessing the UTK LDAP server a couple of times. But I always ran into one problem or the other. Finally succeded today.

[1] PHP script to query the UTK LDAP server
Wrote a PHP script to query the UTK LDAP server. Got the basic info from the php.net website. The script is online here. The source code can be viewed here.

Source code for ldap.php

<?php
// PHP script to search UT LDAP server
// Bobby Maisnam [ bobby@maisnam.com ] 2:53 AM 5/7/2004

$ldapServer = 'ldap.utk.edu';
$ldapBase = 'dc=tennessee,dc=edu';

$attribute = $_GET["a"];
$value = $_GET["v"];

/* try to connect to the server */
$ldapConn = ldap_connect($ldapServer);
if (!$ldapConn)
{
    die('Cannot Connect to LDAP server');
}

/* bind anonymously */
$ldapBind = ldap_bind($ldapConn);
if (!$ldapBind)
{
    die('Cannot Bind to LDAP server');
}

/* set the ldap options */
ldap_set_option($ldapConn, LDAP_OPT_PROTOCOL_VERSION, 3);

/* search the LDAP server */
$ldapSearch = ldap_search($ldapConn, $ldapBase, "($attribute=*$value*)");
$ldapResults = ldap_get_entries($ldapConn, $ldapSearch);

$record_count = $ldapResults['count'];

echo "<p><b>$record_count</b> records returned</p>\n";

for ($item = 0; $item < $ldapResults['count']; $item++)
{
    $item2 = $item+1;
    echo "<hr />\n";
    echo "<h4>Displaying record [$item2]</h4>\n";
    for ($attribute = 0; $attribute < $ldapResults[$item]['count']; $attribute++)
    {
        $data = $ldapResults[$item][$attribute];
        echo $data.":&nbsp;&nbsp;".$ldapResults[$item][$data][0]."<br>";
    }
    echo '<hr /><br><br>';
}

?>


[2] Setting up LDAP address book in OutlookExpress
– Open OutlookExpress
– Tools > Address Book
– In Address Book, Tools > Accounts
– Add (use the following info)
LDAP server: ldap.utk.edu
Port: 389 (default)
Search Base: ou=People,ou=Knoxville,dc=tennessee,dc=edu

Useful Links:
http://dii.utk.edu/ldap/
http://web.utk.edu/~mike/mac/osx-utk-ldap.html
http://us2.php.net/manual/en/ref.ldap.php

Archiving Yahoo! Groups messages; Yahoo! 999 Error

Update (10:37 PM 5/17/2005): A better discussion of the Yahoo 999 error is here.
Update (10:13 PM 2/17/2005): If you have come here trying to find information about the Yahoo 999 error and you are not able to access your email, you might want to try the options mentioned below:
– Trying logging into your account using
http://login.europe.yahoo.com/ or
http://edit.in.yahoo.com/ or
www.bt.yahoo.com or
http://wap.oa.yahoo.com/
Read more about the error here.


Spent the last 5 hours trying to figure out how to archive Yahoo! Groups messages. I want to keep a copy of the messages on my computer and also put a local copy online.
[1] PG-Offline [Windows]
Site: http://pgoffline.com/
Type: Shareware
Bob’s Review: This one works great. Very easy to configure. Also, the messages can be exported as .mdb (MS-Access) files. However Yahoo! Groups blocked my IP after about 332 messages. I got the Yahoo! 999 error. Here is a screenshot. Access was restored after about 3 hours. More discussion about the Yahoo! download limit is here.
Cons: Does not seem to have an export to html option.
[2] yahoo2mbox [Unix/ Linux]
Site: http://www.lpthe.jussieu.fr/~zeitlin/yahoo2mbox.html
Type: Freeware
Bob’s Review: This one was really easy to install. Just one Perl script. That’s it. However, you need shell access to run the program. Use this syntax:
perl yahoo2mbox.pl --start=0 --end=200 --user=your_username -o mbox group_name
Yahoo blocked my IP after about 300 messages. Since I had access to about 60 different logins (and therefore 60 different IPs) to my unix account, I kept changing the logins after I got a block. No need to use the --delay option. Just change your IPs when you get blocked. Of course, if you are on a static IP, then maybe wait 3 hours and try again!
The mbox file generated can then be read using Outlook Express (Well, I use Outlook Express!) by creating an IMAP connection to the unix machine and choosing the location of the mbox file as the root folder path.
Update (6/12/2004):
MHonArc
The mbox file generated using yahoo2mbox can be converted into mailmain style static html pages using MhonArc. You will need a Unix/Linux machine (and most probably root access) to run the script. MHonArc is really good and works just great!

MT bookmarklets and Trackback.

Testing Media Temple’s bokmarklet feature. Not sure if it is really that useful. The only advantage seems to be that I need not copy-paste the URL.
TIME.com: Voices On Broadband — Mar. 29, 2004
3/30/2004: It seems I was wrong. MT bookmarkets are in fact very useful, especially for trackbacks. I am still learning though. I am pinging one of the entries of my blogspot blog and in fact, it works – like a charm!
A nice tutorial about Trackback is here.

Plone

Installed Plone today on my WinXp Pro machine at home. I was already using port 80 for Sambar and port 81 for IIS. So, I had to use port 82. It is working fine. It seems to be really powerful and has a lot of features. But I am not really sure how useful it will be. The greatest drawback is that you need admin rights to your own machine. For people who just have webspace with hosting companies (and not admin rights), they will not be able to use Plone. I feel that MovableType is much better (I am using it for this blog). Also, you might want to try put PHPNuke.
I might be wrong about Plone though. Right now, I have not figured out a way to keep the contents on a remote server. Comments/ suggestions are welcome.
I know that the UTK-SIS website uses Plone. That’s where I came to know about it.

FeedWrapper.com

FeedWrapper is a website where we can generate code to syndicate multiple RSS feeds into a webpage. I tried it out and the results were quite satisfactory. Here is the syndicated web page that I created. The feature seems pretty cool to me.

RSS Feed Aggregators

Tried out some RSS Feed Aggregators today.
Pluck seems to be good. It gets integrated with IE and automatically detects .xml and .rdf hyperlinks. However, the feed seems to be randomly ordered. The timestamp displayed is the one when the feed was added to the list. So, I have a bunch of feeds which display the same timestamp i.e. 6:13 am. Maybe the ordering will work for future updates.
Also tried out BlogStreet’s Info Aggregator. The nice part of this feature is that you can add rss newsfeeds and these will be delivered to you via an IMAP account. I have set up the account but the feeds have not come in yet.
More about this later.

Perl Script for redirection mapping

Wrote a small Perl script to create mapping of blog archive files from my CS account to my current blog. The mappings have been created because a lot of pages on my old blog are indexed by Google. And I do not want those search results to produce a ‘404 not found’ error.
For example,
http://www.cs.utk.edu/~maisnam/blog/archives/000007.php (old)
will be mapped to:
http://blog.maisnam.com/archives/000007.php (new)
The script is available here for download.
I have modified the script to just suit my current needs (Because I am so lazy! 🙂 ). Right now, I have only about 40 files in my old blog. But the script will work for any number of files in a directory. There are some bugs to sort out though. Guess I will work on it later.

New webhost

I have bought a reseller account. I have shifted all my sites to the new server. Speed is pretty good and the good thing is that I can host unlimited sites as long as I don’t exceed the bandwidth and webspace. I have also redesigned maisnam.com using less tables and more CSS.
Note: Previously, I used to point my domains to my server at home which has a DSL connection to the internet. The server is still up but I am not using it much.

orkut.com

Came to know about Orkut through an email from Prashanth. Here is an article from news.com about Orkut. This is a close-knit friendship group where entry is only by invitation. Supposedly based on a Google technology. Interested? please go ahead and read the article. There is very little information on the official website itself though.