vpnmain.cgi: Fixes bug13737 - increments the serial number to allow cert regen
- When the regeneration is carried out the existing cert, with serial number 01, is
revoked but when the new cert is created the serial number is still 01 causing error
messages about the new cert being revoked.
- This patch increments the serial number from 01 to 02 after the initial root/host
certificate set is created.
- Then when the olf cert is revoked the new one uses serial number 02 but also
automatically increments it again. So all future regenerations work without problems.
- Tested out on a physical IPFire system.
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>