* [pbs-devel] [PATCH proxmox-backup] d/postinst: always fixup termproxy user id and for all users
@ 2020-09-01 14:50 Stefan Reiter
2020-09-01 16:02 ` [pbs-devel] applied: " Thomas Lamprecht
0 siblings, 1 reply; 2+ messages in thread
From: Stefan Reiter @ 2020-09-01 14:50 UTC (permalink / raw)
To: pbs-devel
Anyone with a PAM account and Sys.Console access could have started a
termproxy session, adapt the regex.
Always test for broken entries and run the sed expression to make sure
eventually all occurences of the broken syntax are fixed.
Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
---
debian/postinst | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/debian/postinst b/debian/postinst
index 9ab78798..adf49da6 100644
--- a/debian/postinst
+++ b/debian/postinst
@@ -15,11 +15,10 @@ case "$1" in
fi
deb-systemd-invoke $_dh_action proxmox-backup.service proxmox-backup-proxy.service >/dev/null || true
- if test -n "$2"; then
- if dpkg --compare-versions "$2" 'le' '0.8.10-1'; then
- echo "Fixing up termproxy user id in task log..."
- flock -w 30 /var/log/proxmox-backup/tasks/active.lock sed -i 's/:termproxy::root: /:termproxy::root@pam: /' /var/log/proxmox-backup/tasks/active
- fi
+ # FIXME: Remove in future version once we're sure no broken entries remain in anyone's files
+ if grep -q -e ':termproxy::[^@]\+: ' /var/log/proxmox-backup/tasks/active; then
+ echo "Fixing up termproxy user id in task log..."
+ flock -w 30 /var/log/proxmox-backup/tasks/active.lock sed -i 's/:termproxy::\([^@]\+\): /:termproxy::\1@pam: /' /var/log/proxmox-backup/tasks/active
fi
;;
--
2.20.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* [pbs-devel] applied: [PATCH proxmox-backup] d/postinst: always fixup termproxy user id and for all users
2020-09-01 14:50 [pbs-devel] [PATCH proxmox-backup] d/postinst: always fixup termproxy user id and for all users Stefan Reiter
@ 2020-09-01 16:02 ` Thomas Lamprecht
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Lamprecht @ 2020-09-01 16:02 UTC (permalink / raw)
To: Proxmox Backup Server development discussion, Stefan Reiter
On 01.09.20 16:50, Stefan Reiter wrote:
> Anyone with a PAM account and Sys.Console access could have started a
> termproxy session, adapt the regex.
>
> Always test for broken entries and run the sed expression to make sure
> eventually all occurences of the broken syntax are fixed.
>
> Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
> ---
> debian/postinst | 9 ++++-----
> 1 file changed, 4 insertions(+), 5 deletions(-)
>
>
applied, thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-09-01 16:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-01 14:50 [pbs-devel] [PATCH proxmox-backup] d/postinst: always fixup termproxy user id and for all users Stefan Reiter
2020-09-01 16:02 ` [pbs-devel] applied: " Thomas Lamprecht
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal