| 1 |
#[cfg(feature = "Win32_Foundation")] |
| 2 |
::windows_targets::link!("netapi32.dll" "system" #[doc = "Required features: `\"Win32_Foundation\"`"] fn Netbios(pncb : *mut NCB) -> u8); |
| 3 |
pub const ALL_TRANSPORTS: ::windows_sys::core::PCSTR = ::windows_sys::core::s!("M\u{0}\u{0}\u{0}"); |
| 4 |
pub const ASYNCH: u32 = 128u32; |
| 5 |
pub const CALL_PENDING: u32 = 2u32; |
| 6 |
pub const DEREGISTERED: u32 = 5u32; |
| 7 |
pub const DUPLICATE: u32 = 6u32; |
| 8 |
pub const DUPLICATE_DEREG: u32 = 7u32; |
| 9 |
pub const GROUP_NAME: u32 = 128u32; |
| 10 |
pub const HANGUP_COMPLETE: u32 = 5u32; |
| 11 |
pub const HANGUP_PENDING: u32 = 4u32; |
| 12 |
pub const LISTEN_OUTSTANDING: u32 = 1u32; |
| 13 |
pub const MAX_LANA: u32 = 254u32; |
| 14 |
pub const MS_NBF: ::windows_sys::core::PCSTR = ::windows_sys::core::s!("MNBF"); |
| 15 |
pub const NAME_FLAGS_MASK: u32 = 135u32; |
| 16 |
pub const NCBACTION: u32 = 119u32; |
| 17 |
pub const NCBADDGRNAME: u32 = 54u32; |
| 18 |
pub const NCBADDNAME: u32 = 48u32; |
| 19 |
pub const NCBASTAT: u32 = 51u32; |
| 20 |
pub const NCBCALL: u32 = 16u32; |
| 21 |
pub const NCBCANCEL: u32 = 53u32; |
| 22 |
pub const NCBCHAINSEND: u32 = 23u32; |
| 23 |
pub const NCBCHAINSENDNA: u32 = 114u32; |
| 24 |
pub const NCBDELNAME: u32 = 49u32; |
| 25 |
pub const NCBDGRECV: u32 = 33u32; |
| 26 |
pub const NCBDGRECVBC: u32 = 35u32; |
| 27 |
pub const NCBDGSEND: u32 = 32u32; |
| 28 |
pub const NCBDGSENDBC: u32 = 34u32; |
| 29 |
pub const NCBENUM: u32 = 55u32; |
| 30 |
pub const NCBFINDNAME: u32 = 120u32; |
| 31 |
pub const NCBHANGUP: u32 = 18u32; |
| 32 |
pub const NCBLANSTALERT: u32 = 115u32; |
| 33 |
pub const NCBLISTEN: u32 = 17u32; |
| 34 |
pub const NCBNAMSZ: u32 = 16u32; |
| 35 |
pub const NCBRECV: u32 = 21u32; |
| 36 |
pub const NCBRECVANY: u32 = 22u32; |
| 37 |
pub const NCBRESET: u32 = 50u32; |
| 38 |
pub const NCBSEND: u32 = 20u32; |
| 39 |
pub const NCBSENDNA: u32 = 113u32; |
| 40 |
pub const NCBSSTAT: u32 = 52u32; |
| 41 |
pub const NCBTRACE: u32 = 121u32; |
| 42 |
pub const NCBUNLINK: u32 = 112u32; |
| 43 |
pub const NRC_ACTSES: u32 = 15u32; |
| 44 |
pub const NRC_BADDR: u32 = 7u32; |
| 45 |
pub const NRC_BRIDGE: u32 = 35u32; |
| 46 |
pub const NRC_BUFLEN: u32 = 1u32; |
| 47 |
pub const NRC_CANCEL: u32 = 38u32; |
| 48 |
pub const NRC_CANOCCR: u32 = 36u32; |
| 49 |
pub const NRC_CMDCAN: u32 = 11u32; |
| 50 |
pub const NRC_CMDTMO: u32 = 5u32; |
| 51 |
pub const NRC_DUPENV: u32 = 48u32; |
| 52 |
pub const NRC_DUPNAME: u32 = 13u32; |
| 53 |
pub const NRC_ENVNOTDEF: u32 = 52u32; |
| 54 |
pub const NRC_GOODRET: u32 = 0u32; |
| 55 |
pub const NRC_IFBUSY: u32 = 33u32; |
| 56 |
pub const NRC_ILLCMD: u32 = 3u32; |
| 57 |
pub const NRC_ILLNN: u32 = 19u32; |
| 58 |
pub const NRC_INCOMP: u32 = 6u32; |
| 59 |
pub const NRC_INUSE: u32 = 22u32; |
| 60 |
pub const NRC_INVADDRESS: u32 = 57u32; |
| 61 |
pub const NRC_INVDDID: u32 = 59u32; |
| 62 |
pub const NRC_LOCKFAIL: u32 = 60u32; |
| 63 |
pub const NRC_LOCTFUL: u32 = 17u32; |
| 64 |
pub const NRC_MAXAPPS: u32 = 54u32; |
| 65 |
pub const NRC_NAMCONF: u32 = 25u32; |
| 66 |
pub const NRC_NAMERR: u32 = 23u32; |
| 67 |
pub const NRC_NAMTFUL: u32 = 14u32; |
| 68 |
pub const NRC_NOCALL: u32 = 20u32; |
| 69 |
pub const NRC_NORES: u32 = 9u32; |
| 70 |
pub const NRC_NORESOURCES: u32 = 56u32; |
| 71 |
pub const NRC_NOSAPS: u32 = 55u32; |
| 72 |
pub const NRC_NOWILD: u32 = 21u32; |
| 73 |
pub const NRC_OPENERR: u32 = 63u32; |
| 74 |
pub const NRC_OSRESNOTAV: u32 = 53u32; |
| 75 |
pub const NRC_PENDING: u32 = 255u32; |
| 76 |
pub const NRC_REMTFUL: u32 = 18u32; |
| 77 |
pub const NRC_SABORT: u32 = 24u32; |
| 78 |
pub const NRC_SCLOSED: u32 = 10u32; |
| 79 |
pub const NRC_SNUMOUT: u32 = 8u32; |
| 80 |
pub const NRC_SYSTEM: u32 = 64u32; |
| 81 |
pub const NRC_TOOMANY: u32 = 34u32; |
| 82 |
pub const REGISTERED: u32 = 4u32; |
| 83 |
pub const REGISTERING: u32 = 0u32; |
| 84 |
pub const SESSION_ABORTED: u32 = 6u32; |
| 85 |
pub const SESSION_ESTABLISHED: u32 = 3u32; |
| 86 |
pub const UNIQUE_NAME: u32 = 0u32; |
| 87 |
#[repr(C)] |
| 88 |
pub struct ACTION_HEADER { |
| 89 |
pub transport_id: u32, |
| 90 |
pub action_code: u16, |
| 91 |
pub reserved: u16, |
| 92 |
} |
| 93 |
impl ::core::marker::Copy for ACTION_HEADER {} |
| 94 |
impl ::core::clone::Clone for ACTION_HEADER { |
| 95 |
fn clone(&self) -> Self { |
| 96 |
*self |
| 97 |
} |
| 98 |
} |
| 99 |
#[repr(C)] |
| 100 |
pub struct ADAPTER_STATUS { |
| 101 |
pub adapter_address: [u8; 6], |
| 102 |
pub rev_major: u8, |
| 103 |
pub reserved0: u8, |
| 104 |
pub adapter_type: u8, |
| 105 |
pub rev_minor: u8, |
| 106 |
pub duration: u16, |
| 107 |
pub frmr_recv: u16, |
| 108 |
pub frmr_xmit: u16, |
| 109 |
pub iframe_recv_err: u16, |
| 110 |
pub xmit_aborts: u16, |
| 111 |
pub xmit_success: u32, |
| 112 |
pub recv_success: u32, |
| 113 |
pub iframe_xmit_err: u16, |
| 114 |
pub recv_buff_unavail: u16, |
| 115 |
pub t1_timeouts: u16, |
| 116 |
pub ti_timeouts: u16, |
| 117 |
pub reserved1: u32, |
| 118 |
pub free_ncbs: u16, |
| 119 |
pub max_cfg_ncbs: u16, |
| 120 |
pub max_ncbs: u16, |
| 121 |
pub xmit_buf_unavail: u16, |
| 122 |
pub max_dgram_size: u16, |
| 123 |
pub pending_sess: u16, |
| 124 |
pub max_cfg_sess: u16, |
| 125 |
pub max_sess: u16, |
| 126 |
pub max_sess_pkt_size: u16, |
| 127 |
pub name_count: u16, |
| 128 |
} |
| 129 |
impl ::core::marker::Copy for ADAPTER_STATUS {} |
| 130 |
impl ::core::clone::Clone for ADAPTER_STATUS { |
| 131 |
fn clone(&self) -> Self { |
| 132 |
*self |
| 133 |
} |
| 134 |
} |
| 135 |
#[repr(C)] |
| 136 |
pub struct FIND_NAME_BUFFER { |
| 137 |
pub length: u8, |
| 138 |
pub access_control: u8, |
| 139 |
pub frame_control: u8, |
| 140 |
pub destination_addr: [u8; 6], |
| 141 |
pub source_addr: [u8; 6], |
| 142 |
pub routing_info: [u8; 18], |
| 143 |
} |
| 144 |
impl ::core::marker::Copy for FIND_NAME_BUFFER {} |
| 145 |
impl ::core::clone::Clone for FIND_NAME_BUFFER { |
| 146 |
fn clone(&self) -> Self { |
| 147 |
*self |
| 148 |
} |
| 149 |
} |
| 150 |
#[repr(C)] |
| 151 |
pub struct FIND_NAME_HEADER { |
| 152 |
pub node_count: u16, |
| 153 |
pub reserved: u8, |
| 154 |
pub unique_group: u8, |
| 155 |
} |
| 156 |
impl ::core::marker::Copy for FIND_NAME_HEADER {} |
| 157 |
impl ::core::clone::Clone for FIND_NAME_HEADER { |
| 158 |
fn clone(&self) -> Self { |
| 159 |
*self |
| 160 |
} |
| 161 |
} |
| 162 |
#[repr(C)] |
| 163 |
pub struct LANA_ENUM { |
| 164 |
pub length: u8, |
| 165 |
pub lana: [u8; 255], |
| 166 |
} |
| 167 |
impl ::core::marker::Copy for LANA_ENUM {} |
| 168 |
impl ::core::clone::Clone for LANA_ENUM { |
| 169 |
fn clone(&self) -> Self { |
| 170 |
*self |
| 171 |
} |
| 172 |
} |
| 173 |
#[repr(C)] |
| 174 |
pub struct NAME_BUFFER { |
| 175 |
pub name: [u8; 16], |
| 176 |
pub name_num: u8, |
| 177 |
pub name_flags: u8, |
| 178 |
} |
| 179 |
impl ::core::marker::Copy for NAME_BUFFER {} |
| 180 |
impl ::core::clone::Clone for NAME_BUFFER { |
| 181 |
fn clone(&self) -> Self { |
| 182 |
*self |
| 183 |
} |
| 184 |
} |
| 185 |
#[repr(C)] |
| 186 |
#[doc = "Required features: `\"Win32_Foundation\"`"] |
| 187 |
#[cfg(any(target_arch = "aarch64", target_arch = "x86_64"))] |
| 188 |
#[cfg(feature = "Win32_Foundation")] |
| 189 |
pub struct NCB { |
| 190 |
pub ncb_command: u8, |
| 191 |
pub ncb_retcode: u8, |
| 192 |
pub ncb_lsn: u8, |
| 193 |
pub ncb_num: u8, |
| 194 |
pub ncb_buffer: *mut u8, |
| 195 |
pub ncb_length: u16, |
| 196 |
pub ncb_callname: [u8; 16], |
| 197 |
pub ncb_name: [u8; 16], |
| 198 |
pub ncb_rto: u8, |
| 199 |
pub ncb_sto: u8, |
| 200 |
pub ncb_post: isize, |
| 201 |
pub ncb_lana_num: u8, |
| 202 |
pub ncb_cmd_cplt: u8, |
| 203 |
pub ncb_reserve: [u8; 18], |
| 204 |
pub ncb_event: super::super::Foundation::HANDLE, |
| 205 |
} |
| 206 |
#[cfg(any(target_arch = "aarch64", target_arch = "x86_64"))] |
| 207 |
#[cfg(feature = "Win32_Foundation")] |
| 208 |
impl ::core::marker::Copy for NCB {} |
| 209 |
#[cfg(any(target_arch = "aarch64", target_arch = "x86_64"))] |
| 210 |
#[cfg(feature = "Win32_Foundation")] |
| 211 |
impl ::core::clone::Clone for NCB { |
| 212 |
fn clone(&self) -> Self { |
| 213 |
*self |
| 214 |
} |
| 215 |
} |
| 216 |
#[repr(C)] |
| 217 |
#[doc = "Required features: `\"Win32_Foundation\"`"] |
| 218 |
#[cfg(target_arch = "x86")] |
| 219 |
#[cfg(feature = "Win32_Foundation")] |
| 220 |
pub struct NCB { |
| 221 |
pub ncb_command: u8, |
| 222 |
pub ncb_retcode: u8, |
| 223 |
pub ncb_lsn: u8, |
| 224 |
pub ncb_num: u8, |
| 225 |
pub ncb_buffer: *mut u8, |
| 226 |
pub ncb_length: u16, |
| 227 |
pub ncb_callname: [u8; 16], |
| 228 |
pub ncb_name: [u8; 16], |
| 229 |
pub ncb_rto: u8, |
| 230 |
pub ncb_sto: u8, |
| 231 |
pub ncb_post: isize, |
| 232 |
pub ncb_lana_num: u8, |
| 233 |
pub ncb_cmd_cplt: u8, |
| 234 |
pub ncb_reserve: [u8; 10], |
| 235 |
pub ncb_event: super::super::Foundation::HANDLE, |
| 236 |
} |
| 237 |
#[cfg(target_arch = "x86")] |
| 238 |
#[cfg(feature = "Win32_Foundation")] |
| 239 |
impl ::core::marker::Copy for NCB {} |
| 240 |
#[cfg(target_arch = "x86")] |
| 241 |
#[cfg(feature = "Win32_Foundation")] |
| 242 |
impl ::core::clone::Clone for NCB { |
| 243 |
fn clone(&self) -> Self { |
| 244 |
*self |
| 245 |
} |
| 246 |
} |
| 247 |
#[repr(C)] |
| 248 |
pub struct SESSION_BUFFER { |
| 249 |
pub lsn: u8, |
| 250 |
pub state: u8, |
| 251 |
pub local_name: [u8; 16], |
| 252 |
pub remote_name: [u8; 16], |
| 253 |
pub rcvs_outstanding: u8, |
| 254 |
pub sends_outstanding: u8, |
| 255 |
} |
| 256 |
impl ::core::marker::Copy for SESSION_BUFFER {} |
| 257 |
impl ::core::clone::Clone for SESSION_BUFFER { |
| 258 |
fn clone(&self) -> Self { |
| 259 |
*self |
| 260 |
} |
| 261 |
} |
| 262 |
#[repr(C)] |
| 263 |
pub struct SESSION_HEADER { |
| 264 |
pub sess_name: u8, |
| 265 |
pub num_sess: u8, |
| 266 |
pub rcv_dg_outstanding: u8, |
| 267 |
pub rcv_any_outstanding: u8, |
| 268 |
} |
| 269 |
impl ::core::marker::Copy for SESSION_HEADER {} |
| 270 |
impl ::core::clone::Clone for SESSION_HEADER { |
| 271 |
fn clone(&self) -> Self { |
| 272 |
*self |
| 273 |
} |
| 274 |
} |