Tuesday, December 30, 2008, 07:56 AM - Technology
We run OWA here at work and needed a way to check the status of it through Nagios. If you simply scrape the OWA address, you're only checking that the front end is up - unless you log in you will never actually check the back end to do a full end-to-end service check. Here is some code to log in to an OWA forms based authentication page and return a code as to whether or not you were successful. Of course, you can extend this script to pull the contents of the mailboxes or calendar, but that's not the purpose of this script.
<?php
// OWA Login Check
// Written by Scott Milliken
// Permission granted to use under the GPL
//
$username = "myusername";
$password = "sekretpassword";
// You can just use the base URL for your default mailbox
// or you can add on to it to specify a group mailbox
// $mailboxURL = "https://email.mydomain.com" for default
// or for a shared NOC mailbox in the IT department...
$mailboxURL = "https://email.mydomain.com/it/noc";
$authURL = "https://email.mydomain.com/exchweb/bin/auth/owaauth.dll";
// First go to the URL that a user would use so that you can get your session cookie set
$pg = curl_init();
curl_setopt( $pg, CURLOPT_URL, $mailboxURL );
curl_setopt( $pg, CURLOPT_USERAGENT, "Mozilla/5.0 (compatible; MSIE 5.01; Windows NT 5.0)" );
curl_setopt( $pg, CURLOPT_FOLLOWLOCATION, true );
// You need to define a cookie jar to store and retrieve
// the session cookies or this won't work
curl_setopt( $pg, CURLOPT_COOKIEJAR, "cookies.txt" );
curl_setopt( $pg, CURLOPT_COOKIEFILE, "cookies.txt" );
curl_setopt( $pg, CURLOPT_HEADER, false );
curl_setopt( $pg, CURLOPT_RETURNTRANSFER, true );
// Setting these to false is handy for checking multiple
// frontends that may share the same SSL cert, such as
// ones in a round robin DNS scheme, but you address
// them by the "real name" of the host
curl_setopt( $pg, CURLOPT_SSL_VERIFYPEER, false );
curl_setopt( $pg, CURLOPT_SSL_VERIFYHOST, false );
// Set this to true for debugging
curl_setopt( $pg, CURLOPT_VERBOSE, false );
$response = curl_exec( $pg );
$info = curl_getinfo( $pg );
// Set the form data for posting the login information
$postData = array();
$postData["url"] = $mailboxURL;
$postData["reason"] = "0";
$postData["destination"] = $mailboxURL;
$postData["flags"] = "0";
$postData["username"] = $username;
$postData["password"] = $password;
$postData["SubmitCreds"] = "Log On";
$postText = "";
foreach( $postData as $key => $value ) {
$postText .= $key . "=" . $value . "&";
}
curl_setopt( $pg, CURLOPT_REFERER, $info["url"] );
curl_setopt( $pg, CURLOPT_URL, $authURL );
curl_setopt( $pg, CURLOPT_POST, true );
curl_setopt( $pg, CURLOPT_POSTFIELDS, $postText );
$response = curl_exec( $pg );
// At this point you can either print the following
// status to show the result of logging in, or you
// can make another call to the web server for the
// individual frames, such as
// $mailboxURL . "/Inbox/?Cmd=contents" will give you
// the listing of inbox headers (if you call curl again)
$info = curl_getinfo( $pg );
$needle = "close all browser windows when you finish using Outlook Web Access";
if ( strpos( $response, $needle ) )
printf( "Logon to OWA successful.\n" );
else
printf( "Logon to OWA failed.\n" );
?>




( 2.9 / 698 )
Monday, December 29, 2008, 01:31 PM - Toys
So now that we have the U-Verse service installed (it's quite nice, 25 Mbps downstream with 3 Mbps dedicated for internetz and the rest for video) I want to be able to capture HD output from the set top box and view it in MythTV. The only way to do that currently is through the Hauppauge HD PVR 1212, which I ordered today.Next I'll be shopping around for a 1TB SATA II drive to add to the main server and I'll most likely be removing the HDTV OTA capture card out of it - after all, I still have the two tuner HDHomeRun for OTA capture and it seems to pull in the stations a little better.
When I'm done I should have 2 OTA HDTV ATSC tuners, 1 U-Verse HDTV capture input with 2TB of online disk space in a master backend and 2 frontends.
Monday, December 22, 2008, 11:33 AM - Toys
So I heard on the radio this morning that AT&T was finally taking orders for U-Verse in Middle Tennessee beginning today. I had noticed them installing a new SLC at the bottom of the hill for my subdivision back in November, so there was a good chance that I'd be eligible for service. Sure enough, I checked online and it said that I was good to go. I just got a call back from AT&T saying that they could do the install tomorrow, but I asked them for Friday morning, instead.What is U-Verse?
Fiber to the home. IPTV throughout the house. A DVR with the ability to view the streams on any other receiver in the house. Currently only 1 HDTV stream is available at a time, but that's enough for us. Most of what we watch is still NTSC or HD over the air, which I'll be keeping. Oh, and up to 18 Mbps down / 3 Mbps up internetz connectivity!
EPIC WIN
Sunday, April 13, 2008, 10:44 AM - Nashville2600
Yesterday several of us got together for a great hiking trip at Burgess Falls State Park near Cookeville, TN. The hike is a very easy one - more like a short walk until you get to the main waterfall - and is considered to be one of the most rewarding hikes per step walked because there is so much for such a short trail. There were 11 of us hiking together and 3 more joined up later (Ob1Shinobi and his family were running late). Jeff Wee-Eng represented the 865 area code for us and Ob1 was there for the 931s. The rest of us were local to the Nashville metro area.SkyDog even tried a new smoking cessation program with ware. Here you can see SkyDog applying the penalty for ware lighting up (which is now illegal in all TN State Parks, by the way).
After we hiked we went to Mamma Rosa's Italian restaurant in Cookeville and enjoyed an excellent meal. The stromboli there beats anything else in the entire Southeast region, and trust me, I've tried to find another as good. However, even after eating a giant stromboli, Jeff Wee-Eng ordered a sausage foot-long sub... to eat right then. Once the waitress got over the shock and brought him the sub, he ate it all up. When she came back to see if we needed anything else, he ordered a piece of chocolate layer cake. I think this boy can give Tim Ball a run for his money in eating contests.
Here is a short video of the waterfall and our resident ecotaku, Jeff Wee-Eng walking along the rocks at the bottom.
Wednesday, September 26, 2007, 09:29 AM - Nashville2600
Let's take a look at a couple of words/acronyms, shall we? I'm talking about the difference between SWAG, and Schwag. SWAG stands for "Scientific Wild Assed Guess," but some people also use it as "Stuff We All Get." Both are relevant to the geek community, especially those of us who attend trade shows. I see this as silly confusion.Wayne's World, despite it's sophomoric purpose, brought a great new word into the foreground, namely "schwing." Schwing is the word that stood for getting an instant hard-on. The motions that Wayne and Garth always made when saying it are permanently etched into the brains of anyone that has ever seen the skit or the movie. It's total pop culture, which makes it cool++;. Schwag is based upon the word schwing. Sure, you can keep "SWAG" for the crap that is given away at trade shows - the $0.12 screen printed ink pens, the logo stress balls, even the 4,298th coffee cup that I've been given. However, that 1GB memory stick with your company logo on it? Yeah, I'll be a whore for your company, just gimme that thumb drive. That, my friend, is schwag. If it's really cool stuff and the person handing it to you feels that twinge of pain at giving it away, then it's definitely schwag.
I started something new within the hacker and geek communities back in PN6. At the time I traveled extensively and spoke at a lot of trade shows. People who were paying $2500 to get in got really cool things, like laptop backpacks or nice binders or similar. Those who spoke at the trade show got in for free. Yippee. So I decided to merge the two together - if you showed up, you got schwag; if you spoke, you got in free and got schwag. That first year I was financing all of it, so the schwag was a logo imprinted pint glass and a bottle of Hacker-Pschorr beer. The next year I expanded - the attendees got one type of schwag, while the presenters and main organizers got an extra piece of schwag. Yes, I'm playing the devil here, because the purpose of this disparity is to create envy. If you want to get the extra cool schwag, you need to participate. PhreakNIC is put on by volunteers who sink a lot of time into it. Those who speak put in a lot of time as well, and are not paid to be here (well, by us... some are sent by work).
Many people know that I've been trying to hand off Nashville 2600 leadership to someone else for a while. It's time to give someone else a chance to show what they can do. However, there is a legacy that I also want to protect. The different items that we've had over the years are not about branding, or trying to become "The Gap" of the hacker world. It's also not about trying to make money - the admission fees pretty much cover the operating costs, and the shirts pay for themselves and the volunteer giveaways. The only thing related to PhreakNIC that someone should be able to buy their way into is a t-shirt, plain and simple. Yes, we can make other items easily. We could probably even make more money, but this isn't a business, it's a community project. This is the vision that the next leader of Nashville 2600 must never lose sight of, because it helps us to keep our integrity and our focus on what really matters - the convention.
That being said, this year there is no swag. There's only schwag.
Monday, July 30, 2007, 08:38 AM - Technology
Ok, it still boggles my mind that CBS actually covered this during daylight hours. For those who didn't catch it and are interested, here's the link for the segment that I uploaded to Google Video.WoW Arena at WSVG2007
Sunday, July 29, 2007, 09:34 AM - Toys
Yesterday I had DISHnetwork installed at the house, and I think I was close to making the installer's head explode. He had a hard time understanding why I ordered a 4 room setup and put them all in the same room. Let's see if I can explain it well enough - there are two receivers (R1 and R2), each with two tuners (T1 and T2). R1T1 and R2T1 both use an infrared remote, which I can emulate through an infrared transmitter. That makes it ideal for controlling with my MythTV box. R1T2 and R2T2 both use UHF remotes, which I don't have a way to emulate - I'm sure it's possible, just not economical. However, my wife still wanted the ability to change channels and watch TV in other rooms that don't have MythTV front ends on them - namely the kitchen and bedroom. R1T2 sends its signal out on Channel 73, and R2T2 sends its signal out on Channel 80, and they appear to not interfere with each other. I fed the output of R1T2 back into my house cabling setup, reversed the splitters (so that what used to be an OUT is now an IN), and I have the ability to walk around the house with the UHF remote and change the channels on the "dumb tv sets". I'm not using both T2's yet because the tech support people at DISHnetwork said that I can still use infrared on the T2's, so I may get another PVR-150 to add into my MythTV box and then have 3 independent inputs from satellite.
Calendar



