![Wink ;)](./images/smilies/icon_wink.gif)
![Wink ;)](./images/smilies/icon_wink.gif)
Code: Alles auswählen
hciconfig hci0 lm master,accept
hciconfig hci0 piscan
Bei Bluetooth-Verbindungen muss man immer eine beliebige PIN eingeben. Die wird dann auf dem zu verbindenden Geraet ebenfalls abgefragt. Einfach nochmal die selbe eingeben und fertig.outis hat geschrieben:Er fragt noch noch einer PIN - keine Ahnung, wo die konfiguriert wird.
bluetooth-agent[...]
PIN (or passkey) management
---------------------------
Interaction with the local user can be required while BT connection is
being established (pairing process) and the PIN is not yet known or
needs to be changed.
To retrieve the passkey (or PIN) from the user a service program (agent)
running in user's interactive session needs to be prepared and listen
for requests of the bluez daemon when pairing begins.
Examples of such programs are kblueplugd (kdebluetooth package) and
bluetooth-applet (bluez-gnome or gnome-bluetooth packages). A minimal
command-line agent is also provided by bluetooth-agent.
[...]
3. PAN
The 'pand' tool allows you to use ethernet style networking over
Bluetooth. It creates a network interface on your machine that can be
configured in the same way normal network devices are.
For full details see the PAN HOWTO at
<http://bluez.sourceforge.net/contrib/HOWTO-PAN>
[...]
Code: Alles auswählen
$ bluetooth-agent
Bluetooth agent ver 4.66
Usage:
agent [--adapter adapter-path] [--path agent-path] <passkey> [<device>]
Code: Alles auswählen
root:~# bluetooth-agent 1234
apt-cache show bluez-compat
Dieses Paket enthält die veralteten Binärdateien, die an die Paaren-Methode
von BlueZ 3.x erinnern. Diese Binärdateien sind nicht unterstützt und
werden zukünftig verschwinden. Die bereitgestellten Binärdateien sind:
.
hidd
dund
pand
Code: Alles auswählen
root@epia:~# apt-cache search pand|grep blue
bluez-compat - Kompatibilitätsbinärdateien BlueZ 3.x
Code: Alles auswählen
root@epia:~# dpkg -l|grep blue
ii bluetooth 4.66-2 Bluetooth support
ii bluez 4.66-2 Bluetooth tools and daemons
ii bluez-utils 4.66-2 Transitional package
ii libbluetooth3 4.66-2 Library to use the BlueZ Linux Bluetooth stack
Code: Alles auswählen
root@epia:~# which pand
root@epia:~#
Code: Alles auswählen
post-up iptables -t nat -A POSTROUTING -s 192.168.x.x/24 -j MASQUERADE
post-up iptables -A FORWARD -i bnep0 -o eth0 -j ACCEPT
post-up iptables -A FORWARD -o bnep0 -i eth0 -j ACCEPT
Code: Alles auswählen
root@epia:~# iptables -L -v
Chain INPUT (policy ACCEPT 3462 packets, 418K bytes)
pkts bytes target prot opt in out source destination
Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination
Chain OUTPUT (policy ACCEPT 3427 packets, 423K bytes)
pkts bytes target prot opt in out source destination
Code: Alles auswählen
Dec 22 14:23:23 epia bluetoothd[1752]: Bluetooth deamon 4.66
Dec 22 14:23:23 epia bluetoothd[1752]: Starting SDP server
Dec 22 14:23:23 epia bluetoothd[1752]: Starting experimental netlink support
Dec 22 14:23:23 epia bluetoothd[1752]: Failed to find Bluetooth netlink family
Dec 22 14:23:23 epia bluetoothd[1752]: Failed to init netlink plugin
Dec 22 14:23:23 epia bluetoothd[1752]: bridge pan0 created
Dec 22 14:23:23 epia bluetoothd[1752]: HCI dev 0 registered
Dec 22 14:23:23 epia bluetoothd[1752]: HCI dev 0 up
Dec 22 14:23:23 epia bluetoothd[1752]: Starting security manager 0
Dec 22 14:23:23 epia bluetoothd[1752]: ioctl(HCIUNBLOCKADDR): Invalid argument (22)
Dec 22 14:23:23 epia bluetoothd[1752]: Adapter /org/bluez/1752/hci0 has been enabled
Dec 22 14:23:23 epia bluetoothd[1752]: Failed to access HAL
Dec 22 14:23:32 epia acpid: client connected from 1834[0:0]
Dec 22 14:23:32 epia acpid: 1 client rule loaded
Dec 22 14:23:33 epia kernel: [ 71.434205] [drm] Initialized drm 1.1.0 20060810
Dec 22 14:23:33 epia kernel: [ 71.463444] pci 0000:01:00.0: PCI INT A -> Link[LNKA] -> GSI 11 (level, low) -> IRQ 11
Dec 22 14:23:33 epia kernel: [ 71.466869] [drm] Initialized via 2.11.1 20070202 for 0000:01:00.0 on minor 0
Dec 22 14:23:33 epia kernel: [ 71.485360] agpgart-via 0000:00:00.0: AGP 2.0 bridge
Dec 22 14:23:33 epia kernel: [ 71.485422] agpgart-via 0000:00:00.0: putting AGP V2 device into 4x mode
Dec 22 14:23:33 epia kernel: [ 71.485534] pci 0000:01:00.0: putting AGP V2 device into 4x mode
Dec 22 14:23:35 epia lircd-0.8.3[1196]: accepted new client on /dev/lircd
Dec 22 14:24:46 epia bluetoothd[1752]: Refusing connect from 00:04:3E:A5:0D:98: Operation not permitted (1)
Dec 22 14:24:46 epia bluetoothd[1752]: link_key_request (sba=00:19:0E:00:AA:B9, dba=00:04:3E:A5:0D:98)
Code: Alles auswählen
1756 pts/4 S+ 0:00 \_ bluetooth-agent --adapter hci0 xxxx
Code: Alles auswählen
bnep0 Link encap:Ethernet Hardware Adresse 00:19:0e:00:aa:b9
inet6-Adresse: fe80::219:eff:fe00:aab9/64 Gültigkeitsbereich:Verbindung
UP BROADCAST RUNNING MULTICAST MTU:1500 Metrik:1
RX packets:57 errors:0 dropped:0 overruns:0 frame:0
TX packets:13 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:1000
RX bytes:4641 (4.5 KiB) TX bytes:397 (397.0 B)
pan0 Link encap:Ethernet Hardware Adresse 00:19:0e:00:aa:b9
inet6-Adresse: fe80::219:eff:fe00:aab9/64 Gültigkeitsbereich:Verbindung
UP BROADCAST RUNNING MULTICAST MTU:1500 Metrik:1
RX packets:48 errors:0 dropped:0 overruns:0 frame:0
TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
Kollisionen:0 Sendewarteschlangenlänge:0
RX bytes:2816 (2.7 KiB) TX bytes:468 (468.0 B)
Code: Alles auswählen
Ziel Router Genmask Flags Metric Ref Use Iface
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0
Code: Alles auswählen
Mar 6 01:46:03 SLUG bluetoothd[1279]: Refusing connect from 00:XX:XX:XX:XX:XX: Operation not permitted (1)
Mar 6 01:46:06 SLUG bluetoothd[1279]: link_key_request (sba=00:XX:XX:XX:XX:XX, dba=00:XX:XX:XX:XX:XX)
Code: Alles auswählen
root@epia:~# hciconfig -a
hci0: Type: BR/EDR Bus: USB
BD Address: 00:19:0E:00:AA:B9 ACL MTU: 1021:8 SCO MTU: 64:1
UP RUNNING PSCAN ISCAN
RX bytes:22328 acl:330 sco:0 events:614 errors:0
TX bytes:15887 acl:334 sco:0 commands:248 errors:0
Features: 0xff 0xff 0x8f 0xfe 0x9b 0xff 0x79 0x83
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: RSWITCH HOLD SNIFF PARK
Link mode: ACCEPT MASTER
Name: 'epia-0'
Class: 0x020100
Service Classes: Networking
Device Class: Computer, Uncategorized
HCI Version: 2.1 (0x4) Revision: 0x5184
LMP Version: 2.1 (0x4) Subversion: 0x420e
Manufacturer: Broadcom Corporation (15)