O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Raspberry Pi for Secret Agents - Second Edition

Book Description

Turn your Raspberry Pi into your very own secret agent toolbox with this set of exciting projects

In Detail

The book starts out with the initial setup of your Raspberry Pi, guides you through a number of pranks and secret agent techniques, and then shows you how to apply what you've learned out in the real world.

Learn how to configure your operating system for maximum mischief and start exploring audio, video, or Wi-Fi techniques. You will learn how to record, listen, or talk to people from a distance and how to set up your own phone network. Then, plug in your webcam and set up a motion detector with an alarm or find out what the other computers on your Wi-Fi network are up to. Once you've mastered the techniques, combine them with a battery pack and GPS for the ultimate off-road spy kit.

Raspberry Pi for Secret Agents, Second Edition has everything you need to turn your Raspberry Pi into an information-gathering powerhouse. Use the practical spy and pranking techniques to amuse yourself or your friends.

What You Will Learn

  • Install and configure the Raspbian OS for maximum mischief
  • Run your own private phone network
  • Detect an intruder with motion detection and set off an alarm
  • Distort your voice in weird and wonderful ways
  • Push unexpected images into browser windows
  • Track the Pi's whereabouts using GPS
  • Control the Pi with your smartphone

Downloading the example code for this book. You can download the example code files for all Packt books you have purchased from your account at http://www.PacktPub.com. If you purchased this book elsewhere, you can visit http://www.PacktPub.com/support and register to have the files e-mailed directly to you.

Table of Contents

  1. Raspberry Pi for Secret Agents Second Edition
    1. Table of Contents
    2. Raspberry Pi for Secret Agents Second Edition
    3. Credits
    4. About the Author
    5. About the Reviewers
    6. www.PacktPub.com
      1. Support files, eBooks, discount offers, and more
        1. Why subscribe?
        2. Free access for Packt account holders
    7. Preface
      1. What this book covers
      2. What you need for this book
      3. Who this book is for
      4. Conventions
      5. Reader feedback
      6. Customer support
        1. Errata
        2. Piracy
        3. Questions
    8. 1. Getting Up to No Good
      1. A brief history lesson on the Pi
      2. The ins and outs of the Raspberry Pi
        1. GPIO headers
        2. The RCA video jack
        3. The Audio jack
        4. Status LEDs
        5. USB
        6. The Ethernet network
        7. The CSI Camera connector
        8. HDMI
        9. Power
        10. SD card
      3. Installing the Raspbian OS on the SD card
        1. Getting NOOBS
        2. Formatting the SD card
        3. Starting NOOBS
      4. Booting up and configuring Raspbian
        1. Basic commands to explore your Pi
        2. Getting help with commands
      5. Accessing the Pi over the network using SSH
        1. Wired network setup
        2. Wi-Fi network setup
        3. Connecting to the Pi from Windows
        4. Connecting to the Pi from Mac OS X or Linux
      6. The importance of a sneaky headless setup
      7. Keeping your system up-to-date
      8. Backing up your SD card
        1. Complete SD card backup in Windows
        2. Complete SD card backup in MAC OS X
        3. Complete SD card backup in Linux
      9. Summary
    9. 2. Audio Antics
      1. Configuring your audio gadgets
        1. Introducing the ALSA sound system
        2. Controlling the volume
        3. Switching between HDMI and analog audio output
        4. Testing the speakers
        5. Preparing to record
        6. Testing the microphone
        7. Clipping, feedback distortion, and improving sound quality
      2. Recording conversations for later retrieval
        1. Writing to a WAV file
        2. Writing to an MP3 or OGG file
        3. Creating command shortcuts with aliases
        4. Keep your recordings running safely with tmux
      3. Listening in on conversations from a distance
        1. Listening in Windows
        2. Listening in Mac OS X or Linux
      4. Talking to people from a distance
        1. Talking in Windows
        2. Talking in Mac OS X or Linux
      5. Distorting your voice in weird and wonderful ways
        1. Make your computer do the talking
      6. Scheduling your audio actions
        1. Start on power up
        2. Scheduled start
        3. Controlling recording length
        4. Start recording with noise detection
      7. Calling your fellow agents
        1. Setting up SIP Witch
        2. Connecting the softphones
          1. Windows (MicroSIP)
          2. Mac OS X (Telephone)
          3. Linux (SFLphone)
          4. Android (CSipSimple)
          5. iPhone/iPad (Linphone)
        3. Running a softphone on the Pi
          1. Encrypting SIP Witch passwords
          2. Setting up Linphone
          3. Playing files with Linphone
      8. Bonus one line sampler
      9. Summary
    10. 3. Webcam and Video Wizardry
      1. Setting up your camera
        1. Meet the USB Video Class drivers and Video4Linux
        2. Knowing your camera module
        3. Knowing your USB webcam
          1. Finding out your webcam's capabilities
      2. Capturing your target on film
        1. Viewing your camera in VLC media player
          1. Viewing in Windows
          2. Viewing in Mac OS X
          3. Viewing in Linux
        2. Recording the video stream
          1. Recording in Windows
          2. Recording in Mac OS X
          3. Recording in Linux
      3. Detecting an intruder and setting off an alarm
        1. Creating an initial Motion configuration
        2. Trying out Motion
        3. Collecting the evidence
        4. Viewing the evidence
        5. Hooking up more cameras
          1. Preparing a webcam stream in Windows
          2. Preparing a webcam stream in Mac OS X
        6. Configuring Motion for multiple input streams
        7. Building a security monitoring wall
      4. Watching your camera over the Internet
      5. Turning your TV on or off using the Pi
      6. Scheduling video recording or staging a playback scare
      7. Summary
    11. 4. Wi-Fi Pranks – Exploring Your Network
      1. Getting an overview of all the computers on your network
        1. Monitoring Wi-Fi airspace with Kismet
          1. Preparing Kismet for launch
          2. First Kismet session
          3. Adding sound and speech
          4. Enabling rouge access point detection
        2. Mapping out your network with Nmap
      2. Finding out what the other computers are up to
        1. How encryption changes the game
        2. Traffic logging
        3. Shoulder surfing in Elinks
      3. Pushing unexpected images to browser windows
      4. Knocking all visitors off your network
      5. Protecting your network against Ettercap
      6. Analyzing packet dumps with Wireshark
        1. Running Wireshark in Windows
        2. Running Wireshark in Mac OS X
          1. Running Wireshark in Linux
      7. Exploring dynamic DNS, port forwarding, and tunneling
        1. Dynamic DNS
          1. Choosing your domain name
          2. Verifying your domain name
          3. Updating your domain name
        2. Port forwarding
          1. Adding the forwarding rule
          2. Verifying your port forwarding
          3. Port forwarding security
          4. Connected at last
        3. Tunneling
          1. Port tunneling in Windows
          2. Port tunneling in Linux or Mac OS X
      8. Creating a diversion using a chat bot
        1. Introducing XMPP
        2. Useful Profanity
          1. Connecting to Facebook chat
          2. Connecting to Google chat
          3. Connecting to XMPP servers
          4. Getting around Profanity
          5. Project AgentBot
          6. Awakening the bot
      9. Keeping your conversations secret with encryption
      10. Summary
    12. 5. Taking Your Pi Off-road
      1. Keeping the Pi dry and running with housing and batteries
      2. Setting up point-to-point networking
        1. Creating a direct wired connection
        2. Static IP assignment in Windows
        3. Static IP assignment in Mac OS X
        4. Static IP assignment in Linux
      3. Creating an ad hoc Wi-Fi network
        1. Connecting to an ad hoc Wi-Fi network in Windows
        2. Connecting to an ad hoc Wi-Fi network in Mac OS X
      4. Turning the Pi into a Wi-Fi hotspot
      5. Tracking the Pi's whereabouts using GPS
        1. Tracking the GPS position on Google Earth
          1. Preparing a GPS beacon on the Pi
          2. Setting up Google Earth
          3. Setting up a GPS waypoint logger
          4. Mapping GPS data from Kismet
        2. Using GPS as a time source
        3. Setting up GPS on boot
      6. Controlling the Pi with your smartphone
        1. Android (Raspi SSH)
        2. iPhone/iPad (SSH Remote)
        3. Common remote control commands
      7. Receiving status updates from the Pi
        1. Tagging tweets with GPS coordinates
        2. Sending e-mail updates
        3. Scheduling regular updates
      8. Accessing your files from anywhere with Dropbox
      9. Keeping your data secret with encryption
      10. Erasing the Pi should it fall into the wrong hands
        1. Encrypting your home with eCryptfs
        2. Rigging the self-destruct mechanism
      11. Summary
      12. Graduation
    13. Index