2005-02-03 15:53:24

by benbouzid imad

[permalink] [raw]
Subject: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

I want to develope a Gatway in linux OS (kernel 2.6) I
have the bluez stack and it work very well.

I want to use thes PAN profile with a NAP role for my
GW and PANU for other end users.

End users want to access to internet via the Gatway
(AP).
my acces point is now just a PC with a BT-dongle. This
PC is connected to internet via a LAN.

and my end user is another PC with a BT-dongle.

I tried yesterday to connect themselves via IP with a
client server connection using aGN role for one and
PANU for the other. It works funny.

So cans you give me the lines of code I have to write
in each PC.
if someone had already do that can you give me your
code on each side.

tanks a lot.
regards.
imad






D?couvrez le nouveau Yahoo! Mail : 250 Mo d'espace de stockage pour vos mails !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com/


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users


2005-02-03 18:44:41

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

Hi,

> machine.
> all is funny.
> I did
> #sdptool add NAP
> and I was able to find it and to connect to it.
> but if it's the sdptool which sets the services, what
> does it mean --role NAP in thes line :
> # pand --listen --role NAP

a decent version of pand can set the service entry by itself. I meant
what you see with sdptool if you execute it on your client and request
the services on the master.

> and, other thing, annother computer which is in
> windows XP needs a PIN identifier to connect itself to
> my NAP.
> where I can find this PIN whereas the PANU in linux
> connected successfuly to my NAP without asking for any
> PIN.
> In windows I tried 0000 and and without any number but
> it did't connect.

Look at /etc/bluetooth/pin for incoming connection.

> ps:Marcel you are the best i read a lot of mail by
> you. and sincerly, I admire you.

Thanks.

Regards

Marcel




-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-02-03 18:23:45

by benbouzid imad

[permalink] [raw]
Subject: Re: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

Hi,
>>then check with sdptool what is running on your NAP
machine.
all is funny.
I did
#sdptool add NAP
and I was able to find it and to connect to it.
but if it's the sdptool which sets the services, what
does it mean --role NAP in thes line :
# pand --listen --role NAP

and, other thing, annother computer which is in
windows XP needs a PIN identifier to connect itself to
my NAP.
where I can find this PIN whereas the PANU in linux
connected successfuly to my NAP without asking for any
PIN.
In windows I tried 0000 and and without any number but
it did't connect.

regards,

ps:Marcel you are the best i read a lot of mail by
you. and sincerly, I admire you.






D?couvrez le nouveau Yahoo! Mail : 250 Mo d'espace de stockage pour vos mails !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com/


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-02-03 17:21:30

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

Hi,

> I read Howto about PAN and I did :
> for the NAP:
> # pand --listen --role NAP
>
> for the PANU:
> # pand --nodetach --role PANU --search --service NAP
>
> pand[31712]: Bluetooth PAN daemon version 2.15
> pand[31712]: Inquiring
> pand[31712]: Searching for NAP on 00:02:C7:15:11:04
> "it's my NAP"
>
> config of the NAP
> # hciconfig -a
> hci0: Type: USB
> BD Address: 00:02:C7:15:11:04 ACL MTU: 192:8
> SCO MTU: 64:8
> UP RUNNING PSCAN ISCAN
> RX bytes:28224 acl:459 sco:0 events:652
> errors:0
> TX bytes:20479 acl:357 sco:0 commands:141
> errors:0
> Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00
> 0x00
> Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2
> HV3
> Link policy: RSWITCH HOLD SNIFF PARK
> Link mode: ACCEPT MASTER
> Name: 'imad'
> Class: 0x3e0100
> Service Classes: Networking, Rendering,
> Capturing
> Device Class: Computer, Uncategorized
> HCI Ver: 1.1 (0x1) HCI Rev: 0x33c LMP Ver: 1.1
> (0x1) LMP Subver: 0x33c
> Manufacturer: Cambridge Silicon Radio (10)
>
>
> config of the PANU
> # hciconfig -a
> hci0: Type: USB
> BD Address: 00:0B:0D:33:43:A5 ACL MTU: 120:20
> SCO MTU: 64:0
> UP RUNNING PSCAN ISCAN
> RX bytes:14593 acl:192 sco:0 events:330
> errors:0
> TX bytes:17841 acl:262 sco:0 commands:44
> errors:0
> Features: 0xff 0xff 0x05 0x38 0x18 0x18 0x00
> 0x00
> Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2
> HV3
> Link policy: RSWITCH HOLD SNIFF PARK
> Link mode: SLAVE ACCEPT
> Name: 'thomas'
> Class: 0x3e0100
> Service Classes: Networking, Rendering,
> Capturing
> Device Class: Computer, Uncategorized
> HCI Ver: 1.2 (0x2) HCI Rev: 0x0 LMP Ver: 1.2
> (0x2) LMP Subver:
> 0x757
> Manufacturer: Silicon Wave (11)
>
>
> but MY PANU doesn't find the NAP service over my
> NAP???
> wath's the probleme can you help me?

then check with sdptool what is running on your NAP machine.

> and ohter thing wath that mean "nat" and
> "masquerading"
> I find that in http://quozl.netrek.org/bluetooth/

Basic network technologies. This is nothing Bluetooth specific. Teach
yourself about, because there are a lot of information resources
available.

> after making bnep interface between my tow dongle i
> have to write :
> iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
> echo 1 > /proc/sys/net/ipv4/ip_forward
>
> what does it mean?

Check the manual page of iptables and then Netfilter project.

Regards

Marcel




-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-02-03 17:13:03

by benbouzid imad

[permalink] [raw]
Subject: Re: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

hi Marcel,
I read Howto about PAN and I did :
for the NAP:
# pand --listen --role NAP

for the PANU:
# pand --nodetach --role PANU --search --service NAP

pand[31712]: Bluetooth PAN daemon version 2.15
pand[31712]: Inquiring
pand[31712]: Searching for NAP on 00:02:C7:15:11:04
"it's my NAP"

config of the NAP
# hciconfig -a
hci0: Type: USB
BD Address: 00:02:C7:15:11:04 ACL MTU: 192:8
SCO MTU: 64:8
UP RUNNING PSCAN ISCAN
RX bytes:28224 acl:459 sco:0 events:652
errors:0
TX bytes:20479 acl:357 sco:0 commands:141
errors:0
Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00
0x00
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2
HV3
Link policy: RSWITCH HOLD SNIFF PARK
Link mode: ACCEPT MASTER
Name: 'imad'
Class: 0x3e0100
Service Classes: Networking, Rendering,
Capturing
Device Class: Computer, Uncategorized
HCI Ver: 1.1 (0x1) HCI Rev: 0x33c LMP Ver: 1.1
(0x1) LMP Subver: 0x33c
Manufacturer: Cambridge Silicon Radio (10)


config of the PANU
# hciconfig -a
hci0: Type: USB
BD Address: 00:0B:0D:33:43:A5 ACL MTU: 120:20
SCO MTU: 64:0
UP RUNNING PSCAN ISCAN
RX bytes:14593 acl:192 sco:0 events:330
errors:0
TX bytes:17841 acl:262 sco:0 commands:44
errors:0
Features: 0xff 0xff 0x05 0x38 0x18 0x18 0x00
0x00
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2
HV3
Link policy: RSWITCH HOLD SNIFF PARK
Link mode: SLAVE ACCEPT
Name: 'thomas'
Class: 0x3e0100
Service Classes: Networking, Rendering,
Capturing
Device Class: Computer, Uncategorized
HCI Ver: 1.2 (0x2) HCI Rev: 0x0 LMP Ver: 1.2
(0x2) LMP Subver:
0x757
Manufacturer: Silicon Wave (11)


but MY PANU doesn't find the NAP service over my
NAP???
wath's the probleme can you help me?

and ohter thing wath that mean "nat" and
"masquerading"
I find that in http://quozl.netrek.org/bluetooth/

after making bnep interface between my tow dongle i
have to write :
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward

what does it mean?

tanks,
imad


--- Marcel Holtmann <[email protected]> a ?crit :
> Hi,
>
> > I want to develope a Gatway in linux OS (kernel
> 2.6) I
> > have the bluez stack and it work very well.
> >
> > I want to use thes PAN profile with a NAP role for
> my
> > GW and PANU for other end users.
> >
> > End users want to access to internet via the
> Gatway
> > (AP).
> > my acces point is now just a PC with a BT-dongle.
> This
> > PC is connected to internet via a LAN.
> >
> > and my end user is another PC with a BT-dongle.
> >
> > I tried yesterday to connect themselves via IP
> with a
> > client server connection using aGN role for one
> and
> > PANU for the other. It works funny.
> >
> > So cans you give me the lines of code I have to
> write
> > in each PC.
> > if someone had already do that can you give me
> your
> > code on each side.
>
> the PAN howto is quite helpful and the rest is about
> masquerading and
> NAT. There are enough howtos on the internet. The
> BlueZ PAN provides you
> with a virtual network card and it works the same as
> any network card in
> your machine.
>
> Regards
>
> Marcel
>
>
>
>
>
-------------------------------------------------------
> This SF.Net email is sponsored by: IntelliVIEW --
> Interactive Reporting
> Tool for open source databases. Create drag-&-drop
> reports. Save time
> by over 75%! Publish reports on the web. Export to
> DOC, XLS, RTF, etc.
> Download a FREE copy at
> http://www.intelliview.com/go/osdn_nl
> _______________________________________________
> Bluez-users mailing list
> [email protected]
>
https://lists.sourceforge.net/lists/listinfo/bluez-users
>






D?couvrez le nouveau Yahoo! Mail : 250 Mo d'espace de stockage pour vos mails !
Cr?ez votre Yahoo! Mail sur http://fr.mail.yahoo.com/


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

2005-02-03 16:43:06

by Marcel Holtmann

[permalink] [raw]
Subject: Re: [Bluez-users] USING PAN: PANU(desktop1) ->NAP(desktop2)->internet

Hi,

> I want to develope a Gatway in linux OS (kernel 2.6) I
> have the bluez stack and it work very well.
>
> I want to use thes PAN profile with a NAP role for my
> GW and PANU for other end users.
>
> End users want to access to internet via the Gatway
> (AP).
> my acces point is now just a PC with a BT-dongle. This
> PC is connected to internet via a LAN.
>
> and my end user is another PC with a BT-dongle.
>
> I tried yesterday to connect themselves via IP with a
> client server connection using aGN role for one and
> PANU for the other. It works funny.
>
> So cans you give me the lines of code I have to write
> in each PC.
> if someone had already do that can you give me your
> code on each side.

the PAN howto is quite helpful and the rest is about masquerading and
NAT. There are enough howtos on the internet. The BlueZ PAN provides you
with a virtual network card and it works the same as any network card in
your machine.

Regards

Marcel




-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users