30 Apr 2012 11:25
OSI TP4 stack on netbsd
Marcos Pindado Sebastian <mapindado <at> aubay.es>
2012-04-30 09:25:53 GMT
2012-04-30 09:25:53 GMT
Hello, I would like to know if osi stack is still supported on NetBSD, particularly TP4 transport services.
In the archive list along the years it seems several people tried to make this work but don't seem to get it.
This is what we are doing:
- Compile kernel with OSI stacks
- Configure osi protocol for the interface:
XXXX# ifconfig tlp0 iso 2222
XXXX$ ifconfig -a
tlp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
address: 00:30:05:56:34:d2
media: Ethernet autoselect (10baseT)
status: active
inet 192.168.17.55 netmask 0xffffff00 broadcast 192.168.17.255
inet6 fe80::230:5ff:fe56:34d2%tlp0 prefixlen 64 scopeid 0x1
iso 22.22 netmask
- Write a simple client and server socket example. Server justs binds to any address and listens for
connections. Client just tries to connect. It will happen in the same machine.
server:
tp4sock = socket(AF_ISO, SOCK_SEQPACKET, 0)
memset(&isoaddr, 0, sizeof(isoaddr)); => Empty addr, listen on any nsap
isoaddr.siso_family = AF_ISO;
isoaddr.siso_tlen = 2;
cp = (char*)TSEL(&isoaddr); => 2 bytes for selector.
*cp++ = (PORT >> 8); => The same on client. Find this code on bsd nfs server.
*cp = (PORT & 0xff);
Bind => ok, listen => ok
(Continue reading)
RSS Feed