Wednesday, November 4, 2009

How to unpack a WAR file

A WAR file is a web application, zipped into a single file. It is basically just a ZIP file with a special folder structure. It is called a WAR file to identify it as a web application.

Why would I want to unpack my WAR file?

    * WAR files are sometimes more difficult to undeploy, and have problems such as not being able to determine the application root, it is sometimes preferable to unpack the WAR file.
    * Some packages such as JSPWiki have the properties files in the WAR, so it must be unpacked to edit settings before deployment.

How to unpack

    * Rename the file as a zip file (eg: myapp.war becomes myapp.zip)
    * Unzip as you would with any other zip file




Saturday, October 31, 2009

Get Samba to Work with Higher Version of Windows.

Accessing network drives shared on Samba protocol cannot be accessed in higher versions of Microsoft Windows . The technical reason for this failure is Microsoft changed its default security policy to use NTLMv2 authentication only.

Inorder to overcome this we change this security policy to meet our requirements.

Steps are as follows:

1. Run "secpol.msc" from the command prompt / Run utility in Windows. (Start->Run.)
2. It will display Microsoft Security Console for "Local Security Policy".
3. Select the "Local Policies" from the tree of "Security Setting" in the Left hand tab.
4. Select the "Security Options" from the tree of "Local Policies".

Security Settings->
Local Policies->
Security Options

5. Select the policy "Network Security: LAN Manager authentication level" from the list of policies in the right hand side.
6. Right click and open the "Properties".
7. Select the tab "Local Security Setting".
8. Change the drop down menu from "NTVLM2 responses only" to "LM and NTLM – use NTLMV2 session security if negotiated".
9. Apply and close the property window.

Now you can access network drives shared on Samba protocol.

Enjoy sharing.

Monday, October 12, 2009

Presenting a word in various most popular encodings

Here's the file "Hello" in various encodings:

48 65 6C 6C 6F

This is the traditional ANSI encoding.

48 00 65 00 6C 00 6C 00 6F 00

This is the Unicode (little-endian) encoding with no BOM.

FF FE 48 00 65 00 6C 00 6C 00 6F 00

This is the Unicode (little-endian) encoding with BOM. The BOM (FF FE) serves two purposes: First, it tags the file as a Unicode document, and second, the order in which the two bytes appear indicate that the file is little-endian.

00 48 00 65 00 6C 00 6C 00 6F

This is the Unicode (big-endian) encoding with no BOM. Notepad does not support this encoding.

FE FF 00 48 00 65 00 6C 00 6C 00 6F

This is the Unicode (big-endian) encoding with BOM. Notice that this BOM is in the opposite order from the little-endian BOM.

EF BB BF 48 65 6C 6C 6F

This is UTF-8 encoding. The first three bytes are the UTF-8 encoding of the BOM.

2B 2F 76 38 2D 48 65 6C 6C 6F

This is UTF-7 encoding. The first five bytes are the UTF-7 encoding of the BOM. Notepad doesn't support this encoding.

Friday, October 9, 2009

பட்டினத்தடிகளின் தொல்தமிழ்லில் தெளிவுரை

இருப்பதுபொய் போவதுமெய் என்றெண்ணி நெஞ்சே
ஒருத்தருக்கும் தீங்கினை உன்னாதே; பருத்த தொந்தி
நம்மதென்று நாமிருக்க, நாய்நரிகள் பேய்கழுகு
தம்மதென்று தாமிருக்கும் தாம்

மாலைப் பொழுதில் நறுமஞ்சள் அரைத்தே குளித்து
வேலை மெனக்கெட்டு விழித்திருந்து சூலாகிப்
பெற்றாள் வளர்த்தாள் பெயரிட்டாள் பெற்றபிள்ளை
பித்தானால் என்செய்வாள் பின்

உண்டென்றிரு தெய்வம் உண்டென்றிரு உயர்செல்வமெல்லாம்
அன்றென்றிரு பசித்தோர் முகம்பார் நல்லறமும் நட்பும்
நன்றென்றிரு நடுநீங்காமலே நமக்கு இட்டபடி
என்றென்றிரு மனமே உனக்கு உபதேசம் இதே

நாப்பிளக்கப் பொய்யுரைத்து நவநிதியம் தேடி
நலனொன்றும் அறியாத நாரியரைக் கூடிப்
பூப்பிளக்க வருகின்ற புற்றீசல்போலப்
புலபுலெனக் கலகலெனப் புதல்வர்களைப் பெறுவீர்
காப்பதற்கும் வகையறியீர் கைவிடவும் மாட்டீர்
கவர்பிளந்த மரத்துளையில் கால் நுழைத்துக் கொண்டே
ஆப்பதனை அசைத்து விட்ட குரங்கதனைப் போல
அகப்பட்டீர் கிடந்துழல அகப்பட்டீரே

பட்டினத்தடிகலின் புலம்பல்

பட்டினத்தடிகள் துறவியாக ஊர் ஊராகத் திரிந்து கொண்டிருந்த காலத்தில் அவருடைய அன்னையார் மரணமடைந்தார். அவருடைய ஈமச்சடங்கை எங்கிருந்தாலும் வந்து செய்து தருவேன் என்று வாக்களித்திருந்த பட்டினத்தடிகள் சரியான நேரத்தில் சுடுகாட்டினை அடைந்தார். அவருடைய தாயின் சிதைக்காக உறவினர்கள் அடுக்கியிருந்த காய்ந்த விறகுகளை அகற்றிவிட்டு பச்சை வாழைமட்டைகளையும் இலைகளையும் கொண்டு சிதை அடுக்கி பத்துபாடல்கள் பாடி சிதையைப் பற்றச் செய்தார். அந்தப் பாடல்கள் மிகப் புகழ்பெற்றவை.

ஐயிரண்டு திங்களாய் அங்கமெலாம் நொந்து பெற்றுப்
பையலென்ற போதே பரிந்தெடுத்துச் செய்ய இரு
கைப்புறத்தில் ஏந்திக் கனகமுலை தந்தாளை
எப்பிறப்பில் காண்பேன் இனி
முந்தித் தவம் கிடந்து முன்னூறு நாள்சுமந்தே
அந்திபகலாய்ச் சிவனை ஆதரித்துத் தொந்தி
சரியச் சுமந்து பெற்ற தாயார் தமக்கோ
எரியத் தழல் மூட்டுவேன்
வட்டிலிலும் தொட்டிலிலும் மார்மேலும் தோள்மேலும்
கட்டிலிலும் வைத்தென்னைக் காதலித்து முட்டச்
சிறகிலிட்டுக் காப்பாற்றிச் சீராட்டிய தாய்க்கோ
விறகிலிட்டுத் தீமூட்டு வேன்
நொந்து சுமந்து பெற்று நோவாமல் ஏந்திமுலை
தந்து வளர்த்தெடுத்துத் தாழாமே அந்திபகல்
கையிலே கொண்டென்னைக் காப்பாற்றிய தாய்தனக்கோ
மெய்யிலே தீமூட்டு வேன்
அரிசியோ நானிடுவேன் ஆத்தாள் தனக்கு
வரிசையிட்டுப் பார்த்து மகிழாமல் உருசியுள்ள
தேனே திரவியமே செல்வத் திரவியப்பூ
மானே எனஅழைத்த வாய்க்கு
அள்ளி இடுவது அரிசியோ தாய்தலைமேல்
கொள்ளிதனை வைப்பேனோ கூசாமல் மெள்ள
முகமேல் முகம்வைத்து முத்தாடி என்றன்
மகனே எனஅழைத்த வாய்க்கு
முன்னை இட்ட தீ முப்புறத்திலே
பின்னை இட்ட தீ தென்இலங்கையில்
அன்னை இட்ட தீ அடிவயிற்றிலே
யானும் இட்ட தீ மூள்கமூள்கவே
வேகுதே தீயதனில் வெந்து பொடிசாம்பல்
ஆகுதே பாவியேன் ஐயகோ மாகக்
குருவி பறவாமல் கோதாட்டி என்னைக்
கருதி வளர்த்தெடுத்த கை
வெந்தாளோ சோணகிரி வித்தகா நின்பதத்தில்
வந்தாளோ என்னை மறந்தாளோ சந்ததமும்
உன்னையே நோக்கி உகந்து வரம் கிடந்து என்
தன்னையே ஈன்றெடுத்த தாய்
வீற்றிருந்தாள் அன்னை வீதிதனில் இருந்தாள்
நேற்றிருந்தாள் இன்றுவெந்து நீறானாள் பால்தெளிக்க
எல்லோரும் வாருங்கள் ஏதென்று இரங்காமல்
எல்லாம் சிவமயமே யாம்

Thursday, July 30, 2009

Iconv Application Online

A link to test iconv library online

http://www.iconv.org/

We can able to upload a file and select the transformation from one encoding to another.  Quite good one.

Monday, July 13, 2009

Good n fun :-)

A link that is quite good to enjoy......
http://social.answers.microsoft.com/Forums/en-US/vistahardware/thread/720108ee-0a9c-4090-b62d-bbd5cb1a7605


The extraordinary thing from the above is as follows:

"I am glad you brought this up actually.

I don't think this is just a technology problem. The other day, I was reading one of those MS press books (One of the Thick ones) and towards the end of the book (after reading it for about three hours) I wanted to get up for a glass of water and use the toilet eventually.
But, here's when a strange thing happened. As i was about to get up (I usually read in bed) my head was so heavy that I couldn't get up. I roughly estimate the weight increase ~564.32 grams.
Well, I attributed this phenomena to the amount of information that got stored in my brain during that time (Notice the similarity there ? )
I eventually fell asleep and when I woke up a few hours later to take the MS exam guess what?!? My head was light again, and I consequently failed the Exam as I couldn't remember anything a read on that book.

Based on my experience, what I would suggest, is turn the laptop off, leave it like that for a few hours and then you can carry it around without risking to break your back. You might risk to loose your data but hey, your health is more important.

I hope that helps"