{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Lab3 - Introduction to Computer Systems Spring 2011 Lab...

Info icon This preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Introduction to Computer Systems, Spring 2011 Lab Assignment L3: The Buffer Bomb Assigned: May 20 Due: June 2, 17:59 Introduction This assignment helps you develop a detailed understanding of the calling stack organization on an IA32(x86) processor. It involves applying a series of buffer overflow attacks on an executable file bufbomb in the lab directory. Note: In this lab, you will gain firsthand experience with one of the methods commonly used to exploit security weaknesses in operating systems and network servers. Our purpose is to help you learn about the runtime operation of programs and to understand the nature of this form of security weakness so that you can avoid it when you write system code. We do not condone the use of these or any other form of attack to gain unauthorized access to any system resources. There are criminal statutes governing such activities. Logistics You should work alone(only one people) in solving the problems for this assignment. The only “hand-in” will be an automated logging of your successful attacks. Any clarifications and revisions to the assignment will be posted on the course Web page or fudan BBS. Hand Out Instructions The lab handout is now available on the course web page (http://10.132.143.100/jpkc/labs.html), where you can also obtain your lab status information. Start by copying buflab-handout.tar to a (protected) directory in which you plan to do your work. Then give the command “ tar xvf buflab-handout.tar ”. This will cause a number of files to be unpacked in the directory: MAKECOOKIE : Generates a “cookie” based on your team name. BUFBOMB : The code you will attack. 1
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
SENDSTRING : A utility to help convert between string formats. All of these programs are compiled to run on Linux machines. In the following instructions, we will assume that you have copied the three programs to a protected local directory, and that you are executing them in that local directory. Team Name and Cookie It is required that each team consists of exactly one student. So the team name is exactly your ICS SVN id (e.g. ics10302010007). A cookie is a string of eight hexadecimal digits that is (with high probability) uniquely generated for your team. You can generate your cookie with the makecookie program giving your team name as the argu- ment. For example: unix> ./makecookie ics10302010007 0x7b2259d0 In your four buffer attacks, your objective will be to make your cookie show up in places where it ordinarily would not. The B UFBOMB Program The BUFBOMB program reads a string from standard input with a function getbuf having the following C code: 1 int getbuf() 2 { 3 char buf[12]; 4 Gets(buf); 5 return 1; 6 } The function Gets is similar to the standard library function gets —it reads a string from standard input (terminated by ‘ \n ’ or end-of-file) and stores it (along with a null terminator) at the specified destination.
Image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern