10 GOOD BOOKS FOR HACKERS & SECURITY ENGINEERS



2019 Sep 9

Glowing text saying "leet books" with dark clouds in the background

Photo by Cheryl (modified) / CC BY 2.0

One of my blogging goals is to help somebody out there better plan and execute his or her infosec learning objectives with respect to books. More specifically I’m writing this post to assist someone seeking to save time reading. I hope that the book reviews and recommendations below do so.

If you’re focused and deliberate about pursuing knowledge, then you likely know that merely identifying books with intriguing titles or subjects, getting yourself a copy, and telling yourself that you’ll get around to reading it falls short of an actionable, reliable plan to learn what you need to know. There are just too many awesome learning materials out there for one person to consume. All one can do is make informed decisions on including, excluding, and prioritizing a particular learning resource within his or her overall learning plan.

Believe it or not, I’ve completed ten books in the last five months. Here are the titles I’ll be discussing in this post:


  1. Hacker Methodology Handbook
  2. Red Team Field Manual
  3. Hash Crack
  4. The Hacker Playbook 3
  5. Write Great Code, Volume 1
  6. Gray Hat Python
  7. Think Like a Programmer
  8. Black Hat Python
  9. Learn and Master C Programming
  10. Intro to 80x86 Assembly


A secondary goal for this post is to support fellow infosec practitioners in navigating any of these ten specific books more easily by summarizing what I regard as the most important ideas, spelling out concise setup instructions, and explaining any learning obstacles (‘gotchas’) I experienced while studying. Let’s dive in.


Hacker Methodology Handbook


Hacker Methodology Handbook


Description & Review

Hacker Methodology Handbook (HMH) is a ~90 page penetration testing command reference book written by Thomas Bobeck and independently published in late 2018. It contains over 350 CLI commands for more than 100 different tools and programs, and it organizes them by pentesting phases such as recon, enumeration, exploitation, privilege escalation, pivoting, data transfer, etc.

HMH’s relatively small page count is deceptive. It took me a lot of time (weeks!) to systematically test nearly all of the commands. The vast majority of the CLI commands ran as expected, but there were a fair number that didn’t work for me as they were written in the book. At times it felt like I had ‘stepped on a landmine’, and that was somewhat frustrating, but it also motivated me to expand my knowledge of the underlying programs being exhibited.


Recommendations

At the time of this writing HMH costs less than $12 USD, so buying a copy is relatively cheap. More important than the money, though, is how you plan to budget your time with this book. In my case, I wanted to run every CLI command and test every tool it demonstrated. I’m not a pentester, so I was able to learn some things that were completely new to me by doing this. For someone else, though, it probably doesn’t make sense to approach this book how I did.

For most people I’d wager than skimming through the table of contents, selecting a pentesting phase (e.g. privilege escalation), reviewing the listed CLI commands, and testing the more interesting ones is sufficient. Whatever you might do, reading a book in any way disconnected from the bigger picture of your individualized learning objectives isn’t helpful, so keep your specific goals in mind when working with reference books like this one.


The Most Important Ideas

HMH is incredibly light on conceptual explanations or rationales. There’s maybe less than five short explanatory paragraphs throughout the whole volume. The burden is on the reader to understand exactly what a program is doing, how it does it, what type of output to expect, and how it might compare or contrast with other pentesting tactics for a given attack phase. It truly is a command reference book. It doesn’t try to be anything else, and that’s okay.

There’s no big, overarching idea or lesson to be learned within HMH, and I don’t say that with any negativity. All of the ‘ideas’ are presented as tools, commands, and CLI argument options the user has the choice to utilize in a certain pentesting scenario. In that respect, this book is good at getting you started in a you-don’t-know-what-you-don’t-know situation by presenting ideas in the form of CLI examples.


Setup, Gotchas, etc.

To test the referenced commands I simply made a Windows 10 VM and an Ubuntu Linux VM, and I executed each command in its respective operating system. Most of the programs used are pre-installed, but a small number were not, and so I had to download some. One example is from page 23 which references ‘local’ and ‘global’ commands. Searching online led me to the ‘local.exe’ and ‘global.exe’ Windows programs. These tools are apparently part of Windows NT Resource Kit, and they are not installed on Windows 10 by default it seems. Luckily, I found copies from here.

Know that HMH contains a few small syntax errors, typos, misplaced commands, and the occasional duplicate command. For example, at one point the book refers to the ‘msconfg’ command though it was likely intended to say ‘msconfig’ instead. Also, page 16 erroneously shows CLI examples for the ‘dmitry’ program within the ‘netdiscover’ section. There aren’t really any obnoxious flaws in the book that truly prevent the reader from learning what the author intended, though.

One final note for readers that are seriously engaged with this book’s content: the reverse shells listed on pages 68 and 69 are identical to ones posted online by pentestmonkey. If you’re planning on using these commands then save yourself the time and copy/paste from the web instead of manually re-typing them.


Red Team Field Manual


Red Team Field Manual


Description & Review

Red Team Field Manual (RTFM) is a offensive security command reference book written by Ben Clark. It was published in 2013 (six year ago now), and it’s about 80 pages of content. RTFM covers close to 400 CLI commands across roughly 120 software programs. It organizes commands by fields of technical knowledge such as *nix, Windows, networking, web, databases, wireless, etc.

The font size in RTFM is noticeably small, so each page is quite dense with commands. Additionally, this book contains useful reference information for important filesystem paths, OS version IDs, Windows registry locations, wireless frequencies, user-agent strings, and more. Overall, I’d say this is a fantastic book that’s absolutely full of valuable tidbits across a good variety of offensive security tactics.


Recommendations

My goal with this book was to test all of the CLI commands (yes, every single one) to get a better appreciation for the software tools involved, and this took me a couple weeks to complete. I approached it by setting a daily goal to review a certain number of pages, and this allowed me to stay on track and make incremental progress without much disruption.

This book might provide a different value to other readers, though. Since RTFM is structured as a reference book, the average reader might expect to pick it up, turn to a topical section (e.g. databases), and find a CLI command example for a task he or she is attempting to complete during a penetration testing engagement, practice exercise, or similar.


The Most Important Ideas

RTFM covers a great number of Linux programs and tools, and I’m happy with it in that respect. If you’re already a Linux expert, then many of the Linux CLI examples may bore you with their simplicity. However, the book also includes a handful of multi-line scripts (Bash, Python, etc.) that will probably still retain your interest.

For example, RTFM contains command execution examples for the iptables program that sport 10 or more lines of input. On one hand it’s nice that the book doesn’t shy away from teaching vital tools regardless of any heightened complexity of use. On the other it can be daunting or annoying to see a block of text (with quite a small font size) that the reader will need to type into a terminal without error to fully test and experience the example shown. My advice is to be picky with the scripts and multi-line commands you find most worthwhile to execute.


Setup, Gotchas, etc.

Fortunately, many of the Linux-based programs come pre-installed on Ubuntu. I was able to run over ~90% of the CLI examples in the book within either an Ubuntu Linux or Windows 10 VM. However, there are a small number of commands that only work on FreeBSD or Cisco IOS, and I personally opted to skip those ones. It’s not overly difficult to set up a test environment that incorporates those OSes, but I wanted to get through the book fairly quickly so I focused my time on the Linux and Windows examples.

In the web section, the commands tend to make assumptions about the target website’s URL parameters. Some of the SQLMap examples weren’t really testable without a handy website that happened to mirror the URL format as written in the text, so I also skipped over these. Seeing the tool syntax and playing around with SQLMap in general is enough to get the picture either way.


Hash Crack


Hash Crack


Description & Review

Hash Crack: Password Cracking Manual is a highly specialized reference book written by Joshua Picolet covering practical attacks that aim to defeat present-day authentication and encryption systems. Version 3 was published in 2019, and it’s about 130 pages in length. Hash Crack contains roughly 350 CLI commands corresponding to more than 50 unique tools. The book is organized by major concepts within the cracking realm such as hash extraction, wordlists, password analysis, rules and masks, cracking methodology, and more.

I really, really like this book. Password cracking is such a multifaceted and somewhat complicated discipline, and I don’t have multiple years of experience doing much of it professionally (on a pentest, for forensic data recovery, etc.) so I learned a ton of new-to-me tricks that I otherwise wouldn’t have. Not only did the CLI examples help me with specific command syntax, but Hash Crack also contains numerous cheat sheets, lists of tools, example hash formats, scenario descriptions, detailed conceptual explanations, and more. I strongly recommend Hash Crack to anyone serious about learning password cracking and gaining hands-on experience.


Recommendations

Like my other command reference books, I approached this one by attempting to near-exhaustively test all of the commands listed throughout the volume. For a typical reader, though, they should probably just use this book as a reference when a specific scenario calls for cracking. The Common Hash Examples section (pages 105 through 118) gives you the most bang for your buck by quickly spelling out the hash formats (MD5, NTLM, bcrypt, etc.) associated with commonly-used products (7-Zip, Microsoft Office, etc.) and how to mount an attack with either hashcat or john. It’s a great place to check for fast answers and ideas.

Hash Crack also refers to many online resources. Here are a few that stood out:


The Most Important Ideas

The Core Hash Cracking Knowledge section at the beginning of the book is solid. There are two significant ideas, represented as equations, that I think are the most critical ideas from the book to commit to memory:

  1. Keyspace = Character Set ^ Password Length
  2. Cracking Time = Keyspace / Hashrate

The book explains that hashing function identification (solely from looking at a hash’s format) isn’t foolproof, and that the context matters (read: From where was the hash retrieved?) when attempting to identify which type of attack to attempt. Also, Hash Crack has dozens of mask examples including ones for popular password generators (e.g. iCloud Keychain) and using one can likely reduce your cracking time if you know which generator the target used.

Lastly, page 122 lists the 10 Cracking Commandments which I think adequately capture the most important concepts one should grasp and thoroughly consider when cracking passwords.


Setup, Gotchas, etc.

Page 5 of Hash Crack lists the required software to follow along with the tactics as presented. Hashcat and John the Ripper are the most heavily-used programs throughout the book, but others play an important role too. Generally, all the necessary tools were straightforward to download and test. This page also provides a legend that explains the CLI command notation that the author consistently adheres to with every example. It’s definitely worthwhile to understand it before getting your hands dirty.


The Hacker Playbook 3


The Hacker Playbook 3


Description & Review

The Hacker Playbook 3, written by Peter Kim and published in 2018, is the third volume in The Hacker Playbook (THP) series that covers a sizable number of offensive infosec topics and hacker tactics, techniques, and procedures (TTPs) in amazing detail. Throughout more than 270 pages of content, the author explores subjects such as infrastructure setup, recon, webapp exploitation, lateral movement, social engineering, physical attacks, defense evasion, and more with a focus on practical application.

This book is so dense and jam-packed with such an intense amount of detail that it can be somewhat intimidating, but this is also what I think makes it one of my current favorites too. The Hacker Playbook 3 is absolutely exploding with URLs to all kinds of resources like software tools and further subject-specific reading. I counted more than 100 unique URLs nearly all of which I visited while reading. THP also features diagrams, program output snippets, screenshots, CLI command examples, and thorough, detailed conceptual descriptions of vulnerabilities, exploits, and the real-world TTPs in play. I really appreciate this book as both a great read and as a reference I can revisit.


Recommendations

The Hacker Playbook 3 is not for the feint of heart. It simply has so many exercises, external references, follow-up reading suggestions, and tools to learn that you could probably design an entire college semester’s curriculum from this one book alone. If you’re getting paid to save the world on a full-time basis, though, my estimate is that it could realistically take almost a year to truly complete every lab and learn every tool while still balancing one’s professional responsibilities.

I don’t say this to dissuade anyone in particular from getting a copy of this book and giving it a fair shot. It’s just a really good idea to know exactly how much you’re ‘biting off’ here, and to plan your approach and time commitments accordingly before you set any goals involving THP. It’s okay to skip lab exercises that aren’t relevant to you at the time you begin reading. It’s also okay to feel overwhelmed by the sheer depth of detail. My advice is to read over the table of contents, pick one or two chapters that best align with your personal learning objectives, and commit to completing only those exercises and researching the relevant externally-linked tools and resources. Of course you don’t have to limit your hands-on practice to one or two chapters, but this is definitely a book to revisit multiple times. Don’t try to master absolutely everything on the first try. Give yourself time.


The Most Important Ideas

The Hacker Playbook 3 does a good job of conceptually distinguishing penetration testing from red teaming. At the risk of bastardizing the author’s point my summary is that pentesters are trying to prove a break-in is possible whereas a red team is measuring or testing an organization’s defensive personnel and processes in a realistic way.

This book also rightly emphasizes the imperative for red teamers to read APT reports. If the goal of a red team is to emulate realistic threats, then they have to learn how real-world attackers are changing their TTPs. If you’re not fully emulating real threat actors (because you don’t know what they’re doing and how they’re doing it) then you aren’t maximizing realism in your engagements, and in turn your client’s defensive operations won’t be adequately measured.


Setup, Gotchas, etc.

First and foremost, the author maintains a GitHub repository for updates and corrections to the book. There he also links to extra tools and articles recommended by readers. THP also makes use of a purpose-built virtual machine (THP-VM) that ships with practically everything you need to follow along. It requires nearly 7 GB of storage, so I suggest finding enough disk space for it and start downloading it before you need it use it. The URL is at the end of page 22.

Depending on your personal learning objectives it could be worth your time to set up a virtual lab environment to attack and practice against. Chapter 4 describes how to build a Windows Active Directory network (domain controller, client VMs, users/groups, GPO, etc.) for this type of offensive tool testing. Generally, the author advises creating as realistic of a testing simulation as possible (complete with VLANs, antivirus, services like Jenkins, etc.) but I think, again, it’s wise to only go as far as your list of subjects to learn warrants. Don’t get sidetracked and busy yourself with setup and sysadmin tasks at the expense of your infosec studies. Being judicious with your focus is best. You can always return to your lab and add more to it after you’ve achieved your current goals.


Write Great Code

Volume 1


Write Great Code, Volume 1


Description & Review

Write Great Code, Volume 1 was written by Randall Hyde and published by No Starch Press almost 15 years ago in November 2004. Although this is fairly old it’s incredibly relevant for programmers regardless of which language they employ. The subtitle of this book is Understanding the Machine which is fitting since the main topic is machine organization. Through 13 chapters Write Great Code guides the reader to do just that by teaching subjects like data representation (numeric, character, composite), operations (arithmetic, logical), memory (organization, access, architecture), CPU architecture, I/O, and more.

Frankly, I think this book should be required reading for new programmers. If you’ve considered learning assembly language programming then Write Great Code is an absolutely essential read well before you learn a single instruction mnemonic. Machine organization is a vitally-important, language-independent field of knowledge that every serious programmer should understand, because every line of code one might write is inextricably part of an execution environment of some kind. After finishing this book, I was able to better appreciate assembly language concepts that I had only memorized in the past as well as integrate new programming techniques into my skill set more readily.


Recommendations

I won’t lie. There were some heavy, technical parts in this book that seemed to drag on in the name of completeness. It’s probably okay for you to skim through sections here and there insofar as you don’t betray your specific learning goals. Identifying which aspects of machine organization are relevant to your individualized objectives shouldn’t be challenging, and it’s completely normal and okay if not every concept is equally valuable to you. Spend your limited time (and your capacity for focused learning) as wisely as you can.


The Most Important Ideas

Write Great Code showcases so many significant details on how computers work and how programmers can optimize the code they write to elegantly and harmoniously function within the limits and designs of those computers. The best way I can capture the big picture from this book is to list what I personally think are the 10 most noteworthy concepts:

  1. Great code uses resources efficiently, is easy to read/modify, is well tested/documented, and has a consistent style.

  2. Binary numbers have properties that make binary representation highly efficient for arithmetic/logical operations.

  3. Modern CPUs utilize two’s complement representation/operations for working with signed integers.

  4. Floating-point values (and arithmetic operations involving them) will always be subject to inaccuracy.

  5. Memory is slow, and caching (specifically, multi-level caching) provides an absolutely necessary performance benefit.

  6. Any electronic circuit can be constructed from Boolean functions implemented exclusively in NAND operations.

  7. CPU pipelining is a major aspect of consistent and efficient computational performance.

  8. Operating system API calls are slow, so languages implement their own heap management to avoid relying on the OS.

  9. Heap fragmentation is a non-trivial problem, and designing good, general-purpose heap managers is incredibly hard.

  10. Using large block sizes for each disk operation is much more efficient than using multiple, smaller blocks.


Setup, Gotchas, etc.

Personally, I read Write Great Code to learn concepts about the inner workings and designs of computers. That doesn’t mean there aren’t plenty of coding examples throughout the book, but generally, the concepts are explained well enough that I didn’t see much value in pumping the brakes to re-implement the code in a hands-on way. My focus was to maximize my understanding of the ideas presented and not necessary to practice coding. I might advise the average reader to do the same, but if you find yourself doubting your grasp of a certain concept, then it’s probably a good sign to dig deeper. Doing so may or may not necessitate you writing and testing code.


Gray Hat Python


Gray Hat Python


Description & Review

Gray Hat Python by Justin Seitz demonstrates process debugging, fuzzing, code and library injection, and more in twelve detail-packed chapters. This book was published in 2009 (more than 10 years ago now) and it shows quite a bit. Fortunately, many of the concepts and techniques presented are still relevant and applicable today. If you’re interested in how debuggers work and what you can accomplish with one then this book is for you.


Recommendations

If you want exposure to debugging via Python (with an emphasis on the Windows API) then this book won’t disappoint you. Since Gray Hat Python is so old, though, a few of the lab exercises require more effort to get off the ground. Attempting to complete every single hands-on challenge might frustrate you while confronting software dependencies and tracking down very old versions of the programs the book demonstrates. But if you’re okay with that, or if you’re more focused on advancing your conceptual understanding than hands-on practice then you’ll enjoy Gray Hat Python all the same.


The Most Important Ideas

Interestingly, the most valuable knowledge I gained from this book pertained to Windows API functions. More than 20 API functions relating to processes, threads, memory, and debugging were covered in depth with many concentrated in the third chapter titled Building a Windows Debugger. I think these functions, and the Windows API in general, are a fantastic aspect of Windows for a hacker or security engineer to master.


Setup, Gotchas, etc.

Start by downloading the code files from the No Starch Press website. Gray Hat Python recommends using CentOS 5 or Fedora Core 7. Since it’s 2019, I ended up installed CentOS 6.1 in a VM, and it worked perfectly fine. The book also relies on a 32-bit instance of Windows for the exercises to work properly. I used a 32-bit Windows 7 VM without a hitch.

On the CentOS VM, I had to install gcc via yum to compile some of the source code provided. I also discovered that there are no easily downloadable 32-bit versions of Eclipse, PyCharm, etc. so I ended up installing Notepad++. In the sixth chapter I started to run into more software problems relating to pydbg and multiple versions of python. I ultimately decided to skip a number of the labs in the interest of time, since tracking down really old versions of software and then troubleshooting dependency nightmares wasn’t too productive.


Think Like a Programmer


Think Like a Programmer


Description & Review

The full title of this book is Think Like a Programmer: An Introduction to Creative Problem Solving, and it was written by V. Anton Spraul and published close to seven years ago in 2012. It’s all about learning to solve problems through code as a discipline. It doesn’t just teach programming syntax or technical trivia. By way of numerous C++ examples across eight chapters Think Like a Programmer demonstrates how to cognitively approach real-world challenges with procedural and object-oriented programming methods and not just the answers to a series of contrived, arbitrary tasks.

I found this book both inspirational and directly helpful in my ongoing efforts to level-up my own coding skills. The author pays attention to the human element of coding (frustration can get in the way of critical thinking) and the reality that every individual has certain cognitive strengths and weaknesses that impact one’s code quality. The most valuable aspect of this book is that it teaches the reader to identify which programming concepts (arrays, linked lists, classes, recursion, etc.) best apply as possible solutions to different kinds of problems.


Recommendations

Think Like a Programmer is a good read for even a novice coder. Having a rudimentary grasp of the C++ syntax is necessary so you can read the examples and follow along. The author strongly recommends getting hands-on and implementing the solutions in code yourself, so to get the most from this book you should also be able to write basic statements in C++ as well. Be sure to budget enough time to read the chapters and write some code.


The Most Important Ideas

Here are the most interesting ideas and advice from this book that stuck with me:

  1. Study programming languages BEFORE you actually need to use them.

  2. Avoid trying to learn programming by only modifying other people’s code.

  3. When reading code focus on WHY the programmer made a certain design choice over another.

  4. A training course can only ever be a catalyst for learning, and it shouldn’t be thought of as the learning itself.

  5. Necessity is the mother of invention. Identify a program you need and go build it.


Setup, Gotchas, etc.

The setup for this book is straightforward. Utilize a simple C++ development environment that’s conducive to very basic exercises. There’s no benefit in making it complicated. A text editor and gcc are enough for this book.


Black Hat Python


Black Hat Python


Description & Review

Black Hat Python, subtitled Python Programming for Hackers and Pentesters, is an eleven-chapter, offensive coding book written by Justin Seitz and published almost five years ago in 2014. It explores topics such as network sockets, traffic sniffing, web hacking, command and control, post-exploitation, privilege escalation, and more.

I enjoyed this book, and I found the lab exercises quite approachable. Even though the book is somewhat aged now (that says more on the pace of technology advancement than anything) and, therefore, some of the techniques aren’t cutting-edge anymore, the book still demonstrates practical offensive tactics in relevant and interesting subject areas such as sandbox detection, man-in-the-browser (MitB) attacks, automation with COM, process injection, “offensive forensics”, and others.


Recommendations

At a high level, Black Hat Python seems to break down into three parts: network, web, and post-exploitation. If any of those topics is on your personal list of interesting subjects then you won’t regret taking the time to read this book. Like I advise with other books it’s best to focus your energy on lab exercises that correspond to the specific subjects you’re most determined to learn. Completing every hands-on lab feels nice, but by no means is it a hard requirement to still get enough value from Black Hat Python.


The Most Important Ideas

I can’t say this was a deliberate point the book was trying to make, but something that I took away from Black Hat Python is that there’s a monstrous quantity of existing code out there that can aid you in quickly completing offensive tasks in Python. Sometimes this simply means learning and using a general-purpose library, like urllib. But a hugely valuable idea this book demonstrated, even if indirectly, is that you can likely find existing implementations of functions, API calls, structure definitions, and more by merely searching by name for their usage in public code repositories on sites like GitHub.


Setup, Gotchas, etc.

Black Hat Python calls for three VMs: Kali Linux, 32-bit Windows 7, and 32-bit Windows XP. I set them all up, ensuring that both Windows VMs were indeed 32-bit instances, and I didn’t have any problems. It appears the book uses Kali 1.0.9, but I tried a 64-bit Kali VM (2019.2 build) without noticing any differences. Unlike other books, this one utilizes Python 2.7 consistently, so you likely won’t get caught up in dependency hell.

Wing Python IDE is the star of the show for much of the book. I had never played with it before Black Hat Python, so one thing that confused me was the Debug Probe window. It wasn’t easy to find, and it turns out it was renamed Debug Console. Furthermore, it’s only included in the Pro version, so download the Pro trial to follow along with the labs.

Lastly, a handful of the code samples have relatively small issues due to age. With guidance from Stack Overflow I was able to discern which changes needed to be made (e.g. replacing c_ulong with c_uint32) to get everything to work. It was worth putting in a few minutes to find the fix to get the most from the exercises.


Learn and Master C Programming


Learn and Master C Programming


Description & Review

Okay, I lied. Technically, this one isn’t a book (it’s a video series), but it is a magnificent resource for learning C programming. This title, Learn and Master C Programming For Absolute Beginners, is a 2017 Packt Publishing offering by Mohammad El-Haj, and it contains nearly 14 hours of instruction. On top of teaching the C syntax and the general C build process (preprocessing, compiling, linking, etc.) this series also demonstrates using Microsoft Visual Studio 2015 to develop C console applications on Windows.

Finding a modern, approachable course on C programming (not C++) in 2019 isn’t as easy as you might think, but a series that also gently introduces you to Visual Studio along the way is as elusive and beautiful as a goddam unicorn. The chapters on pointers, preprocessor directives, header files, and dynamic memory were particularly valuable. Kudos to Mr. El-Haj for this great programming course.


Recommendations

I already learned C++ years ago in college, but I still regard this course as one of the best uses of my time so far this year. If you want to read or write C programs and you don’t already do so professionally, then I highly recommend this video series. Moreover, if you’re an infosec professional you likely work with Windows systems, so learning Visual Studio to develop and test programs on Windows will be valuable for both offensive (custom pentest tooling) and defensive (analyzing malware source code) purposes. Seriously give this course your consideration. I was able to complete it in three weeks, give or take, by attempting one chapter a day.


The Most Important Ideas

Aside from the fact that Visual Studio is so powerful and useful, there’s no single, main idea with which this course left me. Instead, there are four major concepts that I found either eye-opening or otherwise difficult to learn from other resources. Here they are:

  1. Working with memory and pointers doesn’t have to be scary. It isn’t too complex for mere mortals to fully understand.

  2. The C preprocessor is vital, but misusing it can eventually turn your source into an overly complicated mess.

  3. Separating a C program into multiple source files (and using header files) helps both collaboration and compilation.

  4. C code isn’t always compatible with C++ code, but integrating the two (via extern statements) is often possible.


Setup, Gotchas, etc.

This awesome video series teaches students C programming with Visual Studio Community 2015 Update 3. At the time of this writing, this program is available (in the US anyway) free of charge through Microsoft. Chapter 3 will guide you to install specific packages and features for everything to work like it does in the instructor’s videos. But be aware that Visual Studio, as relied upon in this course, requires dozens of gigabytes of storage space to fully install all the dependencies. I created a 60GB Windows 10 VM, and that ended up being enough space. The download and installation steps took more than an hour for me, though, so I encourage snapshotting your VM after the install completes.


Intro to 80x86 Assembly


Intro to 80x86 Assembly


Description & Review

The full title of this book is Introduction to 80x86 Assembly Language and Computer Architecture, 3rd Edition. It was written by Richard C. Detmer and published more than five years ago in early 2014. This volume covers a lot of ground throughout nine chapters of deep, technical detail such as assembly instructions, control flow, bit manipulation, string and floating point operations, and more.

What I really respect about this title is that it actually teaches real assembly for the 80x86 architecture instead of being overly concerned with bridging the gap between high-level languages and the machine by means of an artificial, author-contrived middle-of-the-road language. This book instructs the reader on how to write code for real-world CPUs. Additionally, it demonstrates various aspects of assembly programming with practical examples with included code samples. Lastly, it doesn’t avoid teaching 64-bit operations either, so I felt like this book truly set me up for success with writing programs in assembly language for realistic use cases.


Recommendations

With all that glowing praise on how the book goes into so much technical detail comes the burden for the prospective reader to have a handle on machine organization and the basics of C programming or similar. For example, I only attempted to read this title after finishing many of the other books described in this post. If programming isn’t part of your day job, then you’ll likely benefit from bootstrapping on those subjects before this one.


The Most Important Ideas

This book simply teaches a large set of details about 80x86, assembly programming, and computer architecture. The summary sections at the end of each chapter are great recaps, though.

In my opinion, the most important skill this book teaches, aside from the actual code-writing itself, is how to debug assembly programs with Visual Studio. Beyond that, I really enjoyed how the author described how one can optimize his or her code either in terms of speed (e.g. reducing the number of instructions required) or size (e.g. using the accumulator register to reduce the resulting opcode’s byte count). I imagine the latter could benefit one in writing space-efficient shellcode or similar.


Setup, Gotchas, etc.

Code samples from the book are provided via the publisher’s website. The URL is listed in the Preface section before Chapter 1. This Book demonstrates examples with Visual Studio 2012, but I didn’t have any problems with the labs while using the 2015 version.


Onward


Although they aren’t all equally potent or valuable I can sincerely recommend any of these books to someone interested in infosec with a appetite for coding like myself. The last few months have been absolutely chaotic with work, but I’m glad that I put in the time and committed to finishing these learning resources. Hell, if I maintain my current pacing I very well could complete another ten books before the year ends!

Did I get something wrong, or do you think I left some crucial detail out of my reviews or general reading approach? Are there alternative titles you can recommend on the same subjects? Don’t hesitate to let me know what you think. Feedback is always encouraged. Thanks for reading!




Mike Iacovacci
Mike Iacovacci is an information security professional specializing in endpoint security, intrusion investigation, and security research. His efforts have prevented serious security incidents and continue to disrupt cybercrime operations and sophisticated threat actors.

FOR FUTURE POSTS AND UPDATES FOLLOW @mikeiacovacci