Sunday, September 30, 2012

CSAW CTF Quals 2012 Recon 1-3 Writeup


This weekend I participated in the CSAW 2012 Capture the Flag (CTF). Although I didn't have nearly the time I wish I had to spend on solving the problems, I wanted to make some writeups for those I did manage to solve in time.

The following problem categories were available to be solved:

  • Trivia
  • Recon
  • Web
  • Reversing
  • Exploitation
  • Forensics
  • Networking
Solutions to the challenges were awarded points based off of how difficult the solution would theoretically be to obtain, ranging from 100 to 600 points per solution.

I wasn't able to solve the final two 400 point Recon challenges (for Yoda, and Dan Guido's favorite foods), so if anyone participated and managed to find those solutions, I would be interested to hear how you went about it!

Recon 100 - Jordan Wiens (psifertex)

For this challenge, we are simply given a Google Search link for 'Jordan Wiens', one of the judges for the CTF, and the only knowledge we have about the key is that it will most likely be in the format 'key{something}'. Not much to go on, but we'll see what we can do.

The obvious sources of information as seen from the Google Search are his Twitter account, and Linkedin Accounts. From here, we can see the alias 'psifertex' commonly used. This may come in handy. On a hunch, we can check to see on which sites the name 'psifertex' is taken using a common tool called namechk.com. Using this tool, we see that psifertex is taken on quite a few websites, but none of these yield great results.

The next step would be to simply perform a Google Search for 'psifertex' and see if we find anything new. Fortunately, we notice the first result is psifertex.com, which only contains the string 'Nothing to see here, move along.' Not buying it, the next step of recon I like to perform on a domain is to try and brute force the subdomains. To do this, I use a tool called subbrute.py. This tool performs multithreaded DNS lookups to a configurable list of DNS resolvers, searching through a list of possible subdomains. It should be noted that I have tweaked and modified my own version of subbrute, and have added subdomains as I've found them, so the standard install may not work in this case.

However, I find the following output from subbrute.py for psifertex.com:

Checking psifertex.com
74.125.45.121 calendar.psifertex.com
74.125.45.121 docs.psifertex.com
69.163.249.183 ftp.psifertex.com
173.236.129.17 key.psifertex.com
69.163.249.183 ssh.psifertex.com
74.125.45.121 start.psifertex.com
69.163.249.183 www.psifertex.com

Obviously, the first subdomain of interest is 'key.psifertex.com', which indeed yields the key: 'secret sonambul1st'


Recon 100 - Jeff Jarmoc (jjarmoc)

For this challenge we were simply given a Google Search for 'jjarmoc'. Again, not too much to work with. Many teams had trouble with this challenge, yet I found this to be one of the easiest (most likely because I had performed the same recon with Jordan Wiens). From Jeff's Twitter page, we can see that he links offenseindepth.com as his homepage. Let's perform the same recon as before, and run subbrute. Here is the output:

Checking offenseindepth.com
107.21.146.162 finger.offenseindepth.com
173.201.193.71 imap.offenseindepth.com
74.125.45.121 mail.offenseindepth.com
107.21.146.162 www.offenseindepth.com

The only subdomain that seems out of the ordinary is finger.offenseindepth.com. Using the subdomain name as a clue, we can attempt to enumerate information about users on the host using the Finger service. Sure enough, by using jjarmoc as the username, we receive the following information:

jordan@crux:/pentest/recon/subbrute$ finger jjarmoc@finger.offenseindepth.com
Debian GNU/Linux      Copyright (C) 1993-1999 Software in the Public Interest
-----------------------------------------------------------------------------
Username: jjarmoc                   In real life:                       


Plan:
This is my .plan.  There are many more like it, but this one is mine.

{key:does anyone still use finger?}

-----------------------------------------------------------------------------

We can use the key 'does anyone still use finger' and we are awarded 100 points. Moving right along.

Recon 100 - Julian Cohen (HockeyInJune)

I actually found Julian's recon challenge to be the most difficult, only by my own oversights. All we are given is a Google Search for 'HockeyInJune'. This, like the other recon challenges, does not provide much information. However, using namechk.com, I can see that HockeyInJune has a reddit profile, which is consistently posting about the CSAW CTF, so we know it's the right guy. I mentioned my own oversights on this one, and it was simply because I checked every Reddit post except the one that had the key. After finally checking the link posted on the comment (cockcab.com), we can see that it clearly lists the key (although I didn't manage to write it down for this post, and now it looks have been removed).

So there you have it! Those were the first 3 recon challenges for the CSAW CTF. As mentioned, two more 400 point challenges were posted later in the weekend (Dan Guido's two favorite foods and Yoda), but I didn't have time to really look to much into them. If anyone managed to find the solutions, I'd be interested to hear how much work it took to found them!

A big thank you goes out to the organizers of the CTF. Everything went smoothly, and appeared to be well organized with interesting challenges. Hopefully next year I will have more time to work on the challenges, and won't be so bogged down with school projects.

I will post more writeups for the challenges as I create them.

-Jordan

Edit: Dan Guido gave a comment on Reddit that the solution to his Recon challenge could be found here. Thanks, Dan!


Sunday, July 22, 2012

Social Engineering Social Networks - How I Will Be Your Friend

Introduction

As detailed in a previous post, social engineering is a common, yet effective, tactic used by attackers that involves "manipulating a person to accomplish goals that may or may not be in the “target’s” best interest." This usually results in the attacker gaining unauthorized access to systems, areas, or information that would otherwise be unavailable. However, while it was briefly mentioned, we didn't really discuss the opportunities available for an attacker or pentester by utilizing one of the most common goldmines of information available today: social networks.

Almost everyone has one or more social networking profiles on one of the major social networking sites (Facebook, Twitter, LinkedIn, Google+, or Myspace), including high-value targets for a social engineering engagements (e.g. "C-level execs", President's, VP's, etc.). These profiles include information that can be critical to a social engineer when crafting the most effective spear-phishing email possible, obtaining answers to secret questions to gain access to systems, or when harvesting data that can be used in further targeted attacks. In this post, we'll look at how to utilize our social engineering skills to methodically "befriend" employees in order to quickly gain access to specific targets.

Tuesday, May 29, 2012

Are Security Certifications Useful?

Introduction

Security professionals either currently employed or seeking employment are often requested to pass certification exams. In fact, many companies may not even consider an applicant for a position that does not have the "required" certifications.

With this being said, in this post we will discuss the purpose behind certifications, how we should view their obtainment, as well as list of different certifications currently offered in the industry.

Thursday, May 10, 2012

RaiderSec Meeting 05/08/2012

Hey everyone!

I would like to apologize again for having to cancel the meeting this past Tuesday. Unfortunately, a class exam overrode our room reservation. However, you can find the slides to the presentation over lockpicking here. If you ever have any questions regarding the subject, please feel free to let me know either through e-mail or in the comments below.

I'm really looking forward to continuing RaiderSec next semester, and hope to use this summer to publish substantial new and interesting content to the blog. Sometime next week, I will post a list of the different things I'd like to cover next semester, but tentatively my goal is to give more hands on examples, as well as take time to look at unique areas of security. Above all, I want for everyone to enjoy learning about areas of security that interest them. So, if there is a particular subject you would like to see covered next semester, or even a subject that you would like to cover yourself, let me know and we'll make it happen!

I've really enjoyed our meetings, and I hope everyone else has as well. If you're here over the summer and would like to get together to discuss things pertaining to RaiderSec, be sure to let me know! Otherwise, I look forward to seeing everyone next semester!

Have a great summer!

-Jordan

Thursday, April 19, 2012

RaiderSec Meeting 04/17/2012

Hey everyone!

I just wanted to thank everyone who made it out to the meeting, and I hope you all enjoyed learning about Cross-Site Scripting (XSS) vulnerabilities and their exploitation. You can find the slides from the last meeting here.

As mentioned in the meeting, next Tuesday (April 24, 2012) Lance will be continuing the topic of input validation vulnerabilities in web applications by going in depth about SQL Injection vulnerabilities. The widespread prevalence and impact SQL Injection vulnerabilities can have will make this a very important and interesting topic.

I look forward to seeing everyone at the meeting!

Wednesday, April 11, 2012

RaiderSec Meeting 04/10/2012

Hey everyone!

I just want to thank everyone who made it out to the meeting yesterday! I hope everyone enjoyed learning about how social engineering attacks work, as well as why the human element of security is (and very likely always will be) the weakest link in a company's defenses.

As I mentioned in the meeting, next week we will begin covering web application vulnerabilities. Until then, feel free to read up on some of the vulnerabilities listed in OWASP's Top 10 Project Report to get an idea of the vulnerabilities we will be discussing in detail.

Also, you can find the slides for the social engineering presentation here. I look forward to seeing everyone at the next meeting!

-Jordan

Sunday, April 8, 2012

Social Engineering - Exploiting the Human Element of Security

Introduction

"Hi, this is Rick from [Internet Service Provider]. We're seeing some unusual traffic from your location. It's most likely nothing to worry about, but we have a field tech on his way to diagnose the problem. Can you make sure he has access to the network to run some quick tests?"

At most, this phone call may take 3-5 minutes, and already the risk for the target being compromised is very high, especially if the individual on the other end of the line agrees to help the "field tech" (very likely the same person who called). This technique is one very specific example of "Social Engineering," and throughout this post, we will see how these techniques are often leveraged by attackers to exploit the human element of security for malicious gain.