![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
github.com/natfaulk/vpn-exec-mon
I needed a program to run behind a VPN on a linux machine. However, the VPN would intermittently go down and the program stop. It is a pain to constantly check if the VPN is still up and then rerun the program.
This fairly simple program restarts the VPN when necessary, as well as starting the executable whenever it stops.
If the VPN is connected, local network addresses should be unreachable.
In my particular circumstances, I know that 1.1.1.1 is unreachable without a VPN - the powers that be have decided to block external DNS quries for some reason, therefore it is a good test to check for general internet connectivity.
There are probably many edge cases that are not covered, but it works pretty well for my purposes. It could probably have easily been implemented using a simple bash / python script, but Go is pretty pleasant to write.
Only tested on Linux, possibly works on OSX, would need significant rewrites to work on Windows.
In the scripts directory, two scripts are needed: vpnstart.sh
and vpnend.sh
. These start and stop the VPN.
Add a .env file with the following parameters:
LOCAL_ADDR=xxx.xxx.xxx.xxx
This is a local network address that should only be accessible when VPN disconnected.
REMOTE_ADDR=xxx.xxx.xxx.xxx
This is a remote address that should only be accessible when the VPN is connected. Either an address that is blocked by the network normally, or an address on the remote network. i.e wireguard often uses 10.7.0.0/24
for the virtual network, with 10.7.0.1
being the remote host.
Finally run ./vpn-exec-mon myprogram arg1 arg2 etc...
where the arguements for vpn-exec-mon are the program name followed by the arguements. One may need to run this as root (i.e. sudo ./vpn-exec-mon) depending on whether the vpn scripts require root access - which is not ideal but should be possible to find ways around this.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.