Merge ~michal-maloszewski99/ubuntu/+source/samba:samba-tool-usrpassword-lunar-fix into ubuntu/+source/samba:ubuntu/lunar-devel

Proposed by Michał Małoszewski
Status: Merged
Approved by: git-ubuntu bot
Approved revision: not available
Merge reported by: Robie Basak
Merged at revision: 87a62cd16afe9d76800044026fe550a859f5a3bc
Proposed branch: ~michal-maloszewski99/ubuntu/+source/samba:samba-tool-usrpassword-lunar-fix
Merge into: ubuntu/+source/samba:ubuntu/lunar-devel
Diff against target: 57 lines (+35/-0)
3 files modified
debian/changelog (+9/-0)
debian/patches/issue-when-updating-old-passwd-containing-regex-metachars.patch (+25/-0)
debian/patches/series (+1/-0)
Reviewer Review Type Date Requested Status
git-ubuntu bot Approve
Simon Quigley (community) Approve
Canonical Server Reporter Pending
Review via email: mp+449096@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Michał Małoszewski (michal-maloszewski99) wrote :
Revision history for this message
Michał Małoszewski (michal-maloszewski99) wrote :
Revision history for this message
Michał Małoszewski (michal-maloszewski99) wrote :

It can be reviewed :)

Revision history for this message
Simon Quigley (tsimonq2) wrote :

I strongly dislike your choice of patch name (quite long). Sponsoring anyway, thanks. :)

review: Approve
Revision history for this message
git-ubuntu bot (git-ubuntu-bot) wrote :

Approvers: tsimonq2, michal-maloszewski99
Uploaders: tsimonq2
MP auto-approved

review: Approve
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

This is part of https://launchpad.net/ubuntu/+source/samba/2:4.17.7+dfsg-1ubuntu2.3, uploaded by the security team.

Update scan failed

At least one of the branches involved have failed to scan. You can manually schedule a rescan if required.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/debian/changelog b/debian/changelog
index 17631d3..7418f70 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
1samba (2:4.17.7+dfsg-1ubuntu2.2) lunar; urgency=medium
2
3 * d/p/issue-when-updating-old-passwd-containing-regex-metachars.patch:
4 Add changes to fix uncaught exception when updating old password
5 containing regex metacharacters by simplifying samba-tool password
6 redaction (LP: #2002949).
7
8 -- Michal Maloszewski <michal.maloszewski@canonical.com> Sun, 20 Aug 2023 13:57:29 +0200
9
1samba (2:4.17.7+dfsg-1ubuntu2.1) lunar; urgency=medium10samba (2:4.17.7+dfsg-1ubuntu2.1) lunar; urgency=medium
211
3 * d/control: adjust breaks/replaces for file move that Debian did in12 * d/control: adjust breaks/replaces for file move that Debian did in
diff --git a/debian/patches/issue-when-updating-old-passwd-containing-regex-metachars.patch b/debian/patches/issue-when-updating-old-passwd-containing-regex-metachars.patch
4new file mode 10064413new file mode 100644
index 0000000..3375da0
--- /dev/null
+++ b/debian/patches/issue-when-updating-old-passwd-containing-regex-metachars.patch
@@ -0,0 +1,25 @@
1Description: Fix samba to allow updating old password
2 The patch here is one line long. It is created from the
3 'suggested fix' in the reported bug in Ubuntu:
4 https://bugs.launchpad.net/ubuntu/+source/samba/+bug/2002949
5 The trick is to replace '(opt_str, secret_data)' with re.escape that
6 are used to escape any special characters in 'opt_str' and
7 'secret_data', ensuring that they are treated as literal characters in
8 the regex pattern.
9Origin: other, https://bugs.launchpad.net/ubuntu/+source/samba/+bug/2002949
10Bug: https://bugzilla.samba.org/show_bug.cgi?id=15289
11Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/samba/+bug/2002949
12Last-Update: 2023-08-21
13---
14This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
15--- a/python/samba/getopt.py
16+++ b/python/samba/getopt.py
17@@ -198,7 +198,7 @@
18 # [= ] -> The option and the secret data might be separated by space
19 # or equal sign.
20 # [ ]*.* -> After the secret data might be one, many or no space.
21- pass_opt_re_str = "(.*[ ]+)(%s[= ]%s)([ ]*.*)" % (opt_str, secret_data)
22+ pass_opt_re_str = "(.*[ ]+)(%s[= ]%s)([ ]*.*)" % (re.escape(opt_str), re.escape(secret_data))
23 pass_opt_re = re.compile(pass_opt_re_str)
24 # Get current proctitle.
25 cur_proctitle = setproctitle.getproctitle()
diff --git a/debian/patches/series b/debian/patches/series
index c2268c6..4829811 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -47,3 +47,4 @@ CVE-2023-34968-09.patch
47CVE-2023-34968-10.patch47CVE-2023-34968-10.patch
48CVE-2023-34968-11.patch48CVE-2023-34968-11.patch
49secure-channel-faulty-kb5028166.patch49secure-channel-faulty-kb5028166.patch
50issue-when-updating-old-passwd-containing-regex-metachars.patch

Subscribers

People subscribed via source and target branches