Added support for windows

Hi,

I have been working with the files of mdm-server. I have made various changes and additions so that the same sets of code can be used in windows.

-
Anand