diff --git a/CHANGELOG.md b/CHANGELOG.md index de01c2f7f0..5b9525fef2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -26,6 +26,8 @@ This project adheres to [Semantic Versioning](https://semver.org/). ([#1841](https://github.com/nix-rust/nix/pull/1841)) - Added `eaccess()` on FreeBSD, DragonFly and Linux (glibc and musl). ([#1842](https://github.com/nix-rust/nix/pull/1842)) +- Added `SockProtocol::Raw = libc::IPPROTO_RAW` for raw sockets + ([#1848](https://github.com/nix-rust/nix/pull/1848)) ### Changed diff --git a/src/sys/socket/mod.rs b/src/sys/socket/mod.rs index 04a6f937a4..31780e8d84 100644 --- a/src/sys/socket/mod.rs +++ b/src/sys/socket/mod.rs @@ -118,6 +118,8 @@ pub enum SockProtocol { Tcp = libc::IPPROTO_TCP, /// UDP protocol ([ip(7)](https://man7.org/linux/man-pages/man7/ip.7.html)) Udp = libc::IPPROTO_UDP, + /// Raw sockets ([raw(7)](https://man7.org/linux/man-pages/man7/raw.7.html)) + Raw = libc::IPPROTO_RAW, /// Allows applications and other KEXTs to be notified when certain kernel events occur /// ([ref](https://developer.apple.com/library/content/documentation/Darwin/Conceptual/NKEConceptual/control/control.html)) #[cfg(any(target_os = "ios", target_os = "macos"))]