From cbedd7c5597b906e5de95debeced81743a21a9f1 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 8 May 2024 07:05:34 +0200 Subject: Merging debian version 2:8.1.0875-5+deb10u3. Signed-off-by: Daniel Baumann --- debian/patches/CVE-2022-0361.patch | 42 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 debian/patches/CVE-2022-0361.patch (limited to 'debian/patches/CVE-2022-0361.patch') diff --git a/debian/patches/CVE-2022-0361.patch b/debian/patches/CVE-2022-0361.patch new file mode 100644 index 0000000..d1354ed --- /dev/null +++ b/debian/patches/CVE-2022-0361.patch @@ -0,0 +1,42 @@ +From: Markus Koschany +Date: Mon, 24 Oct 2022 00:58:11 +0200 +Subject: CVE-2022-0361 + +Origin: https://github.com/vim/vim/commit/dc5490e2cbc8c16022a23b449b48c1bd0083f366 +--- + src/ex_cmds.c | 2 ++ + src/testdir/test_visual.vim | 11 +++++++++++ + 2 files changed, 13 insertions(+) + +diff --git a/src/ex_cmds.c b/src/ex_cmds.c +index 0b732c2..b18f58c 100644 +--- a/src/ex_cmds.c ++++ b/src/ex_cmds.c +@@ -1074,6 +1074,8 @@ ex_copy(linenr_T line1, linenr_T line2, linenr_T n) + } + + appended_lines_mark(n, count); ++ if (VIsual_active) ++ check_pos(curbuf, &VIsual); + + msgmore((long)count); + } +diff --git a/src/testdir/test_visual.vim b/src/testdir/test_visual.vim +index 0841952..e361f97 100644 +--- a/src/testdir/test_visual.vim ++++ b/src/testdir/test_visual.vim +@@ -417,3 +417,14 @@ func Test_visual_block_append_invalid_char() + bwipe! + endfunc + ++" CVE-2022-0361 ++func Test_visual_ex_copy_line() ++ new ++ call setline(1, ["aaa", "bbbbbbbbbxbb"]) ++ /x ++ exe "normal ggvjfxO" ++ t0 ++ normal gNU ++ bwipe! ++endfunc ++ -- cgit v1.2.3