«Summum jus, summa injuria.»
Dan Qing non proferì parola.
«Significa: “Il diritto estremo è estrema ingiustizia”» concluse Metello. E uscì. L’Impero dei Draghi - Valerio Massimo Manfredi
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live
«Il mio maestro era solito dirmi che non c’è miglior modo di ingannare una persona che conquistandone la fiducia.»

L’Impero dei Draghi - Valerio Massimo Manfredi
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live
Quando una donna piange, un uomo perde una parte del suo cuore.

L’Impero dei Draghi - Valerio Massimo Manfredi
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live

Execute programs with administrator privileges from asp.net page

Have you ever needed to execute a command (such as application, batch, script, etc.) on your server with administrator privileges?

Asp.net provides impersonation, that can be used to execute a piece of code with arbitrary credentials, but after examining a little the situation, i’ve came up that is not a good way for me; for various reasons, maybe the more importantly is that the LogonUser method used by impersonation requires that you use a password and that password has to come from somewhere. This means somewhere in your system you have to store this password and retrieve that password which can be compromised and then potentially be used to further penetrate security.

So i’ve implemented another simple method to obviate to this: basically a Windows Service installed on the server machine, running as administrator (or the preferred account), listening for the ServiceBase.OnCustomCommand method, which is invoked by an asp.net page by the ServiceController.ExecuteCommand method. The IPC (Inter-Process Communication) is implemented with a file, written by the asp.net page and read from the windows service, and that contains the command to execute.

Continue reading »
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live
Featured on Smashing Magazine! : )

Enjoy my November Wallpaper!

November Wallpaper


If you like it, please leave a comment! : )
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live

MV Blog code posting utility

This simple utility, written in C# .net, provides some useful tools for blog posts editing - or other general needs:

  • HTML encode / decode utilty
  • URL encode / decode utility
  • Base64 encode /decode utility
  • Base64 UTF-8 encode/decode utlity (useful when your input string contains non-ascii special characters such as à, é, €, etc.)
  • Newline to "<br />" replacement utility
Continue reading »
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live

MV Backup Server Safe Shutdown Monitor

Scenario: Windows server machine with one or more folders that daily receive backup files from different client machines, within a defined (and configurable) time interval, and after receiving all the archives from all client machines must be shutdown automatically.

Continue reading »
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live

In this article i’m going to explain a recently backup plan i’ve implemented for my company.

The backup plan refers to a single Linux client machine which sends backup data to a backup server, but it can be straightly applied to an arbitrary number of client machines. After a quite extensive search over the net i’ve decided to implement the backup plan using dar - Disk ARchive to actually make the backups and rsync to ship data to the backup storage remote server.

I’ve chosen dar as backup software because i’ve found it enough simple to deploy and at the same time plenty of features; and i’ve chosen rsync to transfer data because of it smart file transfer: rsync uses the "rsync algorithm" which provides a very fast method for bringing remote files into sync. It does this by sending just the differences in the files across the link, without requiring that both sets of files are present at one of the ends of the link beforehand.

The backup strategy

dar is executed:

  1. every night for differential backups;
  2. on the first day of the month to make a full backup;

After successful backup rsync is invoked to transfer data to the backups storage server.

Sysadmin notifications: backups scheduling is done by using cron, so i’m using the cron built-in feature which sends the output of executed commands via mail.

 

Continue reading »
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live
Simpsons: How Do You Feel Today? v1.0

Set your favorite Simpsons character as your Today background on your Windows Mobile based device!…

Available characters:

  • Homer
  • Marge
  • Maggie
  • Moe
  • Mr Burns
  • Mr Smithers
  • Flanders
  • Winchester

 

Continue reading »
Share and Enjoy:
  • Digg
  • del.icio.us
  • Technorati
  • Sphinn
  • Facebook
  • LinkedIn
  • Live

Isn't this worth at least €1?

Any donation is appreciated, consider a €1 donation for each download (or maybe €1.35 since PayPal takes €0.35 from a €1.00 donation). Your support allows me to continue to create free software.