falcosecurity / evolution

Evolution process of The Falco Project
Apache License 2.0
46 stars 37 forks source link

Dynamically linking `libelf` - following up from CNCF Legal Committee for license exception request #359

Closed leogr closed 5 months ago

leogr commented 5 months ago

Motivation

While reviewing our license exception request for libelf (LGPL licensed), the CNCF Legal Committee noted that libelf is currently statically linked inside the Falco binary. Instead, they recommend dynamically linking to libelf so that the library remains separable from Falco at runtime. This allows us to comply with the CNCF license policy.

This issue will track all related items to accomplish their request.

### Tasks
- [ ] https://github.com/falcosecurity/libs/pull/1666
- [ ] https://github.com/falcosecurity/falco/pull/3048
- [ ] https://github.com/falcosecurity/falco/pull/3053
LucaGuerra commented 5 months ago

I have tested the dynamic linking patches merged in master with the following configurations:

As expected, with DEB and RPM packages the libelf dependency is automatically downloaded via the OS package manager. When installing via tgz, the library needs to be installed in the system beforehand. The container images are working properly except for an issue identified in the distroless/wolfi container. I already opened a PR for it, once it's merged I think we can close this issue.

LucaGuerra commented 5 months ago

This is complete, libelf is now dynamically linked in Falco.