Lua Workshop 2017

The Lua Workshop 2017 will be held in San Francisco, CA, on October 16–17, 2017, courtesy of Kong.

As in previous workshops, the main goal of the workshop is to allow the Lua community to get together and meet in person and talk about the Lua language, its uses, and its implementation.

The workshop is open to everyone interested in Lua. Register now to reserve a seat.

Please make your own travel and accommodation arrangements. See the information on last year's local page. Contact us if you need help or have special requirements.

Registration

Registrations are now open. There is no registration fee but registration is required because space is limited.

To register to attend the workshop, please send a message to lua.workshop@gmail.com including your full name and the name of your company or organization, if applicable. As confirmation, your name will appear in the list of participants.

Program

We shall have a plenary talk by Roberto Ierusalimschy (Lua's chief architect) and several contributed talks. There will also be plenty of time for getting together and chatting about Lua.

Here is the preliminary schedule:


Monday, Oct 16th

9:00 registration and badge pick-up
9:30 How Much Does it Cost?
Roberto Ierusalimschy
10:30 coffee break
11:00 Lua's coroutines: the secret sauce in Nmap's Scripting Engine
Patrick Donnelly
11:40 intermission
11:50 Terrain-less Procedural Generation with Lua
Enrique Garcia Cota
12:30 lunch
14:00 fengari
Daurnimator
14:40 intermission
14:50 Lua in the Ceph distributed storage system
Noah Watkins
15:30 coffee break
16:00 The Titan Programming Language
Hugo Gualandi
16:40 intermission
16:50 Binding to YARA with LuaJIT
Robert Paprocki
17:30 Kong Inc Happy Hour


Tuesday, Oct 17th

9:00 registration and badge pick-up
9:30 IUP Next
Eric Wing and Chris Matzenbach
10:30 coffee break
11:00 Efficient Layer 7 Search of IP Address Space in LuaJIT/OpenResty
Robert Paprocki
11:40 intermission
11:40 lua-http
Daurnimator
12:30 lunch
14:00 Safe browsing using Lua
Lourival Neto
14:40 intermission
14:50 Measuring Lua's Performance
Enrique Garcia Cota
15:30 coffee break
16:00 To type or not to type Lua
Andre Murbach Maidl
16:40 intermission
16:50 Navigating the smart card world with Lua
William Ahern
17:30 social activities

Venue

The workshop will be held at the Kong HQ in the Financial District of San Francisco: 251 Post Street, 2nd floor, San Francisco CA 94108

Organization

The workshop is organized by Kong and the Lua team.

The organizers can be contacted at lua.workshop@gmail.com.

Sponsored by Kong

Participants

Abstracts

IUP Next slides video
Eric Wing (PlayControl Software) and Chris Matzenbach (Banco do Brasil Americas)

IUP is the long-lived, cross-platform native GUI widget library, developed at PUC-Rio, the same university as Lua. IUP's thoughtful design keep it lightweight and fast (because it uses native GUI widgets) and also make it easy to bind other languages, such as Lua. Adoption of IUP should be great, but the lack of Mac OS X support has hindered it. It's time to fix this and bring IUP into the modern age. This talk will reveal my efforts to implement 4 new backends for IUP: Mac (Cocoa), iOS (CocoaTouch), Android, and a native web browser backend (via Emscripten).

How Much Does it Cost? slides video
Roberto Ierusalimschy (PUC-Rio / Lua.org)

How much does a feature cost in a programming language? Frequently, when people propose new features for a software, the most common metric is lines of code. If a feature can be implemented in a few lines, why not add it? However, each feature has several hidden costs. Besides performance, features can have costs in documentation and testing. Some impair the conceptual integrity of the language, making it more difficult to learn. Some restrict alternative implementations. Some hinder its evolution, by narrowing unnecessarily the design space. In this talk, we will discuss these and other costs of adding features to a language, illustrating the discussion with several features already present in Lua.

The Titan Programming Language slides video
Hugo Gualandi (LabLua/PUC-Rio)

In this talk we present Titan, a new systems programming language that we are developing at LabLua to act as a sister language to Lua. Titan's design focuses on performance and is aimed at application development and as an alternative to some uses of C modules.

Efficient Layer 7 Search of IP Address Space in LuaJIT/OpenResty slides video
Robert Paprocki (Kong)

Searching Internet Protocol (IP) address space has been a long-discussed topic in the context of network-layer services, with advancements in search algorithms coming decades ago. In application-layer contexts, such searches are relegated to second-class status, commonly executing in linear time, with many assumptions made about the request context and targeted search space. In Lua/OpenResty applications in particular, existing community implementations of IP address searching typically use an unoptimized linear search pattern, presenting a CPU bottleneck in high-concurrency environments. This talk features a discussion of existing IP space search implementations, both in theory and in practice, and unveils a new model designed to execute in a highly performant nature at scale, running in logarithmic time. We demonstrate the code flow (pure LuaJIT) and discuss the performance improvements and drawbacks over existing implementations. The discussion wraps with a performance analysis of existing vs. our implementation, using real-world examples of large CIDR block lists and traffic patterns.

lua-http slides video
Daurnimator

What started as an experiment with the HTTP2 protocol has ended up being one of my more ambitious Lua projects. lua-http is a Lua library that offers http client and server functionality for both HTTP1, HTTP2 and websockets. It hopes to become the standard lua library for interacting with HTTP servers or clients. This talk will explore the lua-http API and demonstrate its use in a range of contexts.

fengari slides video
Daurnimator

fengari is the latest project to get Lua running in the browser. After running into a wall with multiple garbage collectors in lua.vm.js, fengari was born from the idea to re-use Javascript's garbage collector for a Lua VM. The core is a port of the PUC-Rio Lua 5.3 codebase to Javascript but structured to allow the JS garbage collector to analyse reachability. This talk will cover the components of fengari and how they come together to let developers write Lua for the browser just as easily as they write Javascript today.

Lua in the Ceph distributed storage system slides video
Noah Watkins (UC Santa Cruz)

Ceph is a massively distributed storage system offering object, file, and block abstractions, and is widely deployed within industry, academic, and scientific contexts. Lua is used within the Ceph file system to provide a mechanism for expressing load balancing policies, and within the object storage system to define dynamic transactional interfaces. This talk will provide an overview of the use of Lua within Ceph and where we would like to expand the integration.

Terrain-less Procedural Generation with Lua slides video
Enrique Garcia Cota (Kong)

Procedural Generation is used often to generate large amounts of content from a small(ish) set of rules. In videogames it's often applied to the generation of geographical / topological data. On this talk I would like to explore how Lua's expressiveness can be leveraged to generate other kinds of data.

Measuring Lua's Performance slides video
Enrique Garcia Cota (Kong)

On this talk I would like to explore the different ways there are for measuring the performance of a piece of code in Lua. We will visit common techniques and usual pitfalls, and also how the host application and the different Lua implementations influence the results.

Binding to YARA with LuaJIT slides video
Robert Paprocki (Kong)

YARA is a tool aimed at (but not limited to) helping malware researchers to identify and classify malware samples. It offers command line tooling for developing signatures and examining samples, as well as a C API and bindings in several languages. This talk focuses on a Lua binding for YARA via LuaJIT's FFI capabilities. We will discuss the designs of the YARA API and it's performance implications in the context of LuaJIT FFI semantics, and the engineering effort needed to work around design limitations. We discuss the Lua API our library provides, and highlight performance benefits and implementation drawbacks for various environments, including OpenResty middleware/reverse proxy environments. The discussion wraps with an examination of future points of improvement in our binding library.

Lua's coroutines: the secret sauce in Nmap's Scripting Engine slides video
Patrick Donnelly (Red Hat, Inc.)

The Nmap Scripting Engine (NSE) is a powerful network security tool famous for its flexibility as well as its applicability to a broad range of network reconnaissance tasks. NSE's success is made possible by the Lua programming lanuage and its most underappreciated feature: coroutines. Through coroutines, NSE allows scripters to be blissfully ignorant of the mechanics of asynchronous network communication. This talk will cover how NSE makes this possible and some of the challenges and delights in orchestrating a symphony of scripts.

To type or not to type Lua slides video
Andre Murbach Maidl (PUCPR)

The main goal behind Typed Lua is to help Lua programmers catch bugs during the development phase. To do that we created a type system for Lua and implemented it as a type checker that programmers can use to annotate their code and run the compiler to check their programs. After type checking the generated code is pure Lua that runs on the unmodified Lua VM. During the design of Typed Lua we tried to accommodate several Lua idioms that are familiar to programmers such as the incremental evolution of tables and filters according to run-time type tags. However, some of these design decisions had impact on the usability of Typed Lua. In this talk we will reason about some of the challenges to type Lua along with their impact on the design and usability of Typed Lua. We will also discuss the relation and the migration of Typed Lua to the Titan language.

Safe browsing using Lua slides video
Lourival Neto (CUJO)

CUJO is a smart firewall device designed to protect home networks. Among other features it allows users to browse websites safely on the Internet. For this, CUJO inspects HTTP(S) traffic for filtering both user's requests and website's responses. For example, it can prevent malwares from being downloaded or inappropriate content from being displayed for children (parental controls). This feature is implemented using Lunatik, that is Lua in the Linux kernel, and bindings for Netfilter/Iptables (NFLua) and for "zero-copy" memory (Luadata). In this talk we will discuss this implementation and show results on running it on thousands of active devices.

Navigating the smart card world with Lua slides
William Ahern

An argument for why Lua is a perfect tool for dealing with the nightmare of complexity that is the smartcard world, through an introduction to libse, a nascent Lua framework for wrangling smartcard interfaces. Includes an overview of standards such as ISO-7816, CCID, PC/SC, OpenPGP Smartcard, and PKCS#11; existing solutions such as OpenSC and GnuPG; and a discussion of the interoperability challenges which have hindered the open source community from fully embracing cryptographic hardware, stunting the commodification of these products and the emergence of a richer and more secure software ecosystem.