Tuesday, November 9, 2010

VCARD quoted-printable decoding and importing to outlook

My father replaced an old LG KU380 and wanted to transfer his contacts to his new Ericson mobile phone. Unluckily for me, LG provided some software that was promising to synchronize the mobile phone with the outlook, but it wouldn’t stay connected with the phone for more than one minute. Thus, every 100 contacts it would stall and start over again. The next available option was to export the contacts in a vcf file from within the mobile phone and transfer the generated file via Bluetooth.

Sunday, October 10, 2010

Manual creation helpers

Ever wanted to create a manual for you application? Well, instead of pressing the print screen button and then editing the captured screens you may use a few build-in tools of windows 7 to help you out. The first tool I would like to mention is the “Snipping Tool” (located in Accessories) which allows you to select the region you want to capture and then edit it. The second one is the amazing “Problem Steps Recorder” (psr.exe located in windows\system32 folder) which allows you to record the steps you do and writes a pretty nice tutorial for you. The only problem is that it takes full screen pictures, but you can always resize the screen resolution and hide the start menu bar.

Hope this will help save a few hours from the nasty manual making job!

Saturday, July 17, 2010

Windows Indentity Foundation – Custom Security Token Service and the relying party configuration

The last couple of days I’ve been coding with the Windows Identity Foundation (WIF) in order to create a WS Federation Security Token Service (STS) that provides the user authentication for multiple relying parties (RPs). I decided to write a small tutorial and a sample (full commented) project that describes the basic steps that are required in order to setup the authentication via passive federation.

Wednesday, June 9, 2010

How to associate a web application (RP) to an existing Security Token Service (STS) using Federation Utility (FedUtil.exe)

Federation utility is a very nice little tool that can automatically configure your claim based web application (which is called Relying Party or RP in the Federation language) to trust an existing security token service (STS). It comes with WIF SDK available from Microsoft. This tool can also create a new STS based on your own claim based web application, but this is not on the scope of the current post.
In order to establish the trust you’ll have to do the following steps:

Federation Metadata Editor on codeplex

I have just opened a new project on codeplex to host the source code of  the Federation Metadata Editor I mentioned on my previous post. Check it out at http://stsmetadataeditor.codeplex.com/

Tuesday, June 8, 2010

The need of claim based security model and identity federation

The last couple of days I have been working on Windows Identity Foundation. In order to take advantage of this framework, you should start writing claim based application. Forget the old fashion role based and start demanding claims! Why to convert to claim based application you may wonder... There are many reasons why you should do that but the most appealing ones I can think of are the following:

Saturday, June 5, 2010

Building openvpn 2.1.1 with enable-password-save on windows

Lately I’ve been having some requests on how to build openvpn 2.1.1 with enable-password-save. The truth is that a few things have changed since my last post. In order to fill these requests I decided to write down a few things about the process. If you are intrested in downloading an allready compiled version or openvpn 2.1.1 with enable-password-save, check out this post.

Asp.net 4.0 URL rewriting aka Routing

Are you tired of having ugly urls in your website like product.aspx?product=1? Are you concerned about having a search engine optimized web site? Asp.net provides the mean to easily rewrite your urls via the System.Web.Routing namespace.
I have composed a simple asp.net website with lots of comments in it, that demonstrates this new (not so new actually because this mechanism exists since .net 3.5 sp1) mechanism.

Friday, June 4, 2010

WIF Custom STS metadata file editor

The last couple of days I have been wondering in the magic world of Identity Federation. Although the windows identity foundation SDK provides a great tool to associate an RP (Relying Party) application with an existing STS (Security Token Service), it requires that the STS have a Federation metadata xml file. If you simply want to automatically generate the STS from the application, then the SDK provide the automatic STS generation on the right click of the RP website, which generates a new STS web site (in c#) based on the RP’s web config file. On the other hand, if you are up to creating a new custom STS without the RP, then you have to manually create the manifest file, which is really very frustrating! On my search around the net I found a couple of federation metadata file creators but none of them had the ability to edit an existing one. Unfortunately, I had to edit the manifest file quite often and thus I had to create a tool to do so. This is why I created the STS Federation Metadata Editor which you may download freely on the following link.
Hope this simplifies your custom STS development efforts!

Thursday, May 27, 2010

Autostart application that requires UAC on user logon in windows 7 without verifying them

I wanted to make windows autorun some application (like openvpn-gui and SQL 2005 Service Manager) whenever I logged in in order to have them loaded in the tray. Placing them in the Startup folder would autostart them but I had to confirm both of them in the UAC (User Account Control) since they both run as administrator. In order to bypass this, I had to schedule them in the windows scheduler. In order to do so you must follow the following steps.

Tuesday, May 18, 2010

Hard reset password on asp.net membership provider (applied to DNN)

I just moved a DNN (DotNetNuke) installation from a computer to another and restored the database in order to be able to work locally. DNN uses asp.net Membership as its default security provider thus I could not login to the web site (all passwords are encrypted using the local machine key). In order to override the password I wrote the following lines of code:
Dim mu As MembershipUser = Membership.GetUser("MyUserName")
mu.ChangePassword(mu.ResetPassword(), "mytoughpassword")
In the default page’s init event. This is the way to programmatically change any membership account’s password.

Happy coding and don't forget to delete the above mentioned lines after reseting the passwords!

Thursday, April 8, 2010

Επιδιόρθωση του MBR

Όσοι έχουν dual boot windows με Linux με boot loader το grub έχουν σίγουρα αντιμετωπίσει το φαινόμενο να μην ξεκινάει ο υπολογιστής και να πετάει κάποιο σφάλμα ο grub. Σε αυτές τις περιπτώσεις, μια επανεγκατάσταση του grub μπορεί να επιλύσει το πρόβλημα που αντιμετωπίζεται. Για αυτό μάζεψα παρακάτω τις οδηγίες που επιτυγχάνουν την επιδιόρθωση του boot sector.

Monday, March 8, 2010

OpenVPN 2.1.1 with save-password enabled (VPNUK Edition)

A couple of days ago, I received an email from VPNUK asking whether I could compile the latest openvpn (2.1.1) with save-password enabled and if I could make a setup that would include their pre-configured config files in the config folder.
I accepted the challenge and not only did I build the latest version of openvpn with save-password enabled, I also modified the openvpn-gui application in order to provide the end users the means to set their connections’ credentials.

In the beginning I added a new menu item that said “Change credentials…” but later on I decided to modify the build-in “Change password” menu item. The modified version will detect whether or not you have the auth-user-pass in you .ovpn file and if you have it, it will display the following dialogue:
I also modified the installation a little bit in order to fix a couple of bugs (uninstalling while openvpn –gui is running etc) and add a few extra things (reboot at the end of the setup, autostart openvpn-gui etc).
If you are interested in downloading this modified version you can download it from VPNUK’s website by clicking here.

By the way, you should totally check out VPNUK.info! They provide cheap, amazingly fast vpn access to hundreds of remote servers all around the world. While testing the application I was able to stream TV episodes from a well know USA channel that only streams inside the US. So if you need to fake your ip and let others think that you are in another country, don’t miss VPNUK (you can even ask for a free trial).

PS: This build includes both the x86 and x64 TAP drivers

Saturday, February 6, 2010

Unwanted languages in the language bar.

A few days ago, i noticed that i had in my language bar 5 language options, instead of 2 that i had configured for my English Windows 7. I checked it out and i had, for no obvious reason, Japanese (JP), Chinese (CH) and Korean (KO). I looked in my "Text Services and Input Languages" where i could only see the Greek and English keyboards that i had installed. Reboot didn't help so in order to get rid of them, i had to manually add them and after applying the changes i removed them. That worked for me and now i only have my original keyboard settings. I have no idea how i got them there in the first place...

Just for reference, the steps where:
  1. Open "Text Services and Input Languages"
    • Right click on the Language bar → Settings...
      OR
    • Control Panel → Region and Language → Keyboards and Languages → Change Keyboards... 
  2. Click Add...
  3. Select the Keyboards you want to add. In my case:
    • Chinese (Simplified, PRC) → Chinese (Simplified) - US Keyboard
    • Japanese (Japan) → Japanese
    • Korean (Korea) → Korean
  4. Click OK
  5. Click Apply
  6. Select and click Remove each language you don't want.


Update [16/03/2011]:

According to Sinsoul's comment below, the reason appears due to installed MS Office profiling tools. He suggested that you should also remove all unwanted languages from the language options in office profiling tools. Here's how:

Start -> Microsoft Office -> Microsoft Office Tools -> Microsoft Office 2007 Language Settings
On the right list (labeled "Enabled editing languages") select each language you don't want and click Remove.