Monday, July 26, 2010

About Clickjacking - Security Testing

What is clickjacking ?

The attack works like this: the attacker first creates an HTML page that included an iframe sourced to a legitimate site, but he doesn’t just display the top left 200x200 pixels. Instead, he positions and sizes the iframe and other page elements so that only the pixels of a specific control, such as a button, of the victim page are visible. The attacker then presents this partial iframe control in a completely different context from its original context in order to trick users into pressing it.

Clickhijacking.html

1. Make a HTML file using below code and save with an html extension Or execute attached html file named "Gowall_Clickjacking.html".

html

body

h1>Hello World

iframe src="http://www.google.com/" height="200px" width="200px" /

/body

/html

2. Execute saved html file by clicking on it.

3. Observe that Google.com website is loaded in iframe in web page.

google website is loaded in iframe in web page.

For More information of attack visit:

1)http://blogs.msdn.com/sdl/archive/2009/02/05/clickjacking-defense-in-ie8.aspx

2)http://blogs.msdn.com/ie/archive/2009/01/27/ie8-security-part-vii-clickjacking-defenses.aspx

3)http://www.sectheory.com/clickjacking.htm

If page is displayed in the iFrame then site is vulnerable to clickjacking and if the target page load with as normal page in browser then it is not vulnerable.

--> We should also check all the pages of application whether they set the top.location javascript as shown below code or not. If not then those pages are vulnerable.

Prevention :

There are some techniques exit to prevent clickjacking for the website. For more information visit

1)http://usablelayout.com/articles/automatically-break-out-iframe

2)https://blogs.sans.org/appsecstreetfighter/2009/10/15/adoption-of-x-frame-options-header/

Some known site like gmail dosn't allow their page to be loaded in iFrame which prenvents from clickjacking attack: I have attached the gmail script named 'Gmail_Clickhijacking.html' execute it and oberve the behaviour.


Friday, July 9, 2010

How Test Estimation Process works


How Test Estimation Process works
Dear All,
When we need to give estimation for testing process, hope this article will help you guys. Feel free to add your inputs in it.
It is said to be number of test engineers would be half of the number of development engineers and on third of number of development working days.
Testing working days = development working days /3
Testing Engineers = Development engineers /2
Testing costs= Testing working days * Testing engineers * persons daily costs
Total Work = Test case time + Defect time
Test case time= Test development time + Test case execution time
Defect time = (hours/defects * #defects)
Note: Consider the defect severities while arriving at hours/defect and also that hours/defects should take into account the defect creation time, debugging time and defect retesting time till the close
Test case time
Test case Development time=(hours/TC development * #test case)
Test case Execution Time = (hours/TC execution * #test case)
Note: Consider the risk, complexity while arriving at the hours/test case development and hours/ test case execution
Example:
Suppose Number of test case =10
Number of resources =2
Each TC has average 50 cases/records
Take approximate 5 min of each testcase
50 *5= 250 min avg 4 hrs for each TC
4 hrs * 10 = avg 40 hrs for test
Test Estimation Rules
  1. Estimation shall be always based on the s/w requirements
  2. Estimation shall be based on expert judgment
  3. Estimation shall based on previous projects
  4. Estimation shall be based on metrics
  5. Estimation shall be never forget the past
  6. Estimation shall be recorded
  7. Estimation shall supported by tools
  8. Estimation shall always be verified