Ever wished you could play around with all the neat gadgets your favorite spies use (like James Bond or Michael Westen)? With the introduction of the remarkable Raspberry Pi and a few USB accessories, anybody can now join in on the action.
Discover how to turn your Raspberry Pi into a multipurpose secret agent tool! Through a series of fun, easy-to-follow projects you’ll learn how to set up audio/video surveillance, explore your Wi-Fi network, play pranks on your friends, and even learn how to free your Raspberry Pi from the constraints of the wall socket.
Raspberry Pi for Secret Agents 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 the audio, video, and Wi-Fi projects. Learn how to record, listen, or talk to people from a distance and how to distort your voice. You can even 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.
Approach
A playful, informal approach to using the Raspberry Pi for mischief!
Who this book is for
Raspberry Pi for Secret Agents is for all mischievous Raspberry Pi owners who’d like to see their computer transform into a neat spy gadget to be used in a series of practical pranks and projects. No previous skills are required to follow along and if you’re completely new to Linux, you’ll pick up much of the basics for free.
Apart from the Raspberry Pi board itself, a USB microphone and/or a webcam is required for most of the audio/video topics and a Wi-Fi dongle is recommended for the networking examples. A Windows/Mac OS X/Linux computer (or second Raspberry Pi) is also recommended for remote network access.
Review of RaspberryPi for Secret Agents This is a useful cookbook with a “provocative title”. If I were a professional secret agent I hope that I would be using considerably more powerful techniques than those described in this book. However, I suspect that if I was to start experimenting with such techniques I would probably get a visit from those “strange men in grey macs that don't officially exist” and feel that they “know what's best for me - on behalf of whatever the current elite they represent is”. Nonetheless, in an age where “those that know best” feel that they have a “god given right” (literally in some cases I suspect given my impressions of the spectrum of the kind of psychological profiles individuals attracted to the “shady orgranisations” we are alluding to) it is important to develop secure unofficial channels of communication. The argument - “if you have nothing to hide then you have nothing to fear is a very specious one” Think of Eugenics (championed in the US before the second world war ... and a source of inspiration to a whole lot of fascists), think of McCarthyism and the nasty witchunts that characterised it ( and also think of various US politicians who began their careers as McCarthyite “stooges”) ... you get my point.
It is also, at times, important to be able to record in both audio and video format with various individuals and organisation so that they cannot later be “plausibly denied”. Being a “whistleblower” involves often difficult and often painful choices, and being subject to often vindictive and spiteful treatment by the powerful and secretive when some of their more nasty goings on are brought into the glare of public scrutiny.
The RaspberryPi and associated small Linux platforms are a useful starting point for the serious development of “spook proof” communications systems, recording and data transmission systems. Of course it can be argued that the use and deployment of such systems is subversive and illegal. How many of you are aware of the assertion by a senior Microsoft executive that open source developers are commnists and worse [http://www.slate.com/articles/technol...], and, I can envisage scenarious where it most certainly would be. However, I can also envisage scenarios involving “potential conflict with state interests” where it can be argued that it would not be. I am thinking for example of labour disputes in which a right wing government is using the intelligence services to defeat a large scale trade union organised protest. See e.g. https://www.mi5.gov.uk/home/mi5-histo... and also, http://www.guardian.co.uk/uk/2009/oct... Also, and this particularly aposite consider the case of David Snowden [see e.g. http://www.bbc.co.uk/news/world-us-ca...]
So, what practical projects does this book provide for those who wish to use “spook like technology” for their own (let us hope socially useful for context see e.g. http://www.havingtheircake.com/conten...) purposes. Here I am thinking of legitimate trade union activities, protection of human rights and civil liberties, unmasking the corruption of the “good and the great” especially bankers and politicians. The sections on audio and video are a good starting point. The audio section illustrates some useful applications of audio including voice distortion (albeit simplistic), but does not cover such techniques as e.g voice encryption that will produce audio like signals that can be used in conjunction with mobile phones. The chapter on webcam and video wizardy is also a useful starting point and can form the starting point for many useful projects, not only “spookish ones” e.g. in monitoring of e.g. bird and animal behaviour as part of a school or University project.
The section on monitoring of WiFi networks and the use of the Wireshark protocol analyser, once again should be thought of as a “starter for 10” , to be followed up by more extensive reading and research. I felt that the use of the word “pranks” in the title was unwise, implying as it does that “snooping” around in your current local “WiFi” neighbourhood is just some kind of “light hearted jape” ... Personally I would have preferred a title along the lines of e.g. “exploring and monitoring WiFi” networks and systems. I have not use Ettercap before and must therefore thank the author for making me aware of it and its various uses. The Wireshark section was little more than a brief overview and I would hope that it will serve to inspire those who have not used Wireshark “in anger” to “dig deeper”
The final chapter had some intriguing topics ... but was disappointingly brief. The section on AdHoc networks ( a topic that I find of great interest and have looked into fairly extensively and even given the odd course and presentation on) was extremely brief. The section on GPS was useful and I enjoyed the section on using communications between a smartphone (Android in the example used in the book) and a RaspberryPi. The final part on data encryption barely scratched the surface.
So there you have it. A useful book for the curious and inventive, especially reasonably bright teenagers with a technical disposition. Not much use for spies though. However, you never know. When I read my copy of “Spycatcher” in the days when “they were trying to ban its publication” what surprised me was the apparent “sheer technological incompetence” of the “spying fraternity”. Maybe this book might be of use to them ... though I suspect they are probably better resourced and technically competent these days. Would it be possible to use this book as a jumping of point for developing applications to “outspook the spooks”. Definitiely yes ... though do be careful and do be discreet. Play safe and conduct small “private” experiments with close and trusted friends. Also do check out the law in your part of the world as regards the use of advanced encryption technologies and the monitoring of radio communications. Also remember when sending “secret data” its not the volume but the quality. Indulge in thought experiments concerning the creation of “secret communications channels”. Once when teaching an embedded Linux kernel and device driver programming course to a group of “technical communications specialists” one of the exercises involved “hacking a keyboard driver” Much to my amusement one of the class hacked into a colleague's computer and had that person's keyboard LEDs “flashing morse code”. I am sure that given a bit more time he could have had the keyboard LEDs “flashing encrypted morse code”, and with multiple LEDs could even have devised multiple channel communication. Now there's a little challenge - not too easy, not too difficult ... Let me know how you get on ... Oh, and by the way .. you could adapt it to send morse from a RaspberryPi to a mobile phone and then “further afield” .... I think you get the picture.
Also, there are many interesting add on boards for the RaspberryPi that can serve as starting points for devising some of your own. How about a board with some interesting encryption or image processing software programmed into an FPGA device ?
Good luck and happy reading. Take care and be sensible and socially responsible.
Raspberry Pi for Secret Agents. Trendy title. While I wondered how serious it could be, the author's name got my attention - Stefan Sjogelid. Now that is already promising. This is the guy behind the idea, that if you're eager enough, you can build your own Linux distribution targeted at the Raspberry Pi architecture. The whole process is thoroughly described on his dedicated web site. And expectations slowly started to rise.
Now with this book we're in for a treat. At least we don't get the usual starter point of view, and get some trickery instead. The book is very educating on an operating system level. Reading it, I was able to fill some large gaps in my modest but constantly expanding Linux knowledge. Once the reader starts, it quickly becomes clear that the installments built up are simple enough, yet powerful and effective. And I wouldn't be surprised if such tools are employed in a real-life espionage activities.
The layout of the book is presented to be dead simple. Its significance is another story :) After the mandatory introduction of the Raspberry Pi's basics (in terms of hardware and OS) to the reader in the first chapter, the actual contents related to the main topic begin from the second one. The four sub-topics of the book are respectively: Audio, Video, WiFi and Portable Pi. The simplicity is only on the surface.
Concerning the audio tasks, at first I had a difficulty to set-up a microphone due to my profanity. Without giving the proper attention to all of the Pi's interfaces I was (wrongfully) thinking that the audio output connector can deliver also an input. After a few lessons learned and a correct setup I was ready to meet some handy tools. Most of the chapter is dedicated to the SoX tool - the working horse of the audio mechanics. Combined with the rest of the tools (some of which are built-in Linux commands) and through the secure shell a lot of possible "spy techniques" are given. Those tools include tmux, espeak and at commands. They're for running SoX independently of the user's session, for speech and task-in-time automation respectively. Apart from the auxiliary elements the main idea is to be shown how the ALSA sound system is employed in the Raspberry Pi, and how easily it can be used for various projects.
Regarding the video tasks, maybe the book was written and released a bit too early, because two weeks ago the guys behind the Raspberry Pi released its own camera, plugged into the dedicated CSI connector. I guess that if written today, this chapter would look a bit different. At least it could include additional information about the Pi camera and its dedicated software tools and capabilities. Well without that info the chapter is comprised of two main projects - video streaming with recording the stream and detection of moving objects. For the purpose of the first task the tools related to the framework around the UVC and V4L drivers are used in order to generate a MJPG video stream. The stream then can be accessed on the network by the VLC media player and if necessary recorded by it (without sound of course). And for the purpose of the second task the very powerful Motion software is shown to easily gather input from even more than one camera.
The chapter about the WiFi networking can make a very nice addition to another of the PACKT's books, which I reviewed recently - Networking with Raspberry Pi by Rick Golden. Here the tool of the trade is the detection system Kismet. For it to work not only configuration but also building from source is required. And to be preserved consistency between the projects (and between the chapters of the book of course) it is shown a collaboration with SoX for the purpose of attaching sound signals to its processing events. Further a network mapping is done with Nmap, which leads to the logical next step - to dive into the common (or not so common) network security techniques for attack and/or monitoring with programs like Ettercap and Wireshark.
In the last chapter the Raspberry Pi had to prepare its back-pack, for it was going on a field trip. Regarding the mandatory warnings for battery life, secure and low profile package and most importantly - avoiding any moisture, the portable computer can pretty quickly step outside. Setting up an ad hoc WiFi network is not difficult following the instructions in this (and partly in the previous) chapter. Two of the most interesting projects in the book (which I unfortunately haven't tested yet for some reasons) are the GPS tracking of the Pi in Google Earth, and remote controlling it from a smart-phone while tweeting its current status to the social media. Merely reading through them, they seemed to comprise a powerful, portable setup and just whet one's appetite for some future projects.
The book aims to teach us how to employ the Raspberry Pi in a set up that is robust, automated and portable. All of these are actually achieved thanks to the software tools built-in or separately added to the Linux operating system. In that sense this could be regarded as the only (although not real) drawback of the book. The small computer is there, but still in the background. Everything described can be done on a regular Linux system's shell. No wires, no soldering, no bread-boards, no hardware projects. Yet the Pi is most suitable and prepared for taking these actions to the field and in real life situations. So the existing hardware is enough to become the real spy and the book just gives the vision on how prepared it is to do the job.
In conclusion I can say that this book very easily achieves the goal of being funny, informative and deep at the same time.
Raspberry Pi for Secret Agents is a great book. Concise instructions on real world situations. You'll enjoy every page of it.
I won't list all the details as you can find them in the TOC. All sections in the book explain how to do the experiments it in Mac, Linux and Windows.
After the intro on how to set up the device with a touch of history comes the real thing.
First on Audio: Recording, listening, distortion, voice generation, broadcasting, scheduling the actions. A lot of real world situations to learn the how-to behind them.
Then comes webcam and video wizardry: first check camera possibilities, then capturing the images and showing them using the web server included. Also recording of the video stream. Then comes the "spy" content... Detecting an intruder and setting off an alarm! But why limit to one camera... How to hook more cameras and a security monitoring videowall showing all the streams. After that, turning a TV on and OFF using HDMI or scheduling video recording. Plenty of fun!
After that the so called "Wi-Fi Pranks" gets a little more technical covering network exploration and mapping, wi-fi airspace monitoring, pushing unexpected images into other computer browser windows, using the RasPi as a firewall and analyzing packet dumps.
Then the last part covers how to make your RasPi really portable, autonomous and headless using a battery, a case and wi-fi, bluetooth and GPS USB modules. Setting a point-to-point network between the RasPi and your computer or controlling it with your mobile device using SSH, wi-fi and an app. Or making the RasPi tweet or PM to your profile even with GPS coordinates. After that comes encryption to the game!
Again, I think you'll enjoy every single page. I did! :)
Other than the "secret agent" goofiness (OK I admit it, it *was* kind of fun) Raspberry Pi for Secret Agents offers quite a bit of information on configuring peripherals on your Raspberry Pi, performing essential linux system maintenance, and giving you some ideas on how you can use your RPi to capture and/or control the world around you. It was a good read and the information, while maybe a bit lacking in detail at times, was well presented. Bottom line is that if you want to learn how to make more use of audio and video on the Raspberry Pi, or get started with the details of networking in general, this book may be of some help.
A great book for beginners on the Raspberry Pi. It covers the basics you will need in the operation of Linux and covers the tricks step by step which helps a lot in understanding.. The explanation of the various packages of Linux and their usage for various tasks helps keep working in Linux for a beginner easy. Overall a great book with amazing content. If you want to start your work on the Pi, this book better be by your side..
This book was a lot of fun, and educational to boot. I strongly urge anyone with a raspberry pi to pick up a copy of this book and have a look. It's also an excellent read for anyone with a linux machine of any sort, as some of the information in the book applies equally to any debian based system, and to a lesser degree, any unix system. It starts out simply, and builds on these concepts to move to progressively complex and interesting projects. It is all presented in a humorous manner which holds the reader's interest, especially if the reader follows along on their own pi.
The book is very interesting and useful even if you are not a linux and embedded system's expert. The topic are described in a very appealing manner, but this book is useful also if you don't want to be a 007 but if you need to work with audio and video on your raspeberry Pi. The book could also be used as a reference if you are a raspeberry pi dummy and you want learn and understand how to play with this fantastic piece of hardware.