Friday, October 05, 2007

PDF Signing, tell me the ways

So normally if you want to sign a PDF you have to get yourself an expensive copy of Adobe. But I was amazed at how many alternatives there are.

This quick little Java app works well

Usage like so
  java -jar SignPDF.jar
--certfile=my_cert.p12 --password=secret
--output=signed.pdf origineel.pdf

Another cool one is this c# project that uses itextsharp located here

Another is this great open source sourceforge project,
in a jiffy this portable signer is probably the fastest!

Thursday, September 06, 2007

m-e-c as2 quickstart

This is my quick little quick start guide for setting a quick little test enivronment between two computers. The software is easy to setup but

does contain a few little gotchas!

Here we go...

Download and install
Also grab yourself a copy of portecle

Run portecle on computer A and open up c:\mec\as2\certificates.p12 (this p12 file contains all of your keys and certs for mec)

Now you want to create a new keypair. So go to tools, generate key pair.

Gotcha # 1 you need to select RSA (it defaults to DSA, do NOT use DSA)

Create a certificate with Validity of 1000 and then fill in A's for everything except for country put AA.
Set the Alias to A

Ok, now you have your keypair, next you need to export your public cert to use on your other computer B. Right click your A key and then go

export. The defaults (Head Certificate and DER Encoded) are fine. Save this as A.CER and copy it over to computer B

Do this same exact process on computer B, exporting B to create a B.CER and copy it over to computer A.

Now you need to bring the public key of computer A into computer B, and the public key of computer B into computer A. In portecle click tools,

and then import trusted certificate. On computer A locate B.CER and click yes that you trust it. On Computer B locate A.CER and click yes that

you trust it.

Ok now we will configure the partners inside of M-e-c. Go to your computer A and click the partners tab. Delete the mendolson test partner.

Click the mycompany and the under misc tab change name to A and AS2 id change to AAS2. Under security tab use the drop down to select the

certificate alias of A. (If it doesn't show up then hit the reload keystore on the main screen, or maybe you need to try again on the steps

above to create the A public key)

Under MDN tab change the url to match your computer. Lets say computer A is
Check that the local station check box is checked.

Now that our local A station is configured we want to configure our partner B. Click new. Change the name to B and the AS2 id to BAS2. Under security click the drop down and select the certificate alias of B, notice that this is not a key symbol but a postcard like symbol. Under send we will put the address of our B computer. Lets pretend it is

Do this same process on computer B to configure the local station A and also the partner B. Now you should be ready to transfer a test file!

First create a test file, you can name it ASDF.txt. Now place this file in the outgoing directory on your server. If we were on server A this would be located in c:\mec\as2\messages\B\outbox drop the file here and you should see it transfer over to the other machine as well as recieve an MDN.

GOTCHA #2 do not have a space in the name of your file, if you have a space the file will not send!!!!! I consider this a bug!

Hope this little quick start guide helps someone out!


Wednesday, August 01, 2007

Process Update: Calendar

We had an interesting process here at National where a front desk person would take a screen shot of the public calendar and then email it out to a group. I first I was floored by how silly it was but then with a little convicing I learned that on a mobile device it was useful to see who was in the office or on vacation etc...

But still the image would be quite big, so I did some digging on how to pull information from the public calendar and wrote a script to email this out every morning! Script here

Wednesday, July 18, 2007


So started messing with Qcheck for some Lan/Wan speed checks. Should be fun...

Btw direct link to the silly prog is here

Wednesday, May 30, 2007

Server Reboot

Had to finally reboot our file server, it was the record winner of the office with about two years and a half uptime! Of course when I rebooted it at 5:00am I wasn't expecting any corrupt directories :-( grr so I got to drive in at 5:00 this morning!

Wednesday, May 23, 2007

Access-based enumeration! is awesome

Ok so I have been meaning to turn this feature on, bascially it only lets people see folders that they have access to! Very nice if you have a ton of folders inside a share! Get it here

Tuesday, May 15, 2007

Working half of email checker

Half of the email checker (email coming in) is working. Code is here ->

Thursday, May 10, 2007

So finished one half of the email server checker

I finished 1/2 the email checker, its extremely simple it just creates an email with a guid and sends through an external mail account, and then creates a file with the same guid. On the other side it pulls in messages from a different local mail account and compares the subject to the guid subject stored in the file. If it matches within the alloted time fram then it is assumed that the email server is recieving emails. Now I'm going to play with xmppy to send me an IM when the process fails.

Monday, May 07, 2007

Email server checker, or the email equivalent of ping

How come I can't find any software to check that an email server is working? I can find plenty of software that checks that SMTP is up, but I want a system that actually sends an email and then the remote box sends back a reciept that it has been recieved. Almost like the email equivalent of ping.

Friday, April 20, 2007

ARGHHH cookies

So I finally found out that you need to create a CookieContainer if the server you are talking with uses cookies for authentication (which of course the piece of crap kronos server does) anyways I almost gave up but I'm glad I got it to work!!!!! This dude was very helpful

Code snippet for sending XML to kronos

Dim outxml As New MSXML2.DOMDocument40
Dim inxml As New MSXML2.DOMDocument40
'Set Receiving page
Dim strURL As String = "http://seattle-kronos/wfc/XmlService"
Dim xmlHTTP As New MSXML2.ServerXMLHTTP40
'Set path of xml file to pass via HTTP
Dim xmlPath As String = "c:\test.xml"

With xmlHTTP

.open("POST", strURL, False)
inxml = xmlHTTP.responseXML
Catch ex As Exception
End Try

End With

Wednesday, April 04, 2007

Mail-enabled calendars are cool

So I just learned about Mail-enabled calendars. I think they are nifty. To set them up you fire up your exchange system manager, admin groups, domain, folder, public folders, right click on your desired public calendar, all tasks, mail enable. Now from your exchange client you can right click on this calendar and you have an exchange settings tab that you can see what email address you can send your requests to. So how to use: create an appointment as usual but also add an invitation to the newly mail enabled public calendar. This will automagically add it to that public calendar.

Thursday, March 08, 2007

A cool way my boss thought of to let a user know what their computer name is by editing the ToolTip (in the registry called the InfoTip) to %USERNAME% on %COMPUTERNAME%
Like below


Windows Registry Editor Version 5.00

@="My Computer"