Lunatik is a framework for scripting the Linux kernel with Lua.

Modules

bpf Lua interface to eBPF.
bpf.map High-level view over pinned eBPF maps.
byteorder Byte Order Conversion
completion Lua bindings for kernel completion mechanisms.
cpu Lua interface to Linux CPU abstractions.
class Minimal class helper for the OOP-style modules (e.g.
crypto Lua interface to the Linux Crypto API.
darken Encrypted Lua script execution using AES-256-CTR.
data Direct memory access and manipulation.
device Low-level Lua interface for creating Linux character device drivers.
fifo kfifo (kernel FIFO) implementation.
hid Lua interface to the Linux HID subsystem.
lighten Encrypted Lua script support (AES-256-CTR).
lunatik Manages Lunatik runtimes — isolated Lua states running in the kernel.
lunatik.runner Manages the execution and lifecycle of Lunatik scripts.
linux Various Linux kernel facilities.
linux.bpf Linux kernel constants exposed under linux.bpf.
linux.eth Linux kernel constants exposed under linux.eth.
linux.genl Linux kernel constants exposed under linux.genl.
linux.kbd Linux kernel constants exposed under linux.kbd.
linux.netdev Linux kernel constants exposed under linux.netdev.
linux.netlink Linux kernel constants exposed under linux.netlink.
linux.nf Linux kernel constants exposed under linux.nf.
linux.nl80211 Linux kernel constants exposed under linux.nl80211.
linux.notify Linux kernel constants exposed under linux.notify.
linux.rtnetlink Linux kernel constants exposed under linux.rtnetlink.
linux.signal Linux kernel constants exposed under linux.signal.
linux.socket Linux kernel constants exposed under linux.socket.
linux.stat Linux kernel constants exposed under linux.stat.
linux.syscall Linux kernel constants exposed under linux.syscall.
linux.task Linux kernel constants exposed under linux.task.
linux.tc Linux kernel constants exposed under linux.tc.
linux.vt Linux kernel constants exposed under linux.vt.
linux.xdp Linux kernel constants exposed under linux.xdp.
mailbox Inter-runtime communication mechanism using FIFOs and completions.
net Network utility functions.
netlink The netlink namespace.
netlink.genl Generic netlink (NETLINK_GENERIC) interface.
netlink.message Netlink wire codec shared by the netlink modules.
netlink.nl80211 The nl80211 (wireless) namespace.
netlink.nl80211.ap Access Point control.
netlink.nl80211.interface Wireless interface management.
netlink.nl80211.object Base class for the nl80211 object classes (wiphy, interface, ...): a netlink.genl session bound to the "nl80211" family, caching its id and carrying the shared dump-decode loop.
netlink.nl80211.station Station management.
netlink.nl80211.wiphy Wireless PHY (wiphy) listing.
netlink.rt The rtnetlink namespace.
netlink.rt.addr Interface address listing.
netlink.rt.link Network interface (link) management.
netlink.rt.object Base class for the rtnetlink object classes (route, link, addr, rule): a netlink.session over the NETLINK_ROUTE protocol carrying the shared dump loop and the routing-table id split.
netlink.rt.route Kernel routing table interface.
netlink.rt.rule FIB rule (policy routing) interface.
netlink.session Netlink request/response session.
netfilter Lua interface to the Linux Netfilter framework.
netlink.channel Generic netlink channel: a generic netlink family with one multicast group whose multicast/unicast are safe from softirq (netfilter hooks, XDP), for kernel-to-userspace delivery.
skb Linux socket buffer interface.
notifier Notifier chain mechanism.
probe kprobes interface.
rcu RCU-synchronized hash table.
signal POSIX Signals
socket Low-level Lua interface for kernel networking sockets.
set A set is a compact, immutable set of strings, queried by binary search.
socket.inet Internet (AF_INET) socket operations.
socket.raw RAW AF_PACKET socket operations.
socket.unix UNIX domain socket (AF_UNIX) operations.
struct Binary codec for fixed C struct layouts.
syscall Accessing kernel system call information.
syscall.table A table mapping system call names to their kernel addresses.
task Linux task interface.
tc Linux Traffic Control (TC) integration.
thread Kernel thread primitives.
xdp eXpress Data Path (XDP) integration.

Classes

crypto.hkdf HMAC-based Extract-and-Expand Key Derivation Function (HKDF) based on RFC 5869.
crypto_aead Lua interface to AEAD (Authenticated Encryption with Associated Data) ciphers.
crypto_comp Lua interface to synchronous compression algorithms.
crypto_rng Lua interface to synchronous Random Number Generators (RNG).
crypto_shash Lua interface to synchronous message digest (hash) algorithms, including HMAC.
crypto_skcipher Lua interface to symmetric-key ciphers (SKCIPHER).
skb.attr Attribute view over an skb: reads and writes packet fields as table keys (view.mark, view.priority) instead of method calls.

Topics

README.md
generated by LDoc 1.5.0 Last updated 2026-09-05 12:27:44