Category Archives: Scripts

PHP Mac Address Validation and Formatting

I have been working on a small php app to perform a network scan and fill a database with the discovered information. The issue is that, depending on what you perform the scan with, the MAC addresses are in a number of different formats. This PHP functions validates a MAC and returns false if its not valid or a variety of formats depending on your needs! If anyone has any thoughts on improving this function feel free to let me know and I will post the updates.

Posted in PHP | Tagged | Leave a comment

Add a single user or multiple users to AD with a VB Script.

This is a VB Script that I have created to fit a scenario where you need to add a user to Active Directory and set attributes for that user. I have found it to be quite tedious to have to create each user and set the attributes manually. So I have searched the net to find information on how to create a script to do what I need. Here is my scenario‚Ķ I need to create a user, set a password, set a location, create a user home folder(not roaming) and set the share permissions. I wanted to be able … Continue reading

Posted in VBS | Tagged , , | Leave a comment

Mitel 5000 PHP SMDR Script

You may have read my short writeup about reading SMDR from the Mitel 5000 with a simple PERL script. If not you can see it HERE. This script is basically the same thing but in PHP. You will have to setup PHP to run from the CLI for this to work… I also set the execution time really long and could run it from a web page as well. It was really ugly but this gets the idea out there…

Posted in PHP, Scripts, Telephony | Tagged , | 4 Comments

Mitel 5000 SMDR Script

The Mitel 5000 is a great system but the base licensed setup has a bit to be desired as far as reporting is concerned. I wanted to know who was making making and receiving calls and how long they were taking. I found some Mitel documentation on how to enable SMDR on the system and sent ahead and enabled it. After enabling SMDR on the Mitel (and rebooting it) you can run the script below on a Linux machine to collect live call data from the system. The SMDR data exchange is very simple. If you have any issues with … Continue reading

Posted in PERL, Scripts, Telephony | Tagged , | 2 Comments