Home

Awesome

kbd-audio

Actions Status

This is a collection of command-line and GUI tools for capturing and analyzing audio data.

Keytap

The most interesting tool is called keytap - it can guess pressed keyboard keys only by analyzing the audio captured from the computer's microphone.

Check this blog post for more details:

Keytap: description and some random thoughts

Video: short demo of Keytap in action

Try it online:

<a href="https://ggerganov.github.io/keytap" target="_blank"><img src="https://i.imgur.com/FXa60Pr.gif" style="display: inline-block; overflow: hidden; width: 99%;"></img></a>

Keytap2

The keytap2 tool is another interesting tool for recovering text from audio. It does not require training data - instead it uses statistical information about the frequencies of the letters and n-grams in the English language.

A more detailed description of the tool is available here: Keytap2 discussion

Video: short demo of Keytap2 in action

CTF: can you guess the text being typed?

Try it online:

<a href="https://keytap2.ggerganov.com" target="_blank"><img src="https://i.imgur.com/nPlLEDN.jpg" style="display: inline-block; overflow: hidden; width: 99%;"></img></a>

Keytap3

This version introduces significant algorithm improvements and better n-gram statistics compared to keytap2. The attack is now fully automated and does not require any manual intervation during the text recovery process.

Video: short demo of using Keytap3

Video: another example of using Keytap3

GUI for Keytap3

Check if your keyboard is vulnerable to Keytap:

<a href="https://keytap3.ggerganov.com" target="_blank"><img src="https://user-images.githubusercontent.com/1991296/166096331-ab26f7f8-08e0-48d6-abd7-57017ebf1866.JPEG" style="display: inline-block; overflow: hidden; width: 99%;"></img></a>

What people say about Keytap

"This works incredibly well.
I hope you realize what you've created (and made available to every person in the world)."
-- ffpip

"I just tried it and it works incredibly well. It kind of makes me want to stop using a mechanical keyboard." -- Karawebnetwork

"This attack and Van Eck phreaking are why Edward Snowden, while typing passwords and other sensitive information, would pull a blanket over himself and his laptop." -- aarchi

"This is what mechanical keyboard users deserve" -- super guy

"fuck.." -- Lluis Franco

Build instructions

Dependencies:

Linux, FreeBSD, Mac OS, Windows (MSYS2 + MinGW)

git clone https://github.com/ggerganov/kbd-audio
cd kbd-audio
git submodule update --init
mkdir build && cd build
cmake ..
make

Tools

Short summary of the available tools. If the status of the tool is not stable, expect problems and non-optimal results.

NameTypeStatus
recordtextstable
record-fulltextstable
playtextstable
play-fulltextstable
view-guiguistable
view-full-guiguistable
key-detectortextstable
keytaptextstable
keytap-guiguistable
keytap2-guiguistable
keytap3textstable
keytap3-guiguistable
-extra-
guess-qptextexperiment
guess-qp2textexperiment
keytap3-multitextexperiment
scaletextexperiment
subreaktextexperiment
key-average-guiguiexperiment
keytap2textexperiment

Tool details

Feedback

Any feedback about the performance of the tools is highly appreciated. Please drop a comment here.