1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00
samba-mirror/source3/libsmb
Elia Geretto 34771e1931 s3:libsmb: Fix errno for failed authentication in SMBC_server_internal()
In SMBC_server_internal(), when authentication fails, the errno value is
currently hard-coded to EPERM, while it should be EACCES instead. Use the
NT_STATUS map to set the appropriate value.

This bug was found because it breaks listing printers protected by
authentication in GNOME Control Panel.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14983

Signed-off-by: Elia Geretto <elia.f.geretto@gmail.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Mar 16 19:44:18 UTC 2022 on sn-devel-184

(cherry picked from commit 70b9977a46)
2022-03-17 09:14:56 +00:00
..
ABI s3:libsmb: Use cli_credentials_set_smb_encryption() 2020-08-19 16:22:42 +00:00
async_smb.c
auth_generic.c s3:libsmb: Check return code of cli_credentials_guess() 2021-06-29 02:19:35 +00:00
cli_smb2_fnum.c s3: libsmb: Call cli_dfs_target_check() from cli_smb2_rename_send(). 2022-02-09 11:09:41 +00:00
cli_smb2_fnum.h libsmb: Use cli_ntcreate in cli_chkpath 2021-11-11 19:08:37 +00:00
cliconnect.c CVE-2016-2124: s3:libsmb: don't fallback to non spnego authentication if we require kerberos 2021-11-09 19:45:34 +00:00
clidfs.c s3: libsmb: Add cli_dfs_target_check() function. 2022-02-09 11:09:40 +00:00
clidgram.c s3: safe_string: do not include string_wrappers.h 2020-08-28 00:56:34 +00:00
clidgram.h
clientgen.c s3/libsmb: check for global parametric option "libsmb:client_guid" 2021-11-04 19:04:31 +00:00
clierror.c libcli: Remove NT_STATUS_INACCESSIBLE_SYSTEM_SHORTCUT error code 2021-11-11 19:08:37 +00:00
clifile.c s3: libsmb: Call cli_dfs_target_check() from cli_cifs_rename_send(). 2022-02-09 11:09:41 +00:00
clifsinfo.c libsmb: Ensure that whoami parses all the data provided to it 2021-05-19 01:32:34 +00:00
clilist.c libsmb: Use async cli_smb2_list_send() in cli_list_send() 2020-11-19 02:48:40 +00:00
climessage.c s3/libsmb: clang: Fix 'Value stored to 'p' is never read' 2019-10-22 17:28:27 +00:00
clioplock.c
cliprint.c s3: safe_string: do not include string_wrappers.h 2020-08-28 00:56:34 +00:00
cliquota.c s3/libsmb: clang: Fix 'Value stored during initialization is never read' 2019-08-28 03:06:42 +00:00
clirap.c libsmb: Move cli_qfilename() to its only user in torture.c 2021-11-11 19:08:37 +00:00
clirap.h libsmb: Move cli_qfilename() to its only user in torture.c 2021-11-11 19:08:37 +00:00
clireadwrite.c libsmb: Remove "trans_oob()" macro 2021-11-11 19:08:37 +00:00
clisecdesc.c libsmb: Make cli_set_security_descriptor() async 2020-11-16 19:53:45 +00:00
clispnego.c CVE-2020-10704: lib util asn1: Add ASN.1 max tree depth 2020-05-04 02:59:31 +00:00
clistr.c libsmb: Remove clistr_pull_talloc() 2020-05-28 19:11:38 +00:00
clisymlink.c libsmb: move reparse_symlink to libcli/smb/ 2021-11-11 19:08:37 +00:00
clitrans.c
conncache.c
dsgetdcname.c dsgetdcname: Display new flags in debug output 2021-12-24 02:16:33 +00:00
dsgetdcname.h s3-dsgetdcname: add dsgetonedcname() 2021-07-14 16:49:30 +00:00
errormap_wbc.c
errormap_wbc.h
errormap.c lib: Align integer types 2020-01-19 18:29:39 +00:00
libsmb_cache.c
libsmb_compat.c s3: libsmb: Added new API smbc_readdirplus2() 2019-10-30 20:44:31 +00:00
libsmb_context.c s3:libsmb: Use cli_credentials to store traversal creds 2021-05-28 02:55:31 +00:00
libsmb_dir.c libsmbclient: Avoid a call to SMBC_errno() in SMBC_notify_ctx() 2021-08-06 17:22:30 +00:00
libsmb_file.c libsmbclient: Avoid a call to SMBC_errno() in SMBC_splice_ctx() 2021-08-06 17:22:30 +00:00
libsmb_misc.c libsmb: Make SMBC_dlist_contains return bool 2020-05-25 08:13:27 +00:00
libsmb_path.c libsmb: Use hex_byte() in urldecode_talloc() 2021-01-08 20:31:33 +00:00
libsmb_printjob.c
libsmb_server.c s3:libsmb: Fix errno for failed authentication in SMBC_server_internal() 2022-03-17 09:14:56 +00:00
libsmb_setget.c s3: libsmb: Added new API smbc_readdirplus2() 2019-10-30 20:44:31 +00:00
libsmb_stat.c s3:libsmb: Use cli_credentials to store traversal creds 2021-05-28 02:55:31 +00:00
libsmb_thread_impl.c
libsmb_thread_posix.c
libsmb_xattr.c libsmb: Avoid a cast 2022-01-18 20:22:38 +00:00
libsmb.h
namecache.c s3: libsmb: Now we only have namecache_store_sa(), rename it back to namecache_store(). 2020-09-07 13:23:44 +00:00
namequery_dc.c s3: libsmb: Rename get_sorted_dc_list_sa() -> get_sorted_dc_list(). 2020-09-15 10:09:39 +00:00
namequery.c lib: Move sockaddr_storage_to_samba_sockaddr() to lib/ 2021-01-11 13:19:32 +00:00
namequery.h lib: Move sockaddr_storage_to_samba_sockaddr() to lib/ 2021-01-11 13:19:32 +00:00
nmblib.c fix undefined-shift in put_res_rec fuzz error: ../../source3/libsmb/nmblib.c:451:4: runtime error: left shift of 65312 by 16 places cannot be represented in type 'int' 2021-10-29 20:29:26 +00:00
nmblib.h s3:libsmb: move cli_set_message() to source3/libsmb/nmblib.c 2020-02-26 19:45:36 +00:00
passchange.c s3:rpc_client: Pass remote name and socket to cli_rpc_pipe_open_with_creds() 2021-12-02 13:59:31 +00:00
proto.h s3: libsmb: Add cli_dfs_target_check() function. 2022-02-09 11:09:40 +00:00
pylibsmb.c s3:pylibsmb: improve return types (false => NULL) 2021-06-10 00:29:32 +00:00
samlogon_cache.c
samlogon_cache.h
smbclient.pc.in
smberr.c
smbsock_connect.c s3/libsmb: clang: Fix 'Assigned value is garbage or undefined' 2019-10-22 17:28:27 +00:00
trusts_util.c s3:trusts_utils: use a password length of 120 for machine accounts 2022-03-07 10:54:17 +00:00
unexpected.c
unexpected.h
wscript s3:libsmb: Use cli_credentials_set_smb_encryption() 2020-08-19 16:22:42 +00:00