New Windows KB5009543, KB5009566 updates break L2TP VPN connections affecting Windows 10 and 11.
When attempting to connect to a VPN, an error is shown as below:

In order to fix this issue is necessary to run a command in the command prompt as administrator.
After running the command restart the machine and try the L2TP VPN connection again.