ipmi
A production-oriented IPMI v2.0 RMCP+ client library (async-first + optional blocking).
This crate focuses on:
- IPMI v2.0 RMCP+ session establishment (Open Session + RAKP 1-4)
- Integrity: HMAC-SHA1-96
- Confidentiality: AES-CBC-128
- Async API (tokio, default)
- Blocking API (feature
blocking)
Note: IPMI is a large specification. This crate implements a secure and commonly supported baseline (mandatory-to-implement algorithms) and provides a solid foundation for adding more commands and cipher suites.
Install
Async API (default):
[]
= "0.1"
Blocking API without pulling tokio:
[]
= { = "0.1", = false, = ["blocking"] }
Observability (optional):
[]
= { = "0.1", = ["tracing", "metrics"] }
Quick start (async)
use ;
// You need a tokio runtime in your application to use the async client.
async
Quick start (blocking)
use ;
Typed commands
The crate exposes a typed command interface in ipmi::commands. You can execute built-in commands
directly, or implement commands::Command for custom commands:
use GetDeviceId;
let device_id = client.execute.await?;
let device_id = blocking_client.execute?;
Security notes
- Password / KG are stored in memory only for the duration of session establishment and are zeroized on drop.
- Session keys are zeroized when the client is dropped.
- The client verifies integrity checks (HMAC) before decrypting payloads.
- The library avoids
unwrap()/expect()in production code.
Feature support
- Transport: UDP/623 (LAN)
- Session: RMCP+ / RAKP (IPMI v2.0)
- Commands:
Get Device ID(netfn0x06, cmd0x01)Get Self Test Results(netfn0x06, cmd0x04)Get System GUID(netfn0x06, cmd0x37)Get Chassis Status(netfn0x00, cmd0x01)Chassis Control(netfn0x00, cmd0x02)Get Channel Authentication Capabilities(netfn0x06, cmd0x38)Close Session(netfn0x06, cmd0x3C)send_raw()for arbitrary commands