Skip to content

Releases: libbpf/libbpf-rs

v0.24.8

08 Nov 17:32
Compare
Choose a tag to compare

What's Changed

libbpf-rs

  • Added Program::attach_netfilter_with_opts for attaching to netfilter hooks

Full Changelog: v0.24.8...v0.24.8

v0.24.7

04 Nov 21:23
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Fixed handling of empty unions in BPF types

New Contributors

Full Changelog: v0.24.6...v0.24.7

v0.24.6

11 Oct 21:10
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Fixed incorrect Cargo environment variable query when used in build script context

New Contributors

  • @kxxt made their first contribution in #959

Full Changelog: v0.24.5...v0.24.6

v0.24.5

30 Sep 20:10
Compare
Choose a tag to compare

What's Changed

libbpf-rs

  • Renamed Program::get_id_by_fd to id_from_fd
    • Deprecated Program::get_id_by_fd
  • Renamed Program::get_fd_by_id to fd_from_id
    • Deprecated Program::get_fd_by_id
  • Adjusted Program::{attach_*, test_run} methods to work on shared receivers
  • Adjusted PerfBufferBuilder to work with MapCore objects

New Contributors

Full Changelog: v0.24.4...v0.24.5

v0.24.4

27 Aug 18:06
Compare
Choose a tag to compare

What's Changed

libbpf-rs

  • Added Program::fd_from_pinned_path method for restoring program descriptor from a pinned path

libbpf-cargo

  • Adjusted skeleton generation code to work around libbpf forward compatibility issue when an old system libbpf is being used instead of the vendored copy

Full Changelog: v0.24.3...v0.24.4

v0.24.3

23 Aug 17:01
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Silenced possible clippy reported warnings in generated skeleton when BPF object file does not contain any maps

Full Changelog: v0.24.2...v0.24.3

v0.24.2

15 Aug 16:17
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Fixed panic on "open" of skeleton with kconfig map

Full Changelog: v0.24.1...v0.24.2

v0.24.1

08 Aug 17:52
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Fixed missing BPF object cleanup after skeleton destruction

Full Changelog: v0.24.0...v0.24.1

v0.24.0

07 Aug 21:20
Compare
Choose a tag to compare

What's Changed

libbpf-rs

  • Split {Open,}{Map,Program} into {Open,}{Map,Program} (for shared access) and {Open,}{Map,Program}Mut (for exclusive access)
  • Added AsRawLibbpf impl for OpenObject and ObjectBuilder
  • Decoupled Map and MapHandle more and introduced MapCore trait abstracting over common functionality
  • Adjusted SkelBuilder::open method to require mutable reference to storage space for BPF object
  • Adjusted {Open,}Object::from_ptr constructor to be infallible
  • Added {Open,}Object::maps{_mut,} and {Open,}Object::progs{_mut,} for BPF map and program iteration
  • Adjusted various APIs to return/use OsStr instead of CStr or str
  • Adjusted {Open,}Program to lazily retrieve name and section
    • Changed name and section methods to return &OsStr and made constructors infallible
  • Adjusted OpenObject::name to return Option<&OsStr>
  • Removed Result return type from OpenProgram::{set_log_level,set_autoload,set_flags}
  • Added Object::name method
  • Added Copy and Clone impls for types inside btf::types module
  • Adjusted OpenMap::set_inner_map_fd to return Result
  • Adjusted ProgramInput::context_in field to be a mutable reference
  • Made inner query::Tag contents publicly accessible
  • Fixed potential memory leak in RingBufferBuilder::build
  • Removed Display implementation of various enum types

libbpf-cargo

  • Reworked generated skeletons to contain publicly accessible maps and program members, no longer requiring method calls
  • Adjusted skeleton creation logic to generate Rust types for all types available in BPF
  • Renamed module for generated Rust types from <project>_types to just types
  • Renamed generated struct_ops type to StructOps and moved it out of types module
  • Fixed Rust code generation logic to properly create Default impl for arrays of pointers

New Contributors

Full Changelog: v0.23.3...v0.24.0

v0.23.3

11 Jun 22:00
Compare
Choose a tag to compare

What's Changed

libbpf-cargo

  • Fixed generation of Default impl in presence of large padding arrays

New Contributors

Full Changelog: v0.23.2...v0.23.3