Review and refactor current vpn code to lower technical debt
there are many smells in current code:
-
too many levels of indirection -
bad naming -
too many platform switches -
inconsistent interfaces (preUp / vpn_start) -
lack of tests -
wrong usage of composition/delegation -
do I need to continue?
the current classes have been hammered together across several migrations. I'll be happy to address these issues (already tried some refactors), but since most of this code hasn't been recently reviewed, I'll be happy to start with a generic review listing smells and suggesting some new class structure.
To guide this refactor, I'm happy to code some new tests. I think the Status parser can be tested separately, and having an improved e2e test can also help in ensuring that the whole functionality doesn't break (start/stop/firewall/restart)