Log In
Or create an account ->
Imperial Library
Home
About
News
Upload
Forum
Help
Login/SignUp
Index
Cover Page
Title Page
Copyright Page
About the Authors
BRIEF CONTENTS
CONTENTS IN DETAIL
FOREWORD
ACKNOWLEDGMENTS
INTRODUCTION
Who This Book Is For
What This Book Isn’t
Why Use Go for Hacking?
Why You Might Not Love Go
Chapter Overview
1 GO FUNDAMENTALS
Setting Up a Development Environment
Understanding Go Syntax
Summary
2 TCP, SCANNERS, AND PROXIES
Understanding the TCP Handshake
Bypassing Firewalls with Port Forwarding
Writing a TCP Scanner
Building a TCP Proxy
Summary
3 HTTP CLIENTS AND REMOTE INTERACTION WITH TOOLS
HTTP Fundamentals with Go
Building an HTTP Client That Interacts with Shodan
Interacting with Metasploit
Parsing Document Metadata with Bing Scraping
Summary
4 HTTP SERVERS, ROUTING, AND MIDDLEWARE
HTTP Server Basics
Credential Harvesting
Keylogging with the WebSocket API
Multiplexing Command-and-Control
Summary
5 EXPLOITING DNS
Writing DNS Clients
Writing DNS Servers
Summary
6 INTERACTING WITH SMB AND NTLM
The SMB Package
Understanding SMB
Guessing Passwords with SMB
Reusing Passwords with the Pass-the-Hash Technique
Recovering NTLM Passwords
Summary
7 ABUSING DATABASES AND FILESYSTEMS
Setting Up Databases with Docker
Connecting and Querying Databases in Go
Building a Database Miner
Pillaging a Filesystem
Summary
8 RAW PACKET PROCESSING
Setting Up Your Environment
Identifying Devices by Using the pcap Subpackage
Live Capturing and Filtering Results
Sniffing and Displaying Cleartext User Credentials
Port Scanning Through SYN-flood Protections
Summary
9 WRITING AND PORTING EXPLOIT CODE
Creating a Fuzzer
Porting Exploits to Go
Creating Shellcode in Go
Summary
10 GO PLUGINS AND EXTENDABLE TOOLS
Using Go’s Native Plug-in System
Building Plug-ins in Lua
Summary
11 IMPLEMENTING AND ATTACKING CRYPTOGRAPHY
Reviewing Basic Cryptography Concepts
Understanding the Standard Crypto Library
Exploring Hashing
Authenticating Messages
Encrypting Data
Brute-Forcing RC2
Summary
12 WINDOWS SYSTEM INTERACTION AND ANALYSIS
The Windows API’s OpenProcess() Function
The unsafe.Pointer and uintptr Types
Performing Process Injection with the syscall Package
The Portable Executable File
Using C with Go
Summary
13 HIDING DATA WITH STEGANOGRAPHY
Exploring the PNG Format
Reading Image Byte Data
Writing Image Byte Data to Implant a Payload
Encoding and Decoding Image Byte Data by Using XOR
Summary
Additional Exercises
14 BUILDING A COMMAND-AND-CONTROL RAT
Getting Started
Defining and Building the gRPC API
Creating the Server
Creating the Client Implant
Building the Admin Component
Running the RAT
Improving the RAT
Summary
Index
← Prev
Back
Next →
← Prev
Back
Next →