Results 1 to 4 of 4

Thread: Bluetooth Dial Up Networking on Linux Share/Save - My123World.Com!

  1. #1

    Bluetooth Dial Up Networking on Linux

    Hello Hackers;

    I am just documenting this topic because I tend to forget it all the time.
    On this same laptop I have banged my head everytime after a fresh linux installation.
    The GUI tools for this given with any linux distro never worked for me. I always had to go the old Linux way.

    So finally, I am documenting it here.
    Might follow it if you need to do the same.

    You would need bluez package and wvdial package. Bluez for bluetooth connectivity and wvdial for dialing to a network.

    For example on a Gnome Ubuntu box:

    # apt-get install bluez-utils bluez-gnome wvdial

    Now you need to pair up your machine and your phone device. When done, we can proceed with binding.

    First scan for devices

    # hcitool scan

    Would get result something like this

    Scanning …
    xx:xx:xx:xx:xx:xx Austin (xx:xx:xx:xx:xx:xx is your devices bluetooth ID)

    Now just check if that device supports DUN or not

    # sdptool search dun xx:xx:xx:xx:xx:xx

    This should give output something like following

    Inquiring ...
    Searching for dun on xx:xx:xx:xx:xx:xx ...
    Service Name: Dial-Up Networking
    Service RecHandle: 0x10005
    Service Class ID List:
    "Dialup Networking" (0x1103)
    "Generic Networking" (0x1201)
    Protocol Descriptor List:
    "L2CAP" (0x0100)
    "RFCOMM" (0x0003)
    Channel: 1
    Profile Descriptor List:
    "Dialup Networking" (0x1103)
    Version: 0x0100

    I see that my device supports L2CAP protocol and on top of that RFCOMM is available. I see that the service may be accessed via channel 1.
    This should be the thing with most of of devices today.

    Now lets just bind them up:

    # rfcomm bind <rfcomm interface> <Target BT addr> <channel>

    In my case:

    # rfcomm bind 0 xx:xx:xx:xx:xx:xx 1

    Now check if it worked.

    # rfcomm

    If it does show a clean report like this, then it worked !

    rfcomm0: xx:xx:xx:xx:xx:xx channel 1 clean

    Now rfcomm config has to be changed accordingly.
    The config normally is placed at /etc/bluetooth/rfcomm.conf

    Just make it look like this:

    # RFCOMM configuration file.

    rfcomm0 {
    bind yes;
    device 00:xx:xx:xx:xx:xx:xx;
    channel 1;
    comment “My_BT_device“;

    #End of config

    Now restart the bluetooth service:

    # /etc/init.d/bluetooth restart

    Now you are done with your bluetooh stuff.

    Going to Dial Up stuff:

    You will have to check for specific settings for your service provider.
    Here is the config file for Idea Internet:


    [Dialer Defaults]
    Modem = /dev/rfcomm0
    Baud = 30720000
    Dial Command = ATDT
    Init1 = ATE1
    Init2 = AT+CGDCONT=1,"IP","Internet","",0,0
    FlowControl = CRTSCTS
    Init3 = ATM0
    Phone = *99***1#
    Username = (empty)
    Password = (empty)
    Stupid Mode = 1


    Hope it helps you and saves me from banging head again !


    Godwin Austin
    Last edited by Godwin Austin; 02-03-2012 at 01:59 PM.
    Fairy tales do not tell children the dragons exist. Children already know that dragons exist. Fairy tales tell children the dragons can be killed

  2. #2
    Web Security Consultant amolnaik4's Avatar
    Join Date
    Jul 2011
    Blog Entries
    Nice article Austin.

    Do you/anybody used USB internet modem like Tata Photon+ on ubuntu?
    Wanted to check how to configure it and issues faced.

    AMol NAik

  3. #3
    Actually for USB modems too wvdial should work.
    Instead of Modem = /dev/rfcomm0 in above configuration you could use /dev/ttyACM0 or /dev/ttyUSB0.
    Check for device name in your /dev/ after connecting the device to your machine.

    Change the 'internet' in Init2 of config to your APN. For idea, the APN is internet.

    You have your username and password for it. Normally its the phone number. Replace username, password feild accordingly.
    You should be good to go.

    Might even try to run command 'wvdialconf' after connecting your modem. The command autoconfigures for your modem.
    Then you will just have to add the APN, username and password.

    Hope that helps
    Last edited by Godwin Austin; 02-03-2012 at 04:23 PM.
    Fairy tales do not tell children the dragons exist. Children already know that dragons exist. Fairy tales tell children the dragons can be killed

  4. #4
    InfoSec Consultant the_empty's Avatar
    Join Date
    Jul 2010
    the blue no-where
    Blog Entries
    Above things should generally work. However, if you are facing a problem such as the device is being detected as mass storage device and not as modem, do not install that package mentioned in most of the solution post regarding this (forgot the name) directly. be careful as it might not allow installing anything after that. I lost my BT instance once because of that.

    old-------------before noticing austin's post----------
    what version of ubuntu and the Photon card ur using Amol. I might come of some help maybe .. done it quite a lot of times.

    However I am in love with bt5 now because it takes all the pain and lets us configure these devices easily

    Last edited by the_empty; 02-08-2012 at 08:26 PM.

Tags for this Thread

Posting Permissions

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