[vlc-devel] [PATCH v3 07/11] smb2: don't try guest account when requested

Thomas Guillem thomas at gllm.fr
Mon Dec 21 17:54:32 UTC 2020


---
 modules/access/smb2.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/modules/access/smb2.c b/modules/access/smb2.c
index 0b7f75906a0..65c34a2bd3a 100644
--- a/modules/access/smb2.c
+++ b/modules/access/smb2.c
@@ -529,6 +529,10 @@ vlc_smb2_open_share(stream_t *access, const char *url,
     const char *share = do_enum ? "IPC$" : smb2_url->share;
     if (!username)
     {
+        /* Don't try the guest account if specifically requested by the user */
+        if (!do_enum && credential->b_interact_forced)
+            goto error;
+
         username = "Guest";
         /* A NULL password enable ntlmssp anonymous login */
         password = NULL;
-- 
2.29.2



More information about the vlc-devel mailing list