Part 3: The SubRoutines

Now for the tools. There's a lot here, but in further articles you will see how this can be useful. I'll go through each tool with what it does, how to call it, and then the code itself.

NOTE: This uses the foundations in parts 1 and 2. You can find them here: Part 1 Part 2

Tags:

Part 2: Some Standard declarations and personalizing for your site

More foundational work. This stuff will configure for your site, and the routines that follow will regularly rely on them.

First, let's declare our modules:

#!/user/bin/perl
use strict;
use Net::LDAP;
use Authen::SASL;
use IO::Socket::SSL;
use Digest::SHA qw/sha1_base64/;
use Mail::Sendmail;
use Crypt::SmbHash;
use CGI;
use CGI qw/:standard/;

Tags:

Part 1: Foundations

In our journey of code, it is always useful to have a foundation. For starters you will need to make sure that you have the following PERL packages installed, as we will be using them regularly.

Net::LDAP
Authen::SASL
IO::Socket::SSL
Digest::SHA
Mail::Sendmail
Crypt::SmbHash
CGI

Fixed Tags:
Tags:

Opening Message

Hello and Welcome!

Over the course of my time as an Admin I've done a lot of Google searches and writeen a lot of code that has been very helpful to me in my work. I will be posting things here that hopefully will help you in your quest to master some of these technologies (Or simply stand on the shoulders of midgets).

I by no means consider myself a Perl or LDAP expert. It has been a "Learn as you go" ordeal. No formal training, just get things done on an as-needed basis.

I assume that you have a basic knowledge of PERL and LDAP.

Enjoy!

-Sean

Tags:
xrayspx's picture

HOWTO: Properly SPAM A Blog

For anyone spamming blogs, especially my blog, this is the proper way to do it. This comment is vaguely related enough that it seems like maybe the person just missed the point they were trying to make, or is a bad writer. In fact, it was copied from this Amazon review of a DVD from 2007.

xrayspx's picture

I Love NH

I'm very proud of my state this week. On January first, NH House Bill 73 went into effect, finally providing equal rights under the law for one more state's residents. AFAIK (and I'm not going to hunt this out now), New Hampshire is the first state to allow gays full access to marriage via legislation, rather than a court ruling. I am ambivalent about the court-based approach, but I know a lot of people feel very strongly that such things should be handled through the legislature. At least this way "activist judges" can't be held accountable.

Fixed Tags:
xrayspx's picture

Google Chrome Review @ 5 Minutes in

I've just been playing with Google Chrome from the Dev Channel site. After 5 minutes, I've got some things I hate.

xrayspx's picture

Mousepoclypse

You can tell a lot about an organization by what kind of mouse they design:

Microsoft creates the Microsoft Wheel Mouse Optical, it is curved for the hand, 3 buttons, scroll wheel, works well, is sturdy, Not Too Bad:

Fixed Tags:
xrayspx's picture

Silence My Lambs

My bathroom is being remodeled and is now completely gutted. Before this project, I proposed a change of venue to the brand new Hampton Inn like 7 miles away, but I was vetoed. I am to "suck it up" and use the serial killer Buffalo Bill bathroom in the basement of our house.

Here is that bathroom, and the journey to it. It took a good deal of self control to do this in the dark. Walking the length of the house in an unlit basement with only the timer light dealy on my camera...I fully expected to see a hand coming at me when the flash fired.

Take a tour with me:

Fixed Tags:

Pages

Subscribe to xrayspx.com RSS