Skip to main content

smb_server_proto_smb1/
lib.rs

1//! SMB1 wire structures ([MS-SMB] extensions over [MS-CIFS]).
2//!
3//! Every module corresponds to a section of the specification:
4//!
5//! | Module | Spec coverage |
6//! |---|---|
7//! | [`consts`]  | command opcodes ([MS-CIFS] §2.2.2, extended by [MS-SMB]) |
8//! | [`header`]  | SMB header ([MS-SMB] §2.2.3.1) and response/AndX assembly |
9//! | [`negotiate`] | [MS-SMB] §2.2.4.5 — `SMB_COM_NEGOTIATE` (0x72) |
10//! | [`session_setup`] | [MS-SMB] §2.2.4.6 — `SMB_COM_SESSION_SETUP_ANDX` (0x73) |
11//! | [`tree_connect`] | [MS-SMB] §2.2.4.7 — `SMB_COM_TREE_CONNECT_ANDX` (0x75) / disconnect |
12//! | [`create`] | [MS-SMB] §2.2.4.9 — `SMB_COM_NT_CREATE_ANDX` (0xA2) |
13//! | [`rw`] | `READ_ANDX` / `WRITE_ANDX` ([MS-CIFS] §2.2.4.x, extended by [MS-SMB]) |
14//! | [`trans2`] | [MS-SMB] §2.2.6 — TRANSACTION2 subcommand envelope + FIND_* (§2.2.6.1/2), QUERY_FS (§2.2.6.3), QUERY/SET PATH/FILE (§2.2.6.5–8); information levels per §2.2.8 |
15//! | [`legacy`] | Core/LANMAN-era commands: MKDIR/RMDIR/CHECKDIR, DELETE, RENAME, QUERY/SET_INFORMATION ([MS-CIFS]) |
16//! | [`misc`] | ECHO, LOGOFF_ANDX, QUERY_INFORMATION_DISK, PROCESS_EXIT |
17
18#![forbid(unsafe_code)]
19#![deny(missing_docs)]
20#![warn(missing_debug_implementations)]
21
22pub mod consts;
23pub mod create;
24pub mod find;
25pub mod header;
26pub mod legacy;
27pub mod misc;
28pub mod negotiate;
29pub mod query;
30pub mod rw;
31pub mod session_setup;
32pub mod trans2;
33pub mod tree_connect;
34
35pub use header::{parse_header, Header, RespBody};
36pub use trans2::find_level;