Wednesday, June 24, 2015

Revenge - Last part

Here is the part 1
Here is the part 2

Sachin left early in the morning for the office. After sometime, the lady got ready for the office. Before leaving house, she called a number.

“Boss, plan is working”, said the lady.
“Good”, was the reply.
“In this week, they fought. He bought new car, left home and moved to my house”, said the lady.
“Good”, was the reply.
“Should I bump him off now?”, asked the lady.
“Fool, do not do anything unless you are asked to do. I want to use that guy. He has cost me millions. Instead of bumping him, I can use his skill and recover that money with interest”, was the reply.
“Sorry boss”, said the lady.
“Now, resign and join my company. I have some plan. Ask that stupid guy to follow you. I want to keep close tab on him. I will ensure you join at higher level to boost his ego and ensure it looks normal. Can you pull it off”, asked Deepak.
“Yes, boss”, the lady said.

The lady went to the office and resigned. She asked Sachin to do the same and promised that he can get more rewarding job in another company. Sachin too got carried away and resigned. After the necessary notice period, both of them joined Deepak’s textile company.

Raj was breathing fire. He was thinking, how could Sachin join his father’s killer’s company.

In the new company, Sachin and the lady joined as VP. Deepak ensured easy induction and transition. The lady tempted Sachin with rich and luxurious life. She asked Sachin if he can help them live grand life. Sachin revealed to her that he can hack accounts and pull money. Lady got all the account numbers of Deepak’s rival and gave it to Sachin to hack. All these people too were criminal and hence Sachin did not feel guilty.

Sachin collected all these account numbers and started doing the basic research on them. He also added few more account numbers of politicians and prominent personalities. He did all the research for 2 weeks and finally was ready to pull the plug. 

All the last minute work ensured it was 2 am in the morning when Sachin was done with everything. Before going for the pull, he dialed in a number:

“All set?” asked Sachin.
“Yes”, was the reply.
“Is the IP switched?” asked Sachin.
“Yes. Now your computer’s IP address is pointing to Deepak’s machine” said Raj.
“Good, I am hitting the button”, said Sachin.
“All yours”, was the reply.
Sachin transferred billions of money from all these accounts into personal account of Deepak. His account was flooded with money and immediately red flag was raised by the bank system.

Here, Raj called onto Deepak.

“Hello Deepak. This is Raj”
“Raj, how dare you call me at this hour” said Deepak
“Sorry to bother you. Thought of informing you that Sachin is transferring all the money to you personal account and you will be screwed by the morning” said Raj.
“You f$$$*** shit, what do you mean” screamed Deepak
“Simple. You had a good plan of separating the brothers. Then, you thought of using Sachin as a means to eliminate your rivals financially. However, we changed the plan by adding few more prominent people to that list and transferred all the money to your personal account” said Raj
“How did you come to know of the plan” asked Deepak. He was half angry and half frightened by the consequences.
“Oh, that was simple! You made Sachin’s boss hire that lady without any new requirement in Sachin’s team. That was the red flat. We did some background verification and found that the lady had no past records in any company. That was the major flaw. Our MNC always does a background check on all employees before hiring them. If she managed to get hired without background check, she has super contacts and wrong reason to be here without any requirement. Moreover, the lady made the classic mistake of befriending Sachin and asking for dinner date in the very first week. From then onwards, we just kept on playing to your plan. Sachin Tendulkar always does some improvisation just before hitting any ball. Similarly, my brother Sachin improvised your plan to screw you” explained Raj.
“You ###, I will kill..” Deepak wanted to scream but Raj had disconnected the call after his last sentence.

The VIPs ensured that Deepak spends rest of his life in jail.

Sachin was made CEO of the company due to sudden arrest of Deepak. Life was coming full circle for Deepak.

Moral of the story: Write a long story, break it into parts and you get 3 posts :)

Tuesday, June 23, 2015

Revenge - Part 2

The ex-CEO had 2 sons named Sachin and Raj. They were college toppers and sports champion. Sachin did his engineering in India and went abroad to study ethical hacking. Raj did his M.Comm and completed Company Sectarian degree. During their last year of respectful PG courses, their father was killed by Deepak. The whole killing episode was witnessed by their mother. However, she kept quiet fearing similar fate for her children. She told them all the truth on completion of their courses.

Initially, both of them went into shock and disbelief. After few months the grief died and feeling of revenge was born. However, the grief killed their mother in the mean time.

Both of them decided to take revenge systematically and without getting caught into legal troubles. Both of them hid their PG courses and secured job in IT MNC.

They established themselves as anti-social to get home by 7 pm daily. Then, they worked till 2am in the morning on planning to get Deepak to his end. They hired few more people and started their ‘part time’ work. Most of the time, they simply hacked into the company accounts and transferred loads of money into their own account via a third party international accounts. Since, most of the transactions were either black or illegal; Deepak could not report this to police. While some other time, they made the company get into legal trouble with the help of their team. They bribed people to do wrong things on company behalf, they bribed unions to ensure that staff does not work in these companies.

They were multi-millionaire by now. The modest looking hatchback was bullet proof car. Their shanty looking house was quite luxurious from inside. The house was guarded 24*7 by armed men. People staying around were curious why such a shanty was guarded heavily.

Deepak eventually found out everything about them and their security arrangements. It was nearly impossible to penetrate the security and kill them in their house. Their car was bullet proof and could not be bombed. Killing somebody inside a MNC is almost again next to impossible. Deepak wanted time to think. He stopped forming new companies and decided to come up with a plan to counter Sachin and Raj.

Here, Sachin and Raj too were left nothing to do after office hours as Deepak had stopped starting new companies. The existing textile and cable TV was too huge and risky to touch. Big politicians and dons were stake holders in these companies. That would be too big fish to swallow. Also, killing Deepak was not an easy job and it was not their way of taking revenge. Everything stood stand still.

Sachin and Raj started staying back in office after 6 pm as they had nothing to do after getting home. Everybody was bit surprised by them. As days passed, everybody found out that they had a good sense of humor too. Months passed and each party waited for other to make a move.

In the mean time, company hired a new lady executive in Sachin’s team. She was charming, elegant, neatly dressed and intelligent. In the first week, she befriended Sachin and asked for dinner together. The next Saturday, they both went to the city’s finest hotel for a dinner. Raj was surprised by Sachin’s behavior and reminded him of their goal. Sachin quickly dismissed that dinner as normal dinner and said that he was completely committed to the final goal.

Sachin kept on going with the lady on dinner, almost every day. Weekends too. The girl was funny and loving. She was intelligent and smart. Sachin liked all her qualities.

Here, Deepak started another company and was successful in it since both the brothers were not at work. Raj alone could not work as efficiently as they both were. Plus, Sachin was the hacker and he was not available. Sachin’s heart was hacked. This frustrated Raj and he confronted Sachin on this. A major fight broke out between them. Next day, Sachin bought brand new car for himself. Although, the car was bullet proof as earlier, this car was jazzy and had modern looks. Clearly, he wanted to impress someone.

It was first time that they were travelling separately. The lady was very happy with the new car. They celebrated that night at her house. Sachin left her house at around 4am and returned home. Raj could not sleep. He was waiting for Sachin. On seeing him drunk at around 4 in the morning, Raj got angry and demanded answers from Sachin. Drunken Sachin slapped Raj and left his home. He packed all his baggage and went to the lady’s house. 

To be continued ..

Monday, June 22, 2015

Revenge - Part 1

Disclaimer: All the characters in this story are fictitious and bear no resemblance to any living or dead.

Deepak Thakur is the most successful man in the city. He has Textile Company and a cable TV network. However, he also has stakes in other small companies floated around the city. Many of them shut down while Deepak continues to form new ones. Rumors are that Deepak is the real owner of all these small companies but legally he is just another stake holder.

While most people respect him for the charity that he is doing around, few of them loathe him for the bad work he has done all these years. The aam junta just knows of what he wants to reveal. Just like paid reviews, there are paid articles on him. These articles focus on his charity and social work.

Sachin and Raj are into software MNC. They are at mid-management level in the same company. They are reclusive, curt and do not roam around with anybody. Both of them are good at their work and hence nobody bothers about them. As long as the client is happy, their boss too is least bothered about their social behavior.

From last 8 years, both of them reach office at 9 am sharp in a modest hatchback car. They immediately start their work. Take a 30 minutes lunch break together. Wind up the tasks and leave the office by 6 pm. While most of their colleagues are angry with them for being anti-social, many envy of them for leaving office by 6 pm, daily, in IT industry. Very few people in their office were even aware about their residential location.

Deepak Thakur has been a busy man from last decade or so. He started his career 20 years back in a modest company. He quickly rose to VP level with his good communication skills and networking. Their company manufactured cloth for the military and masses. After sudden death of their CEO, Deepak was promoted to the CEO level and took the company to new heights. The ex-CEO was a good man with ethical working strategy. However, with this death, ethics were packed in the bag and drowned in the midst of sea. The company bribed, killed and tortured people for new contracts. The ex-CEO loyalist had to change sides, die or disappear. Off-course, neither of the killings were investigated or termed as murders. All were tagged as either ‘accidents’ or ‘natural death’. Even the ex-CEO’s death was tagged as suicide.

He started many new companies under fake names. However, each of them had to be closed for some or the other reason. Few of them became loss making machine, money suddenly disappeared from banks, few got embroiled in legal tangles, few fought with union problems, some of the genuine ideas were stolen by rivals, few of them died due to manpower shortage.

Initially, Deepak thought that all these things were part and parcel of business. Also, since money was coming from textile and cable TV network, he could continue to start new companies or pour money in existing loss making companies. However, the CAs and other finance guys started giving signals that his cycle won’t last long, if nothing has been done.
Deepak started another company under his watchful eyes. It created gold ornaments and supplied it to the local jeweler shops in the city. In-spite of taking all the due care, it got into legal trouble due to some rogue money transaction. The company employees claimed that they never did this transaction. However, the police had proofs and the company had to shut down.

This started making Deepak think if somebody was behind all his mis-adventure. After 2 years of careful investigation by private detectives and another company down the drain, Deepak could understand what was happening. His last 8 years of busy life was wasted in just starting and closing companies. In the process, he lost millions. All these companies were systematically chased and shut down by somebody via hacking and then legal procedures. After another year of investigation by the detectives, it was established that all these things were done to take revenge of killing of the ex-CEO of his company.

Friday, June 12, 2015

My new two wheeler - TVS Wego

After 6 months of going back and forward, we finally bought scooter. Ahh.. my first vehicle :) .. Feels nice? Off course it does.

Typically first question: was there a need of own vehicle?
My place is similar to Pune. If you do not have a vehicle (at least 2 wheeler), you are handicapped. The bus service is not remotely as good as BEST. You cannot depend on these machines.
Although, the necessity things can be bought right in the area, we do have to travel some distance (like 15 mins drive) to get some specialties. These specialties include chaat items, hotels or even shopping centers.

While we do not need hotels or shopping centers on weekly basis, having a 2 wheeler helps immensely to travel anywhere without depending on 'autoriksha' or bus.

Did I calculate cost per km spent if I travel by public transport vs own 2 wheeler? Hell, no. As I wrote sometime back, we need to look beyond money, many times.

Having own vehicle simply means, while getting down you do not have to worry about availability of auto or bus. I had many occasions of waiting for about 30 mins in the afternoon just to reach station for 5 mins work on a Saturday. Even though, in weekdays, I have to spend some waiting time for bus (since I do not commute on personal vehicle); spending 30 mins on Saturday is a strict no no.

Most of the reasons for buying a 2 wheeler are psychological and for convenience.

Once, we decided on buying a 2 wheeler, the next step was deciding which one to buy. Here too, we went by 'needs vs want theory'. The primary use of the vehicle would be to carry groceries from store to home, fetching vegetables from a near by market and off course for buying dinners in a month or two. So the obvious option was to buy a scooter rather than a bike. Scooter has almost a 10 kg capacity storage place along with some place near the legs for hanging bags. Bikes do not have luggage carrying capacity. When on bike, you have to bring someone pillion just to carry the bags.

Next, was which company to go with.

My wife is fan of TVS motor company. She had a TVS scooty which she used for more than 10 years without any engine problem. So one company was already short listed for comparison. However, we still had to have a look at Honda scooters (as they are the leaders in market in the scooter segment). We started with Honda. We went to their showroom and took test drive of Honda Activa 125 and Activa i (the plastic version of the earlier Activa). The same day we went to TVS showroom and took a test drive of Jupiter, Scooty zest and Wego. All the TD vehicles in Honda were worn out and difficult to drive. However, the one in TVS showroom were almost new and were amazing to drive.

We went home and thought about it for few days. We could not believe that Honda scooters were not as good as TVS. So we quickly concluded that the TD vehicles were not upto the mark or poorly maintained.

After few days, we decided to visit another showroom of Honda to check their TD scooters. I called that guy and asked if we can come and if they had models to see and check. After his confirmation we went there. On reaching, we asked for TD and the guy told that he does not have any TD vehicles. I was like, "why did I call you". And the answer was chilling - "You called and asked me if there were any vehicles to see and check. Here are the vehicles on display. You can see them and check but you cannot drive".

This incident completely turned our scooter picking process. Now, we simply had to choose from 3 TVS models !!!

We went again to TVS showroom to finalize on the model.

Jupiter looked crude copy of the Activa and was outright no no.

Zest and Wego looked nice and feature comparison was done between these 2 vehicles.

Both the vehicles have 110 cc engine (same as Activa 110). Wego has metal body and visibly larger tires than Zest. This meant Wego is more stable on highways (which was essential, since I stay very close to highway). Also, Wego comes with closed glove box while Zest has open folder like structure near the handle. The only advantage of Zest is it has wider utility box below the seat. I could place my helmet under it and lock it. Although, both Wego and Zest have same storage capacity (i.e. 10 kg below the seat), Wego cannot accommodate my helmet.
Both Zest and Wego gives about similar mileage i.e. 40-50 kmpl. Wego has decent looks while Zest has typical scooty looks. The more we explored, the more choice became clear - TVS Wego.

Wego has fuel filing location on the external body. Hence, we do not have to lift the seat while filling petrol. Unlike, Jupiter, Wego has the petrol opening parallel to ground which is very convenient.

The vehicle was deliverd in 1 week (disc brake Wego has some waiting period). This 1 week was spent for vehicle procurement , registration and insurance. It took another 1 week to get tax receipt.

Next plan of action is to complete the 1000 km on the odo at the earliest. This would enable quick break-in of the engine and long lasting performance. In 1 week, I could clock 100 km. However, immediate focus is to complete 500 km before 1 month and have the first servicing done.

For comparison and specifications, I have used sites like Team-Bhp, Honda official site and TVS official site. After comparing and listing what I wanted, I have bought TVS Wego.

The photo is used from the official TVS Wego website.

Monday, June 8, 2015

HP Truclient: Problem and Solutions

Recently, I was doing some self learning on the HP Truclient protocol. I took few sample applications and did the record- enhance-replay kind of stuff. 

This protocol looks extremely simple and easy to use. It is on the object level and hence no session or such values are captured in the script. Hence, there is no traditional requirement for correlation. However, the pros ends here. The cons are it consumes very high amount of RAM memory. To give you an idea, how much is the value, consider below example: A typical HTTP/HTML Vuser consumes about 2 MB of RAM for each Vuser. However, Truclient Vuser consumes minimum of 20 MB and that can go up to 60-80 MB depending upon the complexity of the application. The next problem is object level recording. 

Since, the records are all in terms of the properties of the objects, slight change in the application hampers the script completely. We have to modify the script to have new properties and then make it work. There is no straight forward option to vary the think time in the script. Having said that, this protocol is extremely useful for java-script and flex based applications.

Below is the learning from the protocol usage:

1. The machine on which I was working, had a unique problem. When we access the URL for the first time, it throws some HTTP 401 (access violation) error. However, on clicking refresh, the application works fine. To have this scenario, I recorded invoking of the same URL twice. The problem is, when the first step is executed, application throws the above error and the script is aborted. Due to the HTTP error, the script does not go to the next step and stops. 
Solution: Drag - drop 'Catch' function from the list in the script. This Catch function is kept directly after the first step. It's setting is - Catch Any Error. This enables the script to move forward irrespective of the script error. Note: since this was machine specific error, I opted for this. Had this been application issue, we would have to report it to the development team.

2. Normally, we divide the script in 3 sections, viz: Init (which contains Login), Action (which contains the business logic which has to be looped) and End (which contains the Logout section). With the as is settings, the script failed after moving from Init to Action section. The script could login into the application in the Init section. However, while moving, it refreshed everything and there was nothing to be done in the Action section.
  • Check the 'Simulate new user on each iteration'
  • Bring all the sections in a single section of Action and run.

If business logic does not permit you to have everything in a single Action, choose the first option. However, the first option would clear cache and other stored information on the browser for each iteration. This is not the real behavior. 

3. Object Identification: This is the pain, I was talking about earlier. Slight change in the application can play havoc with your script. 
Solution: Normally, when you record any application, go to the object properties, in that expand the Object section. There, it is recommended by HP to have Automatic drop down value. However, group discussions and as per the experience of the experts, it is better to keep 'Java-script'. Moreover, you can right click on the object on the Firefox and click on the 'Inspect Element'. This will give you the properties of that object. You can use this information for the object idenfication as well.
Example: The Search box has properties (check through Inspect Element), id=XXXXXXX.
Go to Object properties - Change the drop down value to Javascript. In the next edit box, comment the existing value and add: document.getElementById("XXXXXXX");
Since, we mention that getelementbyid, we should not write 'id=' inside the bracket which lists the arguments of the function.

4. The vertical scroll bar rolling was recorded but was not replayed. 
Solution: For this, go to Firefox address bar and type - about:config. This will open a list of settings. Search with scroll-bar. Change the below highlighted value to true. 

5. Network timeout: For some unusual long transactions, you may get error from the Vugen saying the transaction has exceeded the network timeout value. 
Solution: Go to Run Time Settings - Replay and increase the Network timeout value to say 1000 milliseconds.

6. Correlation: In spite of saying that this protocol does not need correlation, there may be some cases which would need to capture the data from the screen and pass it on to the script. 
SolutionWhile recording, click on that value which you want to capture. Post recording, change the 'Click' to 'Get Visible Text'. This function now will get the dynamic text from that object. Drag drop 'Evaluate Java script' from the list of functions. Write: window.alert(Paramname). This function displays the captured value from the previous step. This requires manual intervention to close the alert pop up and hence this is only for debugging. Make sure you are capturing the correct value. The Paramname has to be entered in the Variable (in the Arguments) of the 'Get Visible Text' function. Again, drag - drop 'Evaluate JS' function. Write java-script code as 'LR.setParam("Paramname", Paramname);' This code, will enable to use the 'Paramname' as a parameter throughout the script.

7. After invoking Vugen, you invoke Internet Explorer (in case of Truclient - IE protocol) by clicking on the 'Develop Script' button. After that you click on the Record button. Here, sometimes, we get error pop up saying - TCS has stopped working.
Solution: The workaround for this problem was suggested by one of my colleague and is: add below 2 lines in the default.cfg file in the Vugen folder: 
  • MeasurementLevel=0
  • ComponentBreakdown=0

The catch with this approach is that during the run time, the hits/sec and throughput will not be measured as we say that measurement level is zero.
The other alternate option is: switch to Truclient - Firefox protocol !!!

8. SSO implementation:
To enable accessing an application with SSO:
Internet Explorer: Go to Internet Options - Advanced - Check the option for 'Enable Integrated Windows Authentication*
Firefox: In about:config - add the desired url in the parameter network.negotiate-auth.trusted-uris

Above changes should enable the SSO for the application.

For recording in firefox:
Go to about:config and change network.negotiate-auth.allow-proxies to false
This will enable the login for the application by which you can simulate the SSO logins

Users, are you aware of any more such tips and tricks for HP Truclient protocol? If yes, could you please share them with all.