Pages: [1]
Author Topic: keytweeter  (Read 4602 times)
kylemcdonald
View admin
Brooklyn

Posts: 1164

Gravatar


WWW
keytweeter
« on: June 30, 2009, 07:03:25 PM »

I wrote a keylogger that tweets every 140 characters I type http://twitter.com/keytweeter



I know this is more conceptual than the usual ofw-interactive-installation-stuff, but still -- it wouldn't have been possible without ofw :)

I used:

- ofxXmlSettings to store some information like username, password, and filtered words (passwords, credit card numbers, ssn) that I consider "control" rather than "information".

- ofxThread to do the posting and keylogging asynchronously, so keys aren't lost when posts are being made.

- Some code I posted at http://forum.openframeworks.cc/index.php/topic,1244.0.html for handling window hiding (I use the Home and End keys to show and hide the debug console)

- ofEvents were used for the keylogger's callbacks. e.g.:

Code:
ofAddListener(logger.keyPressed, this, &AutoTweet::keyPressed);

See ofxKeyLogger for my windows-specific keylogger implementation. I know Arturo has some linux specific code and zach has some osx specific code -- both from oflab -- for doing keylogging. I tried to write ofxKeyLogger so that it could be extended for other OSes.

- I used the cURL binary and system() to invoke it. http://curl.haxx.se/

The biggest pain was getting some unicode sent to Twitter correctly to represent the arrow and return keys. I could represent the unicode in a string using \u escape sequences, but it would store it in multiple bytes -- so the character count was off. wstring correctly reported the size() of the buffer, but didn't like being sent to _wsystem. In the end I wrote a wrapper called ofxString that let me store ints instead of characters, with the ints corresponding to the OF_KEY mappings.

If you'd like to run the app yourself, just add a bin/data/config.xml that looks like this:

Code:
<username>twitterUsername</username>
<password>twitterPassword</password>
<safe>somePassword</safe>
<safe>creditCardNumber</safe>
<safe>SSN</safe>

And be sure to add the cURL binary to /bin or your system path.

* keytweeter.zip (5.62 KB - downloaded 735 times.)
Logged

theo
Administrator
Amsterdam

Posts: 1090

Gravatar


WWW
Re: keytweeter
« Reply #1 on: June 30, 2009, 08:00:33 PM »

awesome!
I could see a lot of evil and very fun uses for an ofxKeyLogger addon :D

Theo
Logged

kylemcdonald
View admin
Brooklyn

Posts: 1164

Gravatar


WWW
Re: keytweeter
« Reply #2 on: June 30, 2009, 08:16:11 PM »

Yeah! You could totally do whole-machine tourettes :)

The tourettes thing is nice because it's kind of a diy/try it yourself sort of thing, while this is more "check this out -- it's fun conceptual-hacking-art". I'd like to try some more fffffatish stuff, but this is the first thing that came to mind.
Logged

kylemcdonald
View admin
Brooklyn

Posts: 1164

Gravatar


WWW
Re: keytweeter
« Reply #3 on: July 01, 2009, 09:09:17 PM »

Score #3 for ofw + hackaday! http://hackaday.com/2009/07/01/twittering-keylogger/

Also, I posted the binaries w/ a readme if you'd like to play with it. http://kylemcdonald.net/keytweeter/keytweeter.zip
Logged

julapy
sydney

Posts: 375

Gravatar


WWW
Re: keytweeter
« Reply #4 on: July 02, 2009, 08:25:11 AM »

hehe just trying wank out damn the tourretes honkey machine... pretty funny!
Logged

Pierre Proske
Melbourne, Australia

Posts: 829

Gravatar


WWW
Re: keytweeter
« Reply #5 on: July 15, 2009, 05:09:45 PM »

Cool!

There's already a reference in this article to it...
:)

http://www.neural.it/art/2009/07/keytwe ... t_fi.phtml
Logged

Pierre Proske - www.digitalstar.net
kylemcdonald
View admin
Brooklyn

Posts: 1164

Gravatar


WWW
Re: keytweeter
« Reply #6 on: July 15, 2009, 05:14:16 PM »

Yeah! I'm super excited about the neural article, it's the most "legitimate" thing I've been mentioned in yet :) I also think it's a great analysis of the idea, so it was encouraging to read.
Logged

Pierre Proske
Melbourne, Australia

Posts: 829

Gravatar


WWW
Re: keytweeter
« Reply #7 on: July 15, 2009, 10:51:56 PM »

Haha! Good to hear you're becoming  more legit Kyle  :wink:
Yeah the article is really nice...
Logged

Pierre Proske - www.digitalstar.net
Pages: [1]
 
Jump to:  

Powered by SMF 1.1.15 | SMF © 2011, Simple Machines
kinect

viagra priser