Welcome to madhatt.com

A Simple website from a computer geek in Colorado with dreams of moving to Alaska

My Travels Photo Gallery

Asterisk call Script File

So recently I had a issue with someone.  They were dicks and stole couple hundred bucks from me by "deactivating" a product I purchased....   This deactivation process entails the software I PURCHASED turning off every 30 minutes. 


Yes, Yes, Yes, I know, what a dick move, and probably illegal.  So to begin with I decided to fight it.  Not by suing as they dared me too.  But by calling and asking for them to pay me.  Over, and over, and over, and over again.

Thank goodness for Asterisk!

How to robocall someone with Asterisk

Step 1.

Record a WAV file of yourself saying what you would like to the caller.  Place this file in /var/lib/asterisk/sounds/

Step 2.

Create a file stored somewhere, I'll call it, asshole.call

Inside this file put in something like this.


Channel: Local/5551111111@from-internal
Application: Playback
Data: audio-recording
callerid: "You dick" <5552222222> 
The number 5551111111 represents the number you wish to call.
The number 5552222222 represents the number you wish to display in their caller ID.
The section Data: audio-recording represents the name of the file (no spaces) that contains your recorded message (minus the .WAV)
Step 3.
Create a quick and dirty script that will do 2 things.  We'll call this script /callasshole
1. copy the call file to /var/spool/asterisk/outgoing/ and 2. change the owner to asterisk so that the phone system will process it.
cp /asshole.call /var/spool/asterisk/outgoing
chown asterisk:asterisk /var/spool/asterisk/outgoing/*
Step 4.
Create a cron job that will run this file (place the call) every now and then.
enter into the terminal: crontab -e
enter in something like whats below.  This will call the the victim every morning at 7:01 AM.  It will play the recording that you set up to the caller, then hang up.
1 7 * * * /callasshole
Now just sit back and enjoy, this will call the guy every single day... this may be illegal in almost everywhere but who cares...
After a few minutes of thought I decided not to go ahead with this plan.  I decided it was much easier to circumnavigate this "activation" process. 
The server is still churning away today, or is it?