Blame SOURCES/0001-patch-8.1.1365-source-command-doesn-t-check-for-the-.patch

2961da
diff -up vim80/src/getchar.c.cve vim80/src/getchar.c
2961da
--- vim80/src/getchar.c.cve	2019-06-14 13:46:17.269523985 +0200
2961da
+++ vim80/src/getchar.c	2019-06-14 13:46:58.427169288 +0200
2961da
@@ -1418,6 +1418,12 @@ openscript(
2961da
 	EMSG(_(e_nesting));
2961da
 	return;
2961da
     }
2961da
+
2961da
+    // Disallow sourcing a file in the sandbox, the commands would be executed
2961da
+    // later, possibly outside of the sandbox.
2961da
+    if (check_secure())
2961da
+	return;
2961da
+
2961da
 #ifdef FEAT_EVAL
2961da
     if (ignore_script)
2961da
 	/* Not reading from script, also don't open one.  Warning message? */