Print this page
NEX-14666 Need to provide SMB 2.1 Client
NEX-17187 panic in smbfs_acl_store
NEX-17231 smbfs create xattr files finds wrong file
NEX-17224 smbfs lookup EINVAL should be ENOENT
NEX-17260 SMB1 client fails to list directory after NEX-14666
Reviewed by: Evan Layton <evan.layton@nexenta.com>
Reviewed by: Matt Barden <matt.barden@nexenta.com>
Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
Reviewed by: Saso Kiselkov <saso.kiselkov@nexenta.com>
Reviewed by: Joyce McIntosh <joyce.mcintosh@nexenta.com>
and: (cleanup)
NEX-16824 SMB client connection setup rework
NEX-17232 SMB client reconnect failures
Reviewed by: Evan Layton <evan.layton@nexenta.com>
Reviewed by: Matt Barden <matt.barden@nexenta.com>
and: (improve debug)
NEX-16818 Add fksmbcl development tool
NEX-17264 SMB client test tp_smbutil_013 fails after NEX-14666
Reviewed by: Evan Layton <evan.layton@nexenta.com>
Reviewed by: Matt Barden <matt.barden@nexenta.com>
and: (fix ref leaks)
SUP-513 Unable to join AD domain (with NtlmMinSeverSec set in the registry)
Implement "Extended Session Security" and "Key Exchange" in NTLMSSP
*** 32,42 ****
* $Id: smb_lib.h,v 1.21.82.2 2005/06/02 00:55:39 lindak Exp $
*/
/*
* Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
! * Copyright 2013 Nexenta Systems, Inc. All rights reserved.
*/
#ifndef _NETSMB_SMB_LIB_H_
#define _NETSMB_SMB_LIB_H_
--- 32,42 ----
* $Id: smb_lib.h,v 1.21.82.2 2005/06/02 00:55:39 lindak Exp $
*/
/*
* Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
! * Copyright 2018 Nexenta Systems, Inc. All rights reserved.
*/
#ifndef _NETSMB_SMB_LIB_H_
#define _NETSMB_SMB_LIB_H_
*** 101,159 ****
char *ct_fullserver; /* orig. server name from cmd line */
char *ct_srvaddr_s; /* hostname or IP address of server */
struct addrinfo *ct_addrinfo; /* IP addresses of the server */
struct nb_ctx *ct_nb; /* NetBIOS info. */
char *ct_locname; /* local (machine) name */
- smb_iod_ssn_t ct_iod_ssn;
- /* smbioc_oshare_t ct_sh; XXX */
int ct_minauth;
int ct_shtype_req; /* share type wanted */
char *ct_origshare;
char *ct_home;
char *ct_rpath; /* remote file name */
! /* Connection setup SMB stuff. */
! /* Strings from the SMB negotiate response. */
! char *ct_srv_OS;
! char *ct_srv_LM;
! uint32_t ct_clnt_caps;
/* NTLM auth. stuff */
uchar_t ct_clnonce[NTLM_CHAL_SZ];
uchar_t ct_srv_chal[NTLM_CHAL_SZ];
char ct_password[SMBIOC_MAX_NAME];
-
- /* See ssp.c */
- void *ct_ssp_ctx;
- smbioc_ssn_work_t ct_work;
};
/*
* Short-hand for some of the substruct fields above
*/
#define ct_ssn ct_iod_ssn.iod_ossn
#define ct_vopt ct_iod_ssn.iod_ossn.ssn_vopt
#define ct_owner ct_iod_ssn.iod_ossn.ssn_owner
#define ct_srvaddr ct_iod_ssn.iod_ossn.ssn_srvaddr
#define ct_domain ct_iod_ssn.iod_ossn.ssn_domain
#define ct_user ct_iod_ssn.iod_ossn.ssn_user
#define ct_srvname ct_iod_ssn.iod_ossn.ssn_srvname
#define ct_authflags ct_iod_ssn.iod_authflags
#define ct_nthash ct_iod_ssn.iod_nthash
#define ct_lmhash ct_iod_ssn.iod_lmhash
! #define ct_sopt ct_work.wk_sopt
! #define ct_iods ct_work.wk_iods
! #define ct_tran_fd ct_work.wk_iods.is_tran_fd
! #define ct_hflags ct_work.wk_iods.is_hflags
! #define ct_hflags2 ct_work.wk_iods.is_hflags2
! #define ct_vcflags ct_work.wk_iods.is_vcflags
! #define ct_ssn_key ct_work.wk_iods.is_ssn_key
! #define ct_mac_seqno ct_work.wk_iods.is_next_seq
! #define ct_mackeylen ct_work.wk_iods.is_u_maclen
! #define ct_mackey ct_work.wk_iods.is_u_mackey.lp_ptr
/*
* Bits in smb_ctx_t.ct_flags
*/
--- 101,147 ----
char *ct_fullserver; /* orig. server name from cmd line */
char *ct_srvaddr_s; /* hostname or IP address of server */
struct addrinfo *ct_addrinfo; /* IP addresses of the server */
struct nb_ctx *ct_nb; /* NetBIOS info. */
char *ct_locname; /* local (machine) name */
int ct_minauth;
int ct_shtype_req; /* share type wanted */
char *ct_origshare;
char *ct_home;
char *ct_rpath; /* remote file name */
! /* See ssp.c */
! void *ct_ssp_ctx;
! smbioc_ssn_work_t ct_work;
! smb_iod_ssn_t ct_iod_ssn;
/* NTLM auth. stuff */
uchar_t ct_clnonce[NTLM_CHAL_SZ];
uchar_t ct_srv_chal[NTLM_CHAL_SZ];
char ct_password[SMBIOC_MAX_NAME];
};
/*
* Short-hand for some of the substruct fields above
*/
#define ct_ssn ct_iod_ssn.iod_ossn
#define ct_vopt ct_iod_ssn.iod_ossn.ssn_vopt
+ #define ct_minver ct_iod_ssn.iod_ossn.ssn_minver
+ #define ct_maxver ct_iod_ssn.iod_ossn.ssn_maxver
#define ct_owner ct_iod_ssn.iod_ossn.ssn_owner
#define ct_srvaddr ct_iod_ssn.iod_ossn.ssn_srvaddr
#define ct_domain ct_iod_ssn.iod_ossn.ssn_domain
#define ct_user ct_iod_ssn.iod_ossn.ssn_user
#define ct_srvname ct_iod_ssn.iod_ossn.ssn_srvname
#define ct_authflags ct_iod_ssn.iod_authflags
#define ct_nthash ct_iod_ssn.iod_nthash
#define ct_lmhash ct_iod_ssn.iod_lmhash
! #define ct_vcflags ct_work.wk_vcflags
! #define ct_ssnkey_len ct_work.wk_u_ssnkey_len
! #define ct_ssnkey_buf ct_work.wk_u_ssnkey_buf.lp_ptr
/*
* Bits in smb_ctx_t.ct_flags
*/
*** 167,188 ****
#define SMBCF_KCBAD 0x00080000 /* keychain password failed */
#define SMBCF_KCFOUND 0x00100000 /* password is from keychain */
#define SMBCF_BROWSEOK 0x00200000 /* browser dialogue may be used */
#define SMBCF_AUTHREQ 0x00400000 /* auth. dialog requested */
#define SMBCF_KCSAVE 0x00800000 /* add to keychain requested */
! #define SMBCF_XXX 0x01000000 /* mount-all, a very bad thing */
! #define SMBCF_SSNACTIVE 0x02000000 /* session setup succeeded */
! #define SMBCF_KCDOMAIN 0x04000000 /* use domain in KC lookup */
/*
* Context management
*/
int smb_ctx_init(struct smb_ctx *);
void smb_ctx_done(struct smb_ctx *);
int smb_open_driver(void);
int smb_ctx_gethandle(struct smb_ctx *);
int smb_ctx_findvc(struct smb_ctx *);
int smb_ctx_newvc(struct smb_ctx *);
--- 155,176 ----
#define SMBCF_KCBAD 0x00080000 /* keychain password failed */
#define SMBCF_KCFOUND 0x00100000 /* password is from keychain */
#define SMBCF_BROWSEOK 0x00200000 /* browser dialogue may be used */
#define SMBCF_AUTHREQ 0x00400000 /* auth. dialog requested */
#define SMBCF_KCSAVE 0x00800000 /* add to keychain requested */
! #define SMBCF_KCDOMAIN 0x01000000 /* use domain in KC lookup */
/*
* Context management
*/
int smb_ctx_init(struct smb_ctx *);
void smb_ctx_done(struct smb_ctx *);
int smb_open_driver(void);
+ int nsmb_ioctl(int, int, void *);
+ int nsmb_close(int);
int smb_ctx_gethandle(struct smb_ctx *);
int smb_ctx_findvc(struct smb_ctx *);
int smb_ctx_newvc(struct smb_ctx *);
*** 206,215 ****
--- 194,206 ----
*/
int smb_open_rcfile(char *);
void smb_close_rcfile(void);
+ int smb_cf_minauth_from_str(char *);
+ int smb_cf_version_from_str(char *);
+
void smb_simplecrypt(char *dst, const char *src);
int smb_simpledecrypt(char *dst, const char *src);
int nls_setrecode(const char *, const char *);
int nls_setlocale(const char *);