]> git.ipfire.org Git - people/ms/ipfire-2.x.git/commit
update.sh: Core 194 - increment ipsec serial file if x509 set exists
authorAdolf Belka <adolf.belka@ipfire.org>
Tue, 29 Apr 2025 10:10:49 +0000 (12:10 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 29 Apr 2025 15:22:08 +0000 (15:22 +0000)
commitcc6e5188fa3f8ffaeb52f644e411195a7cfa12b8
treecf2348f91c1f5a17ab561cfbd62b05bd7a48b05f
parent73a2afbcf5b923c4b56637227d5621f7800d4d62
update.sh: Core 194 - increment ipsec serial file if x509 set exists

- This is related to the fix patch set for bug13737. That patch set works with no problems
   if the root/host x509 set is created for the first time with that patch set merged.
   However if the x509 is already created previously then the contents of serial will
   still be 01 instead of 02.
- This patch checks if the hostcert.pm file exists and that the index.txt file is empty,
   and then increments the serial content from 01 to 02. This means that when the x509
   is regenerated the system will not complain that 01 cannot be used as it has already
   been revoked but will use 02 for the new host and everything works fine after that.

Fixes: bug13737
Tested-by: Adolf Belka <adolf.belka@ipfire.org>
Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
config/rootfiles/core/194/update.sh