LwIP

Last updated
Original author(s) Adam Dunkels
Developer(s) lwIP developers group
Stable release
2.2.0 [1] / 25 September 2023;16 days ago (2023-09-25)
Repository
Written in C
Operating system multiple
Platform embedded systems
Type IP stack
License Modified BSD license
Website www.nongnu.org/lwip/

lwIP (lightweight IP) is a widely used open-source TCP/IP stack designed for embedded systems. lwIP was originally developed by Adam Dunkels at the Swedish Institute of Computer Science and is now developed and maintained by a worldwide network of developers.

Contents

lwIP is used by many manufacturers of embedded systems, including Intel/Altera, Analog Devices, [2] Xilinx, [3] TI, ST and Freescale.

lwIP network stack

The focus of the lwIP network stack implementation is to reduce resource usage while still having a full-scale TCP stack. [4] This makes lwIP suitable for use in embedded systems with tens of kilobytes of free RAM and room for around 40 kilobytes of code ROM.

lwIP protocol implementations

Aside from the TCP/IP stack, lwIP has several other important parts, such as a network interface, an operating system emulation layer, buffers and a memory management section. The operating system emulation layer and the network interface allow the network stack to be transplanted into an operating system, as it provides a common interface between lwIP code and the operating system kernel. [4]

The network stack of lwIP includes an IP (Internet Protocol) implementation at the Internet layer that can handle packet forwarding over multiple network interfaces. [4] Both IPv4 and IPv6 are supported dual stack since lwIP v2.0.0 . [5] For network maintenance and debugging, lwIP implements ICMP (Internet Control Message Protocol). [4] IGMP (Internet Group Management Protocol) is supported for multicast traffic management. While ICMPv6 (including MLD) is implemented to support the use of IPv6.[ citation needed ]

lwIP includes an implementation of IPv4 ARP (Address Resolution Protocol) and IPv6 Neighbor Discovery Protocol to support Ethernet at the data link layer. lwIP may also be operated on top of a PPP (Point-to-Point Protocol) implementation at the data link layer.[ citation needed ]

At the transport layer lwIP implements TCP (Transmission Control Protocol) with congestion control, RTT estimation and fast recovery/fast retransmit. [4] UDP (User Datagram Protocol) is implemented with experimental UDP-Lite extensions.[ citation needed ]

APIs and sockets

lwIP provides a specialized no-copy application programming interface (API) for enhanced network stack performance. The Berkeley socket API is optional. [4] Raw sockets, or raw pcbs (protocol control blocks), are provided depending on the API used. [6]

Application layer support

At the application layer the lwIP network stack may be supported through the implementation of the following protocols. The DNS (Domain Name System), an SNMP (Simple Network Management Protocol) agent, in v1, v2 or v3, with private MIB (management information base) support and MIB compiler.

Operating systems that implement the lwIP TCP/IP stack may provide a range of supporting clients and servers at the application layer. Such as an IPv4 DHCP (Dynamic Host Configuration Protocol) client or IPv4 link-local addresses (AutoIP). Specialized raw API applications include: an HTTP server, a SNTP client, a SMTP client, a NetBIOS nameserver, a mDNS responder, a MQTT client and a TFTP server.[ citation needed ]

OS implementations

lwIP is used as network stack in ReactOS and Genode [7] and can be used in Minix and GNU Hurd to implement network servers.

See also

Related Research Articles

An Internet Protocol address is a numerical label such as 192.0.2.1 that is connected to a computer network that uses the Internet Protocol for communication. An IP address serves two main functions: network interface identification, and location addressing.

<span class="mw-page-title-main">IPv6</span> Version 6 of the Internet Protocol

Internet Protocol version 6 (IPv6) is the most recent version of the Internet Protocol (IP), the communications protocol that provides an identification and location system for computers on networks and routes traffic across the Internet. IPv6 was developed by the Internet Engineering Task Force (IETF) to deal with the long-anticipated problem of IPv4 address exhaustion, and was intended to replace IPv4. In December 1998, IPv6 became a Draft Standard for the IETF, which subsequently ratified it as an Internet Standard on 14 July 2017.

The Internet protocol suite, commonly known as TCP/IP, is a framework for organizing the set of communication protocols used in the Internet and similar computer networks according to functional criteria. The foundational protocols in the suite are the Transmission Control Protocol (TCP), the User Datagram Protocol (UDP), and the Internet Protocol (IP). Early versions of this networking model were known as the Department of Defense (DoD) model because the research and development were funded by the United States Department of Defense through DARPA.

In computer networking, the User Datagram Protocol (UDP) is one of the core communication protocols of the Internet protocol suite used to send messages to other hosts on an Internet Protocol (IP) network. Within an IP network, UDP does not require prior communication to set up communication channels or data paths.

<span class="mw-page-title-main">Network address translation</span> Protocol facilitating connection of one IP address space to another

Network address translation (NAT) is a method of mapping an IP address space into another by modifying network address information in the IP header of packets while they are in transit across a traffic routing device. The technique was originally used to bypass the need to assign a new address to every host when a network was moved, or when the upstream Internet service provider was replaced, but could not route the network's address space. It has become a popular and essential tool in conserving global address space in the face of IPv4 address exhaustion. One Internet-routable IP address of a NAT gateway can be used for an entire private network.

Berkeley sockets is an application programming interface (API) for Internet sockets and Unix domain sockets, used for inter-process communication (IPC). It is commonly implemented as a library of linkable modules. It originated with the 4.2BSD Unix operating system, which was released in 1983.

NetBIOS is an acronym for Network Basic Input/Output System. It provides services related to the session layer of the OSI model allowing applications on separate computers to communicate over a local area network. As strictly an API, NetBIOS is not a networking protocol. Operating systems of the 1980s ran NetBIOS over IEEE 802.2 and IPX/SPX using the NetBIOS Frames (NBF) and NetBIOS over IPX/SPX (NBX) protocols, respectively. In modern networks, NetBIOS normally runs over TCP/IP via the NetBIOS over TCP/IP (NBT) protocol. This results in each computer in the network having both an IP address and a NetBIOS name corresponding to a host name. NetBIOS is also used for identifying system names in TCP/IP (Windows). Simply stated, it is a protocol that allows communication of data for files and printers through the Session Layer of the OSI Model in a LAN.

In computing, the Windows Sockets API (WSA), later shortened to Winsock, is an application programming interface (API) that defines how Windows network application software should access network services, especially TCP/IP. It defines a standard interface between a Windows TCP/IP client application and the underlying TCP/IP protocol stack. The nomenclature is based on the Berkeley sockets API used in BSD for communications between programs.

The Bootstrap Protocol (BOOTP) is a computer networking protocol used in Internet Protocol networks to automatically assign an IP address to network devices from a configuration server. The BOOTP was originally defined in RFC 951 published in 1985.

SOCKS is an Internet protocol that exchanges network packets between a client and server through a proxy server. SOCKS5 optionally provides authentication so only authorized users may access a server. Practically, a SOCKS server proxies TCP connections to an arbitrary IP address, and provides a means for UDP packets to be forwarded.

Zero-configuration networking (zeroconf) is a set of technologies that automatically creates a usable computer network based on the Internet Protocol Suite (TCP/IP) when computers or network peripherals are interconnected. It does not require manual operator intervention or special configuration servers. Without zeroconf, a network administrator must set up network services, such as Dynamic Host Configuration Protocol (DHCP) and Domain Name System (DNS), or configure each computer's network settings manually.

<span class="mw-page-title-main">Contiki</span> Real-time operating system

Contiki is an operating system for networked, memory-constrained systems with a focus on low-power wireless Internet of Things (IoT) devices. Contiki is used for systems for street lighting, sound monitoring for smart cities, radiation monitoring and alarms. It is open-source software released under the BSD-3-Clause license.

TCP offload engine (TOE) is a technology used in some network interface cards (NIC) to offload processing of the entire TCP/IP stack to the network controller. It is primarily used with high-speed network interfaces, such as gigabit Ethernet and 10 Gigabit Ethernet, where processing overhead of the network stack becomes significant. TOEs are often used as a way to reduce the overhead associated with Internet Protocol (IP) storage protocols such as iSCSI and Network File System (NFS).

In computer networks, a tunneling protocol is a communication protocol which allows for the movement of data from one network to another. It involves allowing private network communications to be sent across a public network through a process called encapsulation.

A network socket is a software structure within a network node of a computer network that serves as an endpoint for sending and receiving data across the network. The structure and properties of a socket are defined by an application programming interface (API) for the networking architecture. Sockets are created only during the lifetime of a process of an application running in the node.

Adam Dunkels is a Swedish computer scientist, computer programmer, entrepreneur, and founder of Thingsquare, an Internet of things (IoT) product development business.

In computing, Microsoft's Windows Vista and Windows Server 2008 introduced in 2007/2008 a new networking stack named Next Generation TCP/IP stack, to improve on the previous stack in several ways. The stack includes native implementation of IPv6, as well as a complete overhaul of IPv4. The new TCP/IP stack uses a new method to store configuration settings that enables more dynamic control and does not require a computer restart after a change in settings. The new stack, implemented as a dual-stack model, depends on a strong host-model and features an infrastructure to enable more modular components that one can dynamically insert and remove.

An IPv6 transition mechanism is a technology that facilitates the transitioning of the Internet from the Internet Protocol version 4 (IPv4) infrastructure in use since 1983 to the successor addressing and routing system of Internet Protocol Version 6 (IPv6). As IPv4 and IPv6 networks are not directly interoperable, transition technologies are designed to permit hosts on either network type to communicate with any other host.

The uIP is an open-source implementation of the TCP/IP network protocol stack intended for use with tiny 8- and 16-bit microcontrollers. It was initially developed by Adam Dunkels of the Networked Embedded Systems group at the Swedish Institute of Computer Science, licensed under a BSD style license, and further developed by a wide group of developers.

NicheStack is a closed source IPv4 network layer and application implementation for operating systems, written in ANSI "C" and is one of three available from InterNiche Technologies, Inc., designed for use in embedded systems. Its transport layer implementation has historical roots in BSD and the IP layer was derived from a Carnegie Mellon University (CMU) implementation.

References

  1. "lwIP 2.2.0 released" . Retrieved 2023-10-11.
  2. "Building Complex VDK/LwIP Applications Using Blackfin Processors ", Kaushal Sanghai, Analog Devices Inc. September 2008
  3. Siva Velusamy, LightWeight IP (lwIP) Application Examples, Xilinx Inc. June 2009
  4. 1 2 3 4 5 6 Wu, Yanwen, ed. (2010). Software engineering and knowledge engineering : theory and practice. Berlin: Springer. p. 639. ISBN   978-3-642-03717-7.
  5. "LwIP: Upgrading".
  6. lwIP functions documentation
  7. "Release notes for the Genode OS Framework 9.11".