Does kaaproject.org have any solution to support udp transport between endpoint and operation server? - kaa

From the open source code of AbstractKaaClient.java below, i'm sure kaaproject supports TCP protocol between endpoint and kaa server.
KaaDataChannel operationsChannel = new DefaultOperationTcpChannel(
kaaClientState, failoverManager, failureListener);
But there are some cases, especially in IoT domain, UDP is more popular than TCP, for its bigger transport overheads. Does kaaproject.org have any plan to support udp transport ? If it has already supported, could you please give me a solution?
Thanks!

It is not supported in 0.x versions of KAA platform. But in 1.0 version we planned to add support for CoAP that built over UDP.

Related

Running program in SCTP

I need to create a program that sends messages, using SCTP, from host A to host B.
The problem is... I don't know how do run this program. How can I, using language C, send messages from one host to another.
Any vague answer is welcomed.
SCTP is a transport layer protocol, and the operating system has built-in transport layer protocols, including SCTP and you get to choose what protocol it uses.
But I think here is what you're looking for: http://simplestcodings.blogspot.com/2010/08/sctp-server-client-implementation-in-c.html
a demo implementation of SCTP above tcp/ip.

Raw Socket Sniffing in Golang

I have a question concerning tcp packet sniffing with golang.
We have written a small tool which captures all incoming TCP packets comming from a fibre Tap.
The current implementation uses a libpcap wrapper under Linux. We need to port this tool to Windows. Of course, it is not possible at the moment.
So my question is, is there a cross platform solution for sniffing packets? We only need TCP packets, IP headers , no Ethernet Data and not all features of libpcap.
If there is no cross platform solution, two Code implementation would be ok, too. I know one can use raw sockets under Linux (and with some limitations under Windows). Does Golang support raw sockets and is there an example implementation for sniffing packets with sockets?
Tanks!! :-)
You should be able to use the ipv4 package from go.net.
Package ipv4 implements IP-level socket options for the Internet Protocol version 4.
The ipv4.RawConn type and it's associated methods should work cross-platform.
A RawConn represents a packet network endpoint that uses the IPv4 transport. It is used to control several IP-level socket options including IPv4 header manipulation. It also provides datagram based network I/O methods specific to the IPv4 and higher layer protocols that handle IPv4 datagram directly such as OSPF, GRE.
There is also an equivalent package for ipv6.
Take a look at https://code.google.com/p/gopacket/ since it supports pcap (requires cgo for this) and can decode a number of protocols including tcp/ip.

Is there an article describing how to implement transport provider of the early UNIX?

I am writing a simple OS with the network feature. But i don't know how to begin the networt part. the Linux Device Driver is not easy to read.
Could you give me some matearials or suggestions?
Take a look at lwIP - A Lightweight TCP/IP stack. It implements all necessary functionality to send/receive UDP datagrams and to establish TCP connections.
lwIP is licenced under the BSD licence, so you may use it even in non-opensource project.

Tunnelling RTSP through HTTP

I need to send video stream between 2 mobile devices. Bada has no support for rtsp so i found its possible to tunnel it through http. can someone help me out with a sample on how to start of. Im new to bada application development.
bada has no RTSP per se, but it has sockets - Osp::Net::Sockets::Socket. I think your best bet is studying the description of RTSP and reimplementing it by hand over sockets. Since the bada sockets are not the same as POSIX sockets in terms of API (although I'm pretty sure bada sockets are a thin layer on top of POSIX ones), it's unlikely you'll find a ready made open source RTSP library.

Linux TCP stack packet injection

Could i inject packets to Linux TCP stack without modifying the ethernet driver? Could i do this with using a library or sth ?
Thank you,
If by 'inject packets to Linux TCP stack' you mean send some data that the Linux kernel will treat as a frame coming from an Ethernet interface then you can use a 'tap' device. If an IP packet (layer 3) is good enough, then use a 'tun' device.
http://en.wikipedia.org/wiki/TUN/TAP
http://www.kernel.org/pub/linux/kernel/people/marcelo/linux-2.4/Documentation/networking/tuntap.txt
Libnet
Libnet is a generic networking API that provides access to several protocols. It is not designed as a 'all in one' solution to networking. Currently many features that are common in some network protocols are not available with Libnet, such as streaming via TCP/IP. We feel that Libnet should not provide specific features that are possible in other protocols. If we restrict Libnet to the minimal needed to communicate (datagram/packets) then this allows it to support more interfaces.
Otherwise, if you're just wondering about injecting hand-crafted packets into the network, read the man pages and look for online help with raw sockets. Some good places to start are man 7 raw, man packet, and there are some ok tutorials at security-freak.net, though the code there is not written particularly well for my tastes.

Resources