summaryrefslogtreecommitdiffstats
path: root/sys/netsmb
diff options
context:
space:
mode:
authorbp <bp@FreeBSD.org>2002-04-17 03:14:28 +0000
committerbp <bp@FreeBSD.org>2002-04-17 03:14:28 +0000
commit96ac6411fa83e21a9b784642d7c65452c001a57d (patch)
tree80d53bda8bc7a14e561b2d252bb17aa69f64b46a /sys/netsmb
parentd45a77858492de9406c19b10d63e68442042e7d2 (diff)
downloadFreeBSD-src-96ac6411fa83e21a9b784642d7c65452c001a57d.zip
FreeBSD-src-96ac6411fa83e21a9b784642d7c65452c001a57d.tar.gz
Recongnize more error codes returned by W2K servers.
MFC after: 4 days
Diffstat (limited to 'sys/netsmb')
-rw-r--r--sys/netsmb/smb.h6
-rw-r--r--sys/netsmb/smb_subr.c9
2 files changed, 14 insertions, 1 deletions
diff --git a/sys/netsmb/smb.h b/sys/netsmb/smb.h
index d6e7442..6ea128b 100644
--- a/sys/netsmb/smb.h
+++ b/sys/netsmb/smb.h
@@ -324,6 +324,7 @@ enum smb_dialects {
#define ERRbadshare 32 /* Share mode can't be granted */
#define ERRlock 33 /* A lock request conflicts with existing lock */
#define ERRfilexists 80 /* The file named in the request already exists */
+#define ERRquota 112 /* W2K returns this if quota space exceeds */
/*
* Error codes for the ERRSRV class
@@ -353,6 +354,11 @@ enum smb_dialects {
#define ERRusempx 250 /* Temporarily unable to support Raw, use MPX mode */
#define ERRusestd 251 /* Temporarily unable to support Raw, use standard r/w */
#define ERRcontmpx 252 /* Continue in MPX mode */
+#define ERRbadPassword 254
+#define ERRaccountExpired 2239
+#define ERRbadClient 2240 /* Cannot access the server from this workstation */
+#define ERRbadLogonTime 2241 /* Cannot access the server at this time **/
+#define ERRpasswordExpired 2242
#define ERRnosupport 65535 /* Invalid function */
/*
diff --git a/sys/netsmb/smb_subr.c b/sys/netsmb/smb_subr.c
index f4634d4..58fd43e 100644
--- a/sys/netsmb/smb_subr.c
+++ b/sys/netsmb/smb_subr.c
@@ -254,6 +254,8 @@ smb_maperror(int eclass, int eno)
return ENOTEMPTY;
case 183:
return EEXIST;
+ case ERRquota:
+ return EDQUOT;
}
break;
case ERRSRV:
@@ -261,6 +263,7 @@ smb_maperror(int eclass, int eno)
case ERRerror:
return EINVAL;
case ERRbadpw:
+ case ERRpasswordExpired:
return EAUTH;
case ERRaccess:
return EACCES;
@@ -271,8 +274,12 @@ smb_maperror(int eclass, int eno)
return EAUTH;
case 3: /* reserved and returned */
return EIO;
- case 2239: /* NT: account exists but disabled */
+ case ERRaccountExpired:
+ case ERRbadClient:
+ case ERRbadLogonTime:
return EPERM;
+ case ERRnosupport:
+ return EBADRPC;
}
break;
case ERRHRD:
OpenPOWER on IntegriCloud