Installling WhatsSpy Public on your Raspberry Pi/Server/VPS
WhatsSpy Public is an web-oriented application that tracks every move of whoever you like to follow. This application is setup as an Proof of Concept that Whatsapp is broken in terms of privacy. Once you've setup this application you can track users that you want to follow on Whatsapp. Once it's running it keeps track of the following activities:
- Online/Offline status (even with privacy options set to "nobody")
- Profile pictures
- Privacy settings
- Status messages
Screenshots
Overview page:

Getting started
This guide requires knowledge of Linux, PHP, PostgreSQL. There is no proper error reporting. I'm not responsible in any way if you screw it up! WhatsApp might even block your account, I can't tell.
Requirements
Shortlist requirements:
- Secondary Whatsapp account (phonenumber that doesn't actively uses Whatsapp)
- Rooted Android phone OR Jailbroken iPhone OR PHP knowledge
- Server/RPi that runs 24/7
- Nginx or Apache with PHP with PDO (php5-pgsql installed) (you can't host on simple webhoster, you need bash)
- Postgresql
Notice
WhatsSpy Public requires an secondary Whatsapp account. Once the tracker is started, you will not be able to recieve any messages over Whatsapp for this phonenumber. You can either try to register an non-Whatsapp used phonenumber with for example this script or just buy an 5 euro SIM Card and use this phonenumber for the tracker.
For the tracker to work you need an secret which is retrieved from either your Phone or the register script mentioned above. In case of phone registration you need an jailbroken iPhone or rooted Android device in order to retrieve the secret.
- Jailbroken iPhone users: You can retrieve using this script.
- Rooted Android phones can use the following APK to retrieve the secret.
In order to retrieve the scecret you need to follow these steps:
- Insert your (new) secondary SIM card in your phone and boot it up.
- Re-install Whatsapp on your phone and activate it using the new phonenumber.
- Use either the APK (Android) or the script (iPhone) to retrieve the WhatsApp secret. Write this secret down, which is required later.
- Insert your normal SIM card and re-install WhatsApp for normal use.
Installation
- Download the repository and unpack these files on your server at for example
/whatsspy/in your web directory (for nginx in debian this is/var/www/). note that the git clone does not work for SSH. You can only use HTTP on this gitlab server - Log in your PostgreSQL database and create an new DB and user for WhatsSpy Public (Insert password for DB user):
- Open
api/whatsspy-db.sqland execute these SQL commands in your whatsspy database (with PgAdmin or step 4). - Update: You can use the commmandto insert these SQL statements in the correct database.
- rename
config.example.phptoconfig.phplocated atapi/and fill in the following details: - Postgresql host/port/dbname/user and password correctly in
$dbAuth. - Insert your 'number' and 'secret' in
$whatsappAuth. - 'number' needs to be without any prefix 0's. 0031 06 xxx becomes 31 6 xxx (no 0's prefix for both the country code and phonenumber itself).
- 'number' may only contain digits. Spaces, plus or any other special character are NOT accepted. Example: 316732174
- Set the absolute path correct in
$whatsspyProfilePath. If you've installed WhatsSpy Public in for example/var/www/whatsspythe correct directory would be/var/www/whatsspy/images/profilepicture/(including/) - You can set an Optional NotifyMyAndroid key for notifications about the tracker (startup,shutdown,errors etc) in
$whatsspyNMAKey. - Check folder rights: the tracker needs read/write acces in both the folder
$whatsspyProfilePathandapi/!
Webserver
You need to restrict access to Whatsspy and the api of Whatsspy from unauthorised web access.
Nginx
For Nginx add the following:
assuming you installed whatsspy in a subdirectory called
/whatsspy in the web directory /var/www/ (default setup)
You can create an .htpasswd here. Make sure you reload the configuration by executing
service nginx reload.Apache
create an
.htaccess in the whatsspy folder and add the following:
Do not place the .htpasswd in the
/var/www folder. You can create an .htpasswd here. The api/ folder is protected by default.Importing users
If everything went well you can now access the WhatsSpy Public interface through your webserver. At this point you need to import users that you want to track (Troubleshooting):
- Either add any contact manually by using "Add contact by phonenumber".
- Or use "import google Contacts" which is an script that retrieves all your Google Contacts and gives an SQL statement which insert all users into the database.
Once you have inserted these users they won't show up automatically. They need to be verified by the tracker which is not running yet.
Starting the tracker
Once you have populated your database with some users, you can start the tracker.
- start a new
screen(if you do not have screen:sudo apt-get install screenor similar for other distro's) - cd to the install of the Whatsspy (for example
/var/www/whatsspy/) and execute`which php` api/tracker.php. - If all runs well it starts spamming information about privacy options and polls.
- It keeps polling every 2 seconds and outputs any statusses on the screen.
- You can exit the screen by using
Ctrl+aand after thatCtrl+d(detaching the screen) in your terminal/Putty.
No comments:
Post a Comment