]> git.ipfire.org Git - people/ms/ipfire-2.x.git/commit
vpnmain.cgi: Fix editing connections that are using a PSK ipsec-psk
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 28 Apr 2025 09:40:21 +0000 (11:40 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 28 Apr 2025 09:40:21 +0000 (11:40 +0200)
commit8fcb3af8153e79a898019ecb36c6103736ee891e
treea52ab037851887e7795cf3a84058ed609182adf6
parent610ed2f195d1447f8f56b9796d916edf2800661f
vpnmain.cgi: Fix editing connections that are using a PSK

This patch takes care of properly decoding the PSK if it was already
stored base64-encoded. If the connection is edited, it always will be
stored base64-encoded upon save.

It would have been nice to not send the PSK back to the browser again
(although the security benefits would have been marginal), but that
would make the code even messier than it is.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
html/cgi-bin/vpnmain.cgi