Commit 5610d99c authored by Thomas Guillem's avatar Thomas Guillem

libvlc: backport smb2 port specifications support

parent 007be001
Pipeline #8685 passed with stage
in 21 minutes and 30 seconds
From f52a7bb426dfd0742df5efef0ff3f7673fd66145 Mon Sep 17 00:00:00 2001
Message-Id: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From 8181eb1f5b872c51879f155318b6218f49b73171 Mon Sep 17 00:00:00 2001
Message-Id: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: Thomas Guillem <thomas@gllm.fr>
Date: Fri, 13 Apr 2018 16:15:16 +0200
Subject: [PATCH 1/6] access: add smb2 module
......@@ -19,16 +19,16 @@ allow to use Builtin NTLMSSP authentication instead of libkrb5.
contrib/src/smb2/rules.mak | 28 +
modules/MODULES_LIST | 1 +
modules/access/Makefile.am | 11 +
modules/access/smb2.c | 718 ++++++++++++++++++
modules/access/smb2.c | 712 ++++++++++++++++++
po/POTFILES.in | 1 +
8 files changed, 992 insertions(+), 1 deletion(-)
8 files changed, 986 insertions(+), 1 deletion(-)
create mode 100644 contrib/src/smb2/0001-ntlmssp-add-support-for-Anonymous-logins.patch
create mode 100644 contrib/src/smb2/SHA512SUMS
create mode 100644 contrib/src/smb2/rules.mak
create mode 100644 modules/access/smb2.c
diff --git a/configure.ac b/configure.ac
index 4909c43539..afe1ce93ae 100644
index 4909c43539..784f5518ad 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1854,7 +1854,14 @@ AS_IF([test "${SYS}" = "mingw32" -a "${enable_winstore_app}" != "yes"], [ VLC_AD
......@@ -54,7 +54,7 @@ index 4909c43539..afe1ce93ae 100644
+dnl
+dnl smb2 access support
+dnl
+PKG_ENABLE_MODULES_VLC([SMB2], [smb2], [libsmb2 >= 2.0.0], (support smb2 protocol via libsmb2), [auto])
+PKG_ENABLE_MODULES_VLC([SMB2], [smb2], [libsmb2 >= 3.0.0], (support smb2 protocol via libsmb2), [auto])
+
dnl
dnl Video4Linux 2
......@@ -361,10 +361,10 @@ index 765ceec45f..2a773029e3 100644
access_LTLIBRARIES += libtcp_plugin.la
diff --git a/modules/access/smb2.c b/modules/access/smb2.c
new file mode 100644
index 0000000000..a132c3876f
index 0000000000..05cc8594eb
--- /dev/null
+++ b/modules/access/smb2.c
@@ -0,0 +1,718 @@
@@ -0,0 +1,712 @@
+/*****************************************************************************
+ * smb2.c: SMB2 access plug-in
+ *****************************************************************************
......@@ -425,8 +425,6 @@ index 0000000000..a132c3876f
+
+#include "smb_common.h"
+
+#define CIFS_PORT 445
+
+static int Open(vlc_object_t *);
+static void Close(vlc_object_t *);
+
......@@ -949,10 +947,6 @@ index 0000000000..a132c3876f
+ if (vlc_UrlParseFixup(&sys->encoded_url, access->psz_url) != 0)
+ return VLC_ENOMEM;
+
+ if (sys->encoded_url.i_port != 0 && sys->encoded_url.i_port != CIFS_PORT)
+ goto error;
+ sys->encoded_url.i_port = 0;
+
+ sys->smb2 = smb2_init_context();
+ if (sys->smb2 == NULL)
+ {
......@@ -964,10 +958,10 @@ index 0000000000..a132c3876f
+ sys->encoded_url.psz_path = (char *) "/";
+
+ char *resolved_host = vlc_smb2_resolve(access, sys->encoded_url.psz_host,
+ CIFS_PORT);
+ sys->encoded_url.i_port);
+
+ /* smb2_* functions need a decoded url. Re compose the url from the
+ * modified sys->encoded_url (without port and with the resolved host). */
+ * modified sys->encoded_url (with the resolved host). */
+ char *url;
+ if (resolved_host != NULL)
+ {
......
From 9b03a1727b20532b7db494f3dd9eb48dac52f173 Mon Sep 17 00:00:00 2001
Message-Id: <9b03a1727b20532b7db494f3dd9eb48dac52f173.1565083097.git.thomas@gllm.fr>
In-Reply-To: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
References: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From f94921c24481e1e11fd26712e458ad0fa20b2635 Mon Sep 17 00:00:00 2001
Message-Id: <f94921c24481e1e11fd26712e458ad0fa20b2635.1565088614.git.thomas@gllm.fr>
In-Reply-To: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
References: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: =?UTF-8?q?Hugo=20Beauz=C3=A9e-Luyssen?= <hugo@beauzee.fr>
Date: Thu, 28 Mar 2019 15:23:48 +0100
Subject: [PATCH 2/6] compat: Workaround sendmsg bug on android
......@@ -49,7 +49,7 @@ index 0f42e782f8..8d69048746 100644
#else
#error sendmsg not implemented on your platform!
diff --git a/configure.ac b/configure.ac
index afe1ce93ae..c0c0b6109a 100644
index 784f5518ad..ea4c6d43f7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -365,6 +365,9 @@ AS_IF([test "$SYS" = linux],[
......
From e83f11dcb31eb5fc47bd85dca8c1f4d6ce6f4e5a Mon Sep 17 00:00:00 2001
Message-Id: <e83f11dcb31eb5fc47bd85dca8c1f4d6ce6f4e5a.1565083097.git.thomas@gllm.fr>
In-Reply-To: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
References: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From 8188b040afaef381a473bc764dc97cba26991069 Mon Sep 17 00:00:00 2001
Message-Id: <8188b040afaef381a473bc764dc97cba26991069.1565088614.git.thomas@gllm.fr>
In-Reply-To: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
References: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: Soomin Lee <bubu@mikan.io>
Date: Thu, 27 Sep 2018 18:40:39 +0200
Subject: [PATCH 3/6] libvlc: events: Add callbacks for record
......
From f31bb6bf6abf587edb9e351500ef98bb2c77e9e9 Mon Sep 17 00:00:00 2001
Message-Id: <f31bb6bf6abf587edb9e351500ef98bb2c77e9e9.1565083097.git.thomas@gllm.fr>
In-Reply-To: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
References: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From c63130ac155443677fccddf143cc2c7fc4158e4d Mon Sep 17 00:00:00 2001
Message-Id: <c63130ac155443677fccddf143cc2c7fc4158e4d.1565088614.git.thomas@gllm.fr>
In-Reply-To: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
References: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: =?UTF-8?q?Hugo=20Beauz=C3=A9e-Luyssen?= <hugo@beauzee.fr>
Date: Fri, 29 Mar 2019 10:56:26 +0100
Subject: [PATCH 4/6] network: tls: Handle errors from older kernels
......
From 888741befdcf51ee78bd16897e05df5ece74c9a6 Mon Sep 17 00:00:00 2001
Message-Id: <888741befdcf51ee78bd16897e05df5ece74c9a6.1565083097.git.thomas@gllm.fr>
In-Reply-To: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
References: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From dfb83a71d0ac1a5094afa320df647481afc5a78f Mon Sep 17 00:00:00 2001
Message-Id: <dfb83a71d0ac1a5094afa320df647481afc5a78f.1565088614.git.thomas@gllm.fr>
In-Reply-To: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
References: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: Soomin Lee <bubu@mikan.io>
Date: Mon, 1 Oct 2018 15:37:57 +0200
Subject: [PATCH 5/6] access_output: file: Add error dialog for write/open
......
From d1c0362dc7df9ae5f2c87ac860ad4fb426ac97c7 Mon Sep 17 00:00:00 2001
Message-Id: <d1c0362dc7df9ae5f2c87ac860ad4fb426ac97c7.1565083097.git.thomas@gllm.fr>
In-Reply-To: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
References: <f52a7bb426dfd0742df5efef0ff3f7673fd66145.1565083097.git.thomas@gllm.fr>
From c1f72f15b9577944850c9ba80b636275c0517bcd Mon Sep 17 00:00:00 2001
Message-Id: <c1f72f15b9577944850c9ba80b636275c0517bcd.1565088614.git.thomas@gllm.fr>
In-Reply-To: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
References: <8181eb1f5b872c51879f155318b6218f49b73171.1565088614.git.thomas@gllm.fr>
From: Soomin Lee <bubu@mikan.io>
Date: Wed, 31 Oct 2018 10:08:55 +0100
Subject: [PATCH 6/6] libvlc: media_player: Add record method
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment