public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
From: Marcel Holtmann <marcel@holtmann.org>
To: Vincenzo Ampolo <vincenzo.ampolo@gmail.com>
Cc: linux-bluetooth@vger.kernel.org, Stefano Zanero <zanero@elet.polimi.it>
Subject: Re: Bluetooth honeypot - hci socket that reads package problem -
Date: Mon, 20 Jul 2009 15:09:32 +0200	[thread overview]
Message-ID: <1248095372.4549.122.camel@violet> (raw)
In-Reply-To: <200907201503.51944.vincenzo.ampolo@gmail.com>

Hi Vincenzo,

> > You need to set the device into RAW mode. Otherwise the kernel will keep
> > processing the HCI packets.
> 
> Do you mean that i've to use a special device that supports RAW mode or that i 
> can open a socket in RAW mode?
> 
> if it's the latter,i'm googlin for a while and i don't find any useful 
> information. How should i call the socket C function to accomplish it?

you have to turn the Bluetooth HCI device into RAW mode. And also
hciconfig will tell you if the device is in that mode. Otherwise you
will have the kernel interfere and act as it is suppose to.

	dd = hci_open_dev(dev_id);
	ioctl(dd, HCISETRAW, 1);
	hci_close_dev(dd);

Regards

Marcel



      reply	other threads:[~2009-07-20 13:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-20  7:38 Bluetooth honeypot - hci socket that reads package problem - Vincenzo Ampolo
2009-07-20  7:45 ` Marcel Holtmann
2009-07-20 13:03   ` Vincenzo Ampolo
2009-07-20 13:09     ` Marcel Holtmann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1248095372.4549.122.camel@violet \
    --to=marcel@holtmann.org \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=vincenzo.ampolo@gmail.com \
    --cc=zanero@elet.polimi.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox