Skip to content

Latest commit

 

History

History
59 lines (30 loc) · 3.64 KB

File metadata and controls

59 lines (30 loc) · 3.64 KB

Lab: Working with the Command Line

Important Note: please do this lab without using generative AI (e.g., ChatGPT). Doing this lab with ChatGPT is trivial, but you want to build hands-on experience working with the command line interface / terminal --experience you will need throughout the course and in your career.

Part 1, The Basics (1 point)

Because this is largely a hands-on course, it is essential that you learn many of the fundamental Linux commands, an important skill for any good security practitioner.

If you are using macOS, you can also use the Terminal app. If you are using Windows 10, you can use the Linux subsystem. See instructions at https://docs.microsoft.com/en-us/windows/wsl/install-win10.

Please learn and tinker with the commands below and answer the questions below. Many commands will require flags.

Commands: ls, rm, mkdir, rmdir, cd, wget, pwd, ln, sudo, chmod, umask, ping, cut, sort, which, grep, whereis, finger, w, who, whoami, last, file, strings, top, ps, nice, nohup, kill, signal, more, less, ifconfig, arp, nslookup, cat, uname, history, netstat, curl, ifconfig, traceroute, shred, dig, man, lsof, whois, crontab, nc, uniq, id, groups, df, du, dd, openssl, tar, clear, touch

Answer the questions below. Answers may vary depending on operating system used.

  1. How would you find the path (i.e., location) to the gcc command?

  2. How would you download a file from the Internet?

  3. What is the full command to read the manual page of the command that formats and displays the on-line manual pages? (NOTE: there is no typo to this question)

  4. What command can you use to find out your IP address and MAC address?

  5. What command can you use to show all the processes that are running on the system?

  6. What command can you use to get more details about running processes listening on ports?

  7. What command with flag could you use to list every file, including hidden files, on the entire system, showing their owner, location, and access time? Please also note the flags that you used with command.

  8. Assume you found a file named warrent.pdf. What command could you use to find out what type of file this was?

  9. So you discovered that warrent.pdf is a binary executable. What command could you use to extract any readable information from the file without running it? Also, try this on a compressed file such a ZIP or JAR

  10. What command can you use to find the IP address-to-MAC address mappings for systems on the local network?

  11. Consider the following IP address: 46[dot]252[dot]26[dot]153. Where is the computer with that IP address located --in what country?

  12. For the previous question, what command did you use to determine the location of the computer?

  13. What command can you use to securely delete a file?

  14. What command can you use to see if you are a computer administrator or superuser?

  15. What command can you use to see list of previous commands you have entered on command line?

  16. What command can you use to see list of scheduled tasks running on your computer?

Part 2, Wargames (9 points)

Let's further hone your basic security skills by playing wargames. This set of wargames is offered by OverTheWire (http://overthewire.org/wargames/).

Play the Bandit wargame at http://overthewire.org/wargames/bandit/, beginning with level 0. Reach level 15 or higher (you can stop at level 15, 14=>15). To get credit, submit a selfie of you and your terminal screen showing that you reached level 15. Only JPG or PNG picture format will be accepted.

This part is dedicated to Olivia MacDougal, Class of 2018

Submitting This Lab

For students officially enrolled in the course, submit lab on Canvas.