Tuesday, May 20, 2008

Getting Started with ActiveScaffold

Recently I returned to my rails env to do some more experiments (which might be used for a future project)

To start with, I have seen a bit of active scaffold stuff and was very impressed with it originally already.  In the meantime, rails 2 have arrived.  Quite a few things have changed and I was thinking that it might have an effect on the overall picture of active scaffold also.

However, checking up on railsforum etc brought out that not much effect has gone down to active scaffold kind of plugins from rails 2.

Starting up active scaffold is really easy as they say on its website also...

try it here... www.activescaffold.com It turned out to be really simple to initialize yourself with it. 

Searching a bit more I came across a few tutorials -

Tutorial from Active Scaffold guys

Another one from someone like me, experimenting with activeScaffold...

AkillesBlog » Blog Archive » Ruby on Rails: Experimenting with ActiveScaffold   
Blogged with the Flock Browser

Tuesday, May 13, 2008

Open Solaris build May 2008 ( 2008.05 ) released

Today I came across a few news items and articles here and there that talked about the release of OpenSolaris projects' May 2008 release.

Though its available for download from the open solaris home page, Sun is offering Free CD shipments for the latest release here : https://www2.sun.de/dct/forms/reg_us_2307_228_0.jsp

I already ordered my copies :)

Also, there is a nice article about bit of unix OS history and open solaris 2008.05 release review here : http://blogs.zdnet.com/BTL/?p=8703

Monday, May 12, 2008

Installing Oracle 11g on Ubuntu server 64bit on vmware server 2 beta

I have this wish to install a hardy server version on my system. Since I did not want to add another partition, so I chose to do that inside a virtual machine (using vmware). vmware supports 64bit Guest Operating system, as opposed to virtual box which does not. :(

So, I have been able to install the server edition inside the vmware machine. I have never used nfs before, but the tutorial I was following was suggesting to use it.


However, I am having problems with -
  1. Trying to expand the virtual hard disk inside vmware. I tried it, but havent succeeded yet.
  2. The Oracle installer exits with a strange error message.
I have posted my issues on the ubuntu forums, and havent got any solution yet. Lets see how it goes...

Using Base64 encoding with Oracle / Perl

For basic encryption purposes, base 64 encoding can be used. In fact its so basic that it would probably be incorrect to call it encryption. Its more encoding, basically preventing the subject text from appearing in plain text.

For example, if in some tool, all the parameters are stored in repository tables, and therefore, its not very nice if the passwords are stored there in plain text. They should at least be made illegible, so that they dont appear in plain text and there is some effort spent in decoding it.

Base64 encoding is an industry standard and almost all programming languages, development toolkits provide plugins for this. For Oracle, there are pre-existing packages providing the functionality.

We can use base 64 encoding on oracle side using Oracle supplied package UTL_ENCODE. On the perl side, we could use cpan package MIME:Base64. Other languages provide different kinds of plug-ins. For example, ruby on rails has a plug in for this, Javascript also allows this to be done relatively easily.

The idea is that, such sensitive data to be entered by customers, in encoded format. So, we also dont see the plain text version. And then the program uses the encoded version, right to the point before actual data needs to be used.

For achieving this, following way of working can be used :

1. On Oracle side, the sensitive data is encoded using a program call equivalent to the following will return an encoded/decoded string for a given input string.

FUNCTION fnc_encrypt(lv_str IN VARCHAR2)
RETURN utl_raw.cast_to_varchar2(UTL_ENCODE.BASE64_ENCODE(utl_raw.cast_to_raw(lv_str)));

FUNCTION fnc_decrypt(lv_str IN VARCHAR2)
RETURN utl_raw.cast_to_varchar2(UTL_ENCODE.BASE64_deCODE(utl_raw.cast_to_raw(lv_str)));

Its a design decision whether to put this code in a procedure/package somewhere.

2. On the other end of the processing chain, reverse operation would have to be performed. For example, in Perl, the implementation relies on the cpan package MIME:Base64

use MIME::Base64 ();
and then use the decode/encode function as per the need...

Thursday, May 8, 2008

vmware 2 beta on hardy

I installed vmware 2 beta on my hardy. It was a surprise and a pleasant one at that, the installation procedure did not require any tweaks at all. It worked out of the box.

Further, when I tried to connect to the web based management interface, I encountered my first problem. vmware requires a log-in with root user, and as any ubuntu user would tell you, the root user is well-hidden in ubuntu. Almost never used, my knowledge on how to set a password to root user was zero.

Again, communities came to help. This thread on vmware communities helped me through that.


Its a small tip, but none-the-less important. Just run "sudo gnome-terminal" and it would open a root terminal for you. Once there, type "passwd" to change the password for root user and you are done.

now, in the browser, log in to vmware web mgmt interface with user as root, and password you chose for root user.

As a precaution, I gave my normal user admin privileges so that I dont have to login as root all the time.

Oracle wrap utility...

Oracle's wrap utility helps to hide the application logic from being visible. However, I recently discovered that it doesnt hide string literals.

Hard to grasp though, since my understanding was a bit different. I cant really think of a reason why would they keep strings etc in plain text. Perhaps to force people (like me) not to store their encryption key in a package and wrap it to achieve another level of security...

Here's the standard statement from Oracle about the limitations of wrap utility -

Limitations of the Wrap Utility

String literals, number literals, and names of variables, tables, and columns remain in plain text within the wrapped file. Wrapping a procedure helps to hide the algorithm and prevent reverse-engineering, but it is not a way to hide passwords or table names that you want to be secret.

From : http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96624/c_wrap.htm#LNPLS016

I wonder if there are any tricks to achieve something like that... my investigations are still on.. will report...

Wednesday, May 7, 2008

xgl - System monitor bug in hardy...

On Ubuntu's latest release, Hardy Heron, if you are using xserver-xgl package for graphics, you are in for a surprise.

The system monitor carries on a bug in xgl package wrt incorrect reporting of memory usage, and shows processes using zillion bytes of memory.

I started using xserver-xgl from the times in Gutsy when Compiz would not run on my hardware without that. However, I didnt quite notice this until I involved myself with beta release of hardy.

As it happened, I raised this issue on the Ubuntu forums (more than once actually, link-1, link-2), and finally after a few discussions/posts, it was discovered that

  • xserver-xgl has a few bugs
  • no more active development is happening on this stream of packages
  • Compiz should work without needing this package as well.
As a result, I tried removing xgl from my laptop, and voila, memory consumption numbers are from earth again.. the martian numbers have left... :)

Attaching two screenshots here to give the idea of the Martian numbers...

I got my new lens.... Canon 55-250 IS

Wow, it feels great to buy something... especially when its a lens... :)

So, after deliberations for few weeks, I finally ordered my new lens last weekend. Got it soon afterwards. Its a Canon 55-250 IS F/4-5.6

There are quite a few reviews ( review-1, review-2 ) available for this one, so I wont attempt at writing one, but I can point out a few things from my experience..

  • The build is not so nice. The feel in hand is much more plasticky than the standard kit lens (18-55 from my EOS 350D days). Even though both are plastic, the finishing of the kit lens is much much better than this one.
  • There is a certain whirring sound when IS is enabled, if you hear really closely. Some investigations (basically asking questions on forums) revealed that its normal due to the IS function.
  • I have just taken my first batch of photos, and not completely done with processing yet. However, the first impressions are great. I have always had the problem with my hand not steady enough for a high-zoom shot, and the IS in this lens is just the life saver for me.
  • Few photos from the first outing are posted on my flickr account.

Love this thing. Will write more when more experiences show up.... Here are some shots...

aha..., originally uploaded by s_raghu20.

Doesnt that sparkle..., originally uploaded by s_raghu20.

On Grayscale..., originally uploaded by s_raghu20.

Monday, May 5, 2008


Dandelion, originally uploaded by yOOrek.

A wonderful photo from George...

absolutely stunning...

Sunday, May 4, 2008

acid3 and webkit on hardy

I have been fascinated with the rendering of web pages by Safari. Always liked it, it has a certain edge to it when talking about the look and feel. When I read more, it turned out that the rendering engine is similar to Konqueror (somewhere I read that its actually based on open source libraries from Konqueror).

I dont have a mac so I cant really experience it first hand, but the windows release of Safari made me get my first experience.

This weekend, I was surfing net when I came across "webkit". Reading a bit more about it informed me -
WebKit is an open source web browser engine. WebKit is also the name of the Mac OS X system framework version of the engine that's used by Safari, Dashboard, Mail, and many other OS X applications. WebKit's HTML and JavaScript code began as a branch of the KHTML and KJS libraries from KDE. This website is also the home of S60's S60 WebKit development.
This made me think, if its actually open source to start with, the code must be available and may be I can compile it for my system.

Well, I didnt had to look much further... search produced this link...

However, my first attempt at compilation failed, due to lack of one of the packages. libxt-dev

So, now the list of pacakges that should be installed on hardy to compile webkit would look like this :

sudo apt-get install autoconf automake libtool bison flex gperf libicu-dev libxslt-dev libcurl4-openssl-dev libsqlite3-dev libjpeg62-dev libpng12-dev libglibmm-2.4-dev libgtk2.0-dev build-essential libxt-dev

The sample browser, gives me 98 on acid3 (acid3.acidtests.org). Though very minimalistic in capabilities, this is the best score for acid3 that I could get on my system.

Here are my scores
Firefox 3 beta 5 : 71
Flock : 51
Opera 9.5 beta 2 : 78
Midori (webkit based) : 64
Webkit minimal browser (nightly build r32862 ) 98

On my windows partition as well, none of the browsers went beyong 70's. Best being opera at 71.

Saturday, May 3, 2008

Linux Kernel sites...

Found this interesting site. If you want to start knowing or playing around with linux kernel, this site could be a interesting start.

Linux Kernel Newbies

Also interesting would be to watch out for this site... www.kernel.org

Blogged with the Flock Browser

Friday, May 2, 2008

The Travel Photographer: Gateway of the Gypsies

Found this piece about Nomads in northwestern India.  In local slang, we (Indians) call them "Banzara".  I dont know enough about their history to comment on the documentory here, but the mention of the people from India sort of excited me.

The Travel Photographer: Gateway of the Gypsies

Blogged with the Flock Browser

Thursday, May 1, 2008

Nice painting...

Found this while surfing net somewhere...


I like this painting very much. :)    
Blogged with the Flock Browser

vmware infrastructure web access on vista...

For those who try to use vmware server on windows vista (unfortunately I am trying these days), the vmware server 2 beta is using tomcat engine to provide web based environment.

The access control is weird to say the least. It doesnt matter if ur user has Administrtor rights on the vista box. You have to have the "Administrator" user and log in as that only. So, you got to make a new user called Administrator and then log in to Vmware Infrastructure Web access.

I found the help on vmware forums. reproducing here for benefit of myself (lest I forget) and others who might come across.

  1. Logon to Vista using your usual account.
  2. Launch the cmd prompt - Make sure you select, 'Run as administrator'
  3. Net user administrator yourFavPassword
  4. Net user administrator /active:yes
  5. Switch User, or logoff
  6. Logon as Administrator Password yourFavPassword
    (Your password may be different!)
And then the VI web access works... :)