Important: All students are required to read the Syllabus, which outlines the major course policies, and Collaboration Policy, which describes the rules surrounding collaboration with other students and referencing external sources outside of the course. Please make sure you understand these policies well! (The section below elaborates more on some additional policies that aren’t covered in either of those documents.)
This is a course on computer systems security through a balanced mixture of theory and practice.
We’ll start out with building the foundations of security through an exploration of cryptography. From there, we’ll move to more complex, multi-faceted systems such as web applications, operating systems, and networks. Along the way, we’ll explore complementary topics such as authentication, physical security, social engineering, privacy, anonymity, usability, and the security of emergent systems such as blockchains and machine learning.
By learning about security through these multiple domains, you’ll concretely learn how various classes of attacks appear in a vast variety of scenarios and how they work in practice. You’ll also learn how to evaluate systems adversarially, from writing precise security analyses about subtle issues in protocols to discovering and exploiting vulnerabilities in concrete technical systems for yourself.
Through all of these activities, you’ll ultimately work to develop a specific kind of intuition—a “security mindset”—that will give you the knowledge, vocabulary, and confidence to critically analyze and effectively defend the software and systems you approach as a computer scientist even after the course.
We strongly encourage you to consider taking CS162, the additional half-credit “lab”. If you take CS162, you’ll have the opportunity to work on advanced challenges that will provide you with a greater appreciation of systems security and the “security mindset” as a whole:
CS162 is intended to be taken concurrently with CS166 and provides students with a deeper understanding of the material by doing advanced versions of the CS166’s projects and advanced questions on the written assignments (homeworks and midterms). These advanced versions focus on real-world skills: performing attacks that are more difficult and rely on less serious vulnerabilities, performing attacks against systems with more real-world constraints, and creating attacks that achieve a higher standard of quality than a mere proof of concept.
In previous years, CS162 students report spending approximately 8 to 20 extra hours on each project throughout the semester, though they also note that the additional components are more front-loaded so the second half of the semester is much more flexible. (We anticipate that this will be the same this year.) You do not need any additional experience on the base prerequsites of the course to succeed in CS162—anyone who feels comfortable taking CS166 and is able to put in the extra time should also feel comfortable taking CS162.
If you’re interested, undergraduate and PhD students should register for CS162 as normal on Courses@Brown. (Senior undergraduates are eligible to capstone with CS162—email the HTA list if you intend to capstone.) If you’re a Masters student, you may earn 2000-level credit for CS166 by completing the CS162 requirements—email the HTA list if you want to do this.
If you don’t meet the official prerequisites but still want to take the course, talk to the HTAs (they can advise you on your particular situation).
Your willingness to challenge yourself is perhaps the most important prerequsite for the course. Security can be frustrating at times, but the rewards are great—in exchange for engaging with some difficult intellectual challenges, you’ll have the opportunity to gain concrete insights about systems and security and become a better computer scientist by the end of the course.
We will have live lecture on Tuesdays and Thursdays @ 1pm - 2:20pm ET using Zoom. The information needed to access the lectures is available on the Piazza board.
Attendance Policy: Attending lectures synchronously and active class participation is highly encouraged, but not required. While lecture will be recorded, class participation will help the instructor better assess your understanding of the topics in determining the final grade.
The instructor determines overall letter grades by taking into account the final numerical grade and, in borderline cases, class participation in both lecture and sections. If you can’t attend lectures, we recommend that you try to attend one of the sections each week (though section attendance is not required). In other words, not attending lecture and section won’t directly impact your grade, but you might get more out of lecture and section if you’re able to participate (and, if you’re at a letter grade boundary, class participation and attendance might positively impact your final letter grade at the instructor’s discretion).
If you’re unable to attend lecture on a given date, you don’t need to notify us. (If you’ll routinely be unable to attend lecture—for instance, due to time zone constraints—email Bernardo briefly explaining why in the first two weeks of the course.)
Asking Questions: During the lecture all students will be muted, but we encourage signaling your questions via Zoom chat. This helps us maintain a queue of student questions. You can either ask your question directly in the chat, or, if you want to ask your question verbally, simply type the word
"question" in the chat and Bernardo will signal to you when you can unmute and ask your question.
Recording Policy: Lectures will be recorded and made available to all registered students within 24 hours of the lecture date via this Panopto folder (during shopping period, if you are not officially registered, you need to have CSCI1660 in your Primary Cart on Courses@Brown in order to see the Panopto folder). We will also post lecture slides for each lecture. For organizational and privacy reasons (some course content covers sensitive topics), the lecture recordings (not the slides) will be automatically removed three weeks after each lecture is given. However, if you have extenuating circumstances that prevent you from watching a given lecture within three weeks, email Bernardo to request a one-off extension to view a given lecture past that time.
“Chatting Time”: The 10 minutes following the end of lecture are “Chatting Time”. During “Chatting Time”, Bernardo (and, occassionally, some of your TAs) will remain in the Zoom call and will be available to answer any questions about the lecture material, talk about course logistics, or, in general, just chat with students and other course staff members before the call ends. (“Chatting Time” won’t be included in the Zoom recording.)
Zachary and William will lead synchronous weekly recitation sections on most weeks. Sections are optional, but attendance is highly recommended—many students in previous years find that they’re directly helpful on for working on the assignments in the course in preparing for the midterms. (They’re also designed to give you an opportunity to get to work with and meet some of your fellow classmates in the course.) Please see Sections for more information.
The Collaboration Policy details the rules surrounding collaboration on all aspects of the course and plays a major role in the pedagogical goals of the course. Please read it in its entirety and make sure you understand its contents before working on any assignment in this course.
To emphasize the points related to collaborating with other students in the course:
Midterms: Must be completed entirely independently. Any form of collaboration on midterms is strictly prohibited other than that detailed in the Collaboration Policy.
Projects: Whenever you’re actively interacting with project systems, you must do so entirely independently. “Actively interacting” includes having the project systems (binary, website, etc.) within sight or interacting with them, exploring system source code, writing your deliverables (solutions, writeup, exploit code, video, etc.), and so on. You also may not share your deliverables with others, and you may not read others’ deliverables.
That said, we allow discussion of projects with other students as long as no student in the discussion is actively interacting with the project systems. You should treat project-based discussions like going to TA hours—that is, focus on high-level hints, prodding questions, and occasional debugging help on narrowly scoped technical issues, but don’t give away full answers. Finally, when you talk to other students about projects, you must cite those students in your handin. See the Policy for more details.
Homeworks: You’re permitted to (and encouraged to) discuss any aspect of the homework problems with other students currently in CS166. In this course, the homework problems generally will require you to approach problems from different angles and are designed to encourage discussion amongst students.
However, you must write your homework solutions entirely independently. You may not share your solutions with anyone (or read solutions written by others). You should not write your solutions while working with other students, and when you’re writing your solutions, you should ensure that you independently understand and can reproduce your answers without referring to notes from collaboration sessions and consulting with other students. (Homework Clinics are not exempt from this policy.) Finally, when you talk to other students about homeworks, you must cite those students in your handin. See the Policy for more details.
Even if you’ve read the above summary, please read the remainder of the Collaboration Policy, since it covers more policies on referencing external sources, how to cite other students in your handins, etc. If you have any questions about the Policy, please ask on Piazza.
|Homework 0||Jan 22||Jan 28|
|Homework 1 (solution)||Jan 29||Feb 11|
|Homework 2 (solution)||Feb 12||Feb 22 / 25|
|Homework 3 (solution)||Mar 9||Mar 20 / 22|
|Homework 4 (solution)||Mar 23||Apr 3 / 5|
|Cryptography||Jan 26||Feb 8|
|Flag||Feb 9||Feb 28|
|Handin||Mar 5||Mar 18|
|Dropbox||Mar 19||Mar 26, Apr 11|
|Jan 21|| Course Intro: Logistics, Security Principles |
Textbook chapters: 1.1, 1.3.1, 1.3.3, 1.3.4, 1.4
|w/ Bernardo, William, Zachary|
|Jan 26|| Cryptography I: Symmetric Crypto, OTP, Hash Functions |
Textbook chapters: 8.1.1, 8.1.2, 8.1.3, 8.1.4, 8.1.6, 8.1.7, 8.3
|w/ Bernardo, Sierra, Lilika|
|Jan 28|| Cryptography II: Block / Stream Ciphers, Public Key Crypto, Signatures |
Textbook chapters: 1.3.2, 1.3.5, 8.2.1, 8.2.2, 8.4 (except 8.4.2), 7.1.2
|w/ Bernardo, Zachary, Lilika|
|Feb 2|| Cryptography III: MACs, IND-CPA / Authentication I: Passwords, AAA |
Textbook chapters: 1.4.2
|w/ Bernardo, Lilika, William, Zachary|
|Feb 4|| Web Security I: Browser Security, SOP |
Textbook chapters: 7.1, 7.2.3
|w/ Bernardo, Lilika, William, Zachary|
|Feb 9|| Web Security II: Session Management, CSRF |
Textbook chapters: 7.2.5, 7.2.7
|w/ Bernardo, Lilika, William, Abby|
|Feb 11|| Web Security III: SQL Injection, XSS |
Textbook chapters: 7.2.6, 7.3.3
|w/ Lilika, Zachary|
|Feb 16||Long Weekend (No Class)|
|Feb 18||Web Security IV: Frameworks / Authentication I.5: Passwords, Again||w/ Bernardo, Lilika, Zachary|
|Feb 23||Authentication II: MFA||w/ Bernardo, Lilika, William|
|Feb 25||Systems I: Malware||w/ Bernardo, Lilika|
|Mar 2|| Systems II: Storage Encryption |
Textbook chapter: 9.7
|w/ Bernardo, Lilika, Charlotte|
|Mar 4|| Systems III: Operating Systems |
Textbook chapter: 3
|w/ Bernardo, Lilika, Charlotte|
|Mar 9|| Networks I: The Layers, MAC, IP, Routing |
Textbook chapters: 5.1, 5.2.1, 5.2.2, 5.3.1, 5.3.2
|w/ Bernardo, Lilika|
|Mar 11|| Networks II: ARP, TCP, UDP, NAT |
Textbook chapters: 5.2.3, 5.3.3, 5.3.4, 5.4.1, 5.4.2, 5.5.3
|w/ Bernardo, Lilika, Zachary|
|Mar 16|| Networks III: DNS, SSL, TLS |
Textbook chapters: 6.1
|w/ Bernardo, Lilika, Charles|
|Mar 18|| Networks IV: Cloud Security (Guest Lecture) |
Textbook chapters: 7.1.2, 8.2.4
|w/ Roberto Tamassia|
|Mar 23|| Networks V: Key Exchange, Pentesting |
In-class demo: Pentesting
|w/ William, Bernardo|
|Mar 25|| Applications I: Anonymization, Distributed Blockchains, Cryptocurrencies |
In-class demo: Tor
|w/ Bernardo, Lilika|
|Mar 30|| Applications II: Contact Tracing, Usable Security |
Reading: “Contact Tracing: Cryptography Specification” by Apple
|w/ William, Zachary|
|Apr 1||Applications III: Firewalls, BGP, Heartbleed, IPV Security||w/ Bernardo, Lilika|
|Apr 6||Applications IV: Ransomware, Incident Response||w/ Bernardo, William, Zachary, Lilika|
|Apr 8||Applications V: Meeting with An Expert (Guest Lecture)||w/ Royal Hansen|
|Apr 13||Reading Period (No Class)|
|Apr 15||Reading Period (No Class)|
Starting with the March 10 section, we’ll be switching the section schedule to once per week at Wednesdays @ 8pm ET and the sections will mostly be entirely led in lecture format (i.e. no practice problems) for the remainder of the semester. In each section, we’ll review course content from the past week, cover new content that may be helpful on the assignments, and/or give advice on approaching the technical projects——see below for specific content. As usual, slides will be posted and sections will be recorded for later viewing for those who are unable to attend live.
|Jan 27 / 28||Cryptography A||Handout||Video: Zachary / William|
|In this section, we’ll go over a few hints and tips for the Cryptography project and, more generally, how to think about the "security mindset". We'll also cover some additional material on hash functions. (This week's practice handout will focus on the Cryptography I lecture.)|
|Feb 3 / 4||Cryptography B||Handout||Video: Zachary / William|
|In this section, we’ll review the second half of the Cryptography lectures. (This week's practice handout will focus on the second half of the Cryptography lectures.)|
|Feb 10 / 11||Web Security A||Handout||Video: Zachary / William|
|In this section, we’ll extend our discussion of CSRF and session-focused vulnerabilities to some new web attacks. We'll also give some advice on how to approach the Flag project. (This week's practice handout will focus on the first half of the Cryptography lectures—with the exception of SOP content, which you'll review more on Homework 2!)|
|Feb 17 / 18||Web Security B||Handout||Video: Zachary / William|
|In this section, we'll focus on "code injection"-related attacks similar to the XSS and SQLI exploits we discussed in lecture. We'll also use this background to motivate discussion about client-side modification attacks. Finally, we'll give some hints and tips for the Bob's Router part of the project.|
|Feb 24 / 25||Review: Midterm 1||Handout||Video: Zachary|
|In this section, we'll spend a little bit of time reviewing the Authentication lectures, but we’ll spend most of the remaining time hosting an open Q&A to review previous content from the course in preparation for Midterm 1.|
|Mar 3 / 4||No Section (Midterm)|
|Mar 10||Unix Security + Handin||Video: William|
|In this section, William will connect our discussion from the Systems III lecture to a much broader security idea we've previously seen in the course ("code as data") and talk about some tips for the Handin project. This section covers new material that relies on past lecture content, so make sure you're up-to-date on the lectures before attending. (No section handout this week.)|
|Mar 17||Networks||Video: Zachary|
|In this section, Zachary will extend our discussion from the Networks lectures to further details about the protocols. This section covers new material that relies on past lecture content, so make sure you're up-to-date on the lectures before attending. (No section handout this week.)|
|Mar 24||Summing It All Up: Dropbox||Video: William|
|In this section, we'll recap some ideas from the Cryptography, Networks, Cloud Security, and Blockchains lectures to show how you might find some inspiration in past course material for the Dropbox project. (No section handout this week.)|
|Mar 31||No Section|
|Apr 7||No Section|
|There will be no Midterm 2 review section, but the Homework Clinics will remain open during this time for general questions in preparation for the midterm (even though there is no homework out during this time)—if you have questions about course content, please attend one of the Homework Clinics this week!|
|Apr 14||No Section (Midterm)|
We have two types of TA office hours in CS166.
In Project Hours, you can ask for help on anything related to the projects (clarifications, code, etc.), lecture material, or general concepts. Any questions about homework content should be directed to Homework Clinic or Piazza (exception: CS162 students may ask about CS162-only homework content at Project Hours).
In Homework Clinics, students collaborate on homework problems in a group-work environment under the guidance of the TAs. Homework Clinics are designed specifically to help students on the homework problems or any conceptual problems related to the homework. Any questions outside of the homework content should be directed to TA Hours or Piazza.
All students are responsible for the contents of the following documents and registering for the following external services used in the course:
Textbook: The textbook for the course is Introduction to Computer Security by Michael T. Goodrich and Roberto Tamassia, 1st Edition. The lecture schedule includes supplementary readings from the textbook, and you’ll find the textbook directly helpful on most assignments in this course.
Gradescope: We use Gradescope for collecting certain assignments and grade distribution. We add students to our Gradescope page manually based on waitlist signups and course registration—if you’re trying to hand in but aren’t able to access the page, please email the HTA list.
Piazza: Join our Piazza board to ask questions about course content (see the Collaboration Policy for question guidelines). The course staff will also post announcements and assignment clarifications to this board. All Piazza questions must be posted privately by default, though the course staff will make posts public when necessary.
Regrade Policy: Before submitting a regrade request, please read the Regrade Policy.
Extension Requests: If there are extenuating circumstances preventing you from completing an assignment on time (e.g., illness), you may use this form to request an extension (without using late days) before the assignment is due. (Dean’s Notes and SEAS Accomodations should not go through this form—any inquires of the sort should be sent directly to Bernardo.)
Anonymous Feedback: If you have feedback that you’d wish to share anonymously, you can use this form. Emails are tracked on this form, but these email addresses cannot be viewed by the course staff (including the professor) and are only viewable by Thomas Doeppner (Director of Undergraduate Studies).
Undergraduate Missive: The Computer Science department’s Undergraduate Missive contains lots of helpful information regarding asking for help from TAs, Sunlab Consultants, and more. (Some information is useful for graduate students as well.)
Diversity and Inclusion: In addition to the following resources, you can email the Student Advocates for Diversity & Inclusion at
Health and Wellness: In addition to the following resources, you can email the Student Advocates for Health & Wellness at
Student Groups: The department sponsors or is affiliated with several student groups:
Writing Center: The Writing Center offers free consultations for students who would like to improve the quality of their writing; this is relevant in CS166 since the written components of the course involve communicating complex technical ideas clearly, concisely, and precisely. Appointments can be scheduled on the Writing Center website or by emailing
CAPS (Counseling and Psychological Services): If you feel yourself falling behind, needing to talk to someone about personal problems, or, in general, want a supportive ear, you may find CAPS helpful—they provide a range of mental health services to the Brown community. The office can be reached at 401-863-3476 or
SAS (Student Accessibility Services): Brown University is committed to full inclusion of all students. Students who, by nature of a documented disability, require academic accommodations should contact the professor. The staff of the SAS office can be reached at 401-863-9588 or
firstname.lastname@example.org to discuss the process for requesting accomodations.
Ombudsperson Office: The Ombuds Office provides a safe, informal, and confidential service independent from the University administration for students involved in a University-related problem (academic or administrative), acting as a neutral complaint resolver and not as an advocate for any of the parties involved in a dispute. The Ombudsperson can provide information on policies and procedures affecting students, facilitate students’ contact with services able to assist in resolving the problem, and assist students navitgate conflicts concerning improper application of University policies or procedures. All matters referred to this office are held in strict confidence (with the exception of cases where there appears to be imminent threat of serious harm).
Student Support Services: Student Support Services assists students with a wide-range of issues and concerns that might arise during their time at Brown. The Student Support Services Deans provide 24-hour crisis services for undergraduate, graduate, and medical students with personal or family emergencies, and are available by appointment to consult with individual students about their personal questions/concerns, thus allowing students to succeed and thrive in their academic pursuits.
Administrator on Call: The Student Support Services office manages Brown’s Administrator On Call (AOC) system which provides a mechanism for Brown students to seek assistance in emergency situations after business hours. An AOC is able to respond to students, connect them with resources and referrals, consult with colleagues as needed, and gather information for additional follow-up during business hours. To reach the AOC, call 401-863-3322 and ask to speak to the Administrator-On-Call.
Each of these courses cover relatively disjoint material, and you’ll learn completely different things in all of them. (If you haven’t taken any of them—great! CS166 is a great introduction to the field, and you’ll learn a lot through this course. If you have taken a subset of these courses—also great! A lot of CS166’s material will still be new to you, and all of these courses are useful in terms of honing your security mindset for the long-term.)
If you’re a 7th semester (or greater) undergraduate, then you can use CS166 as a capstone by completing the CS162 requirements—you’ll need to register for CS162, and you need to email the HTA list.
If you’re a graduate student, then you can use CS166 for 2000-level credit by completing the CS162 requirements.
If you’re a Masters student and want 2000-level credit, you should not register for CS162 (since it’ll cost you more tuition!). Instead, you should email the HTA list indicating that you intend to complete the CS162 requirements for 2000-level credit.
If you’re a PhD student and want 2000-level credit, then you should register for CS162. (No need to email the HTA list in this situation.)
Please read the Lecture Policy. If you are looking to request Simultaneous Enrollment Permission on ASK to register for another class in the same timeslot as CS166, please email the instructor—we will approve such requests, but please note that lecture attendance and class participation in CS166 can help your final grade in borderline cases.