d4rkcat / pia

Private Internet Access VPN Linux bash client
GNU General Public License v2.0
92 stars 18 forks source link

if script fails with killswitch on, network is still available #10

Open winchendonsprings opened 6 years ago

winchendonsprings commented 6 years ago

If I run the script with the -k switch on and the script crashes, the network is still available.

Shell output its


~ sudo pia -dfks 43
 [*] Connected, OpenVPN is running daemonized on PID 13277                    
 [*] Changed DNS to PIA servers.
 [*] Firewall enabled.
 [X] WARNING: New OpenVPN log entries detected:                         
     Sun May 27 21:56:50 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #23606 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:50 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #23616 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:52 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #24779 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:52 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #24780 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:52 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #24781 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:53 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #25405 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:53 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #25406 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:53 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #25407 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:53 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #25734 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:55 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #26887 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:55 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #26888 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Sun May 27 21:56:55 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #26891 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings

 [*] Restored DNS servers.
 [>] Restarting VPN...
 [>] Connecting to US_Silicon_Valley, Please wait.../usr/bin/pia: line 245: warning: command substitution: ignored null byte in input
 [X] OpenVPN exited unexpectedly. Please review log:                    
Sun May 27 21:57:04 2018 OpenVPN 2.4.5 x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Mar  4 2018
Sun May 27 21:57:04 2018 library versions: OpenSSL 1.1.0h  27 Mar 2018, LZO 2.10
Sun May 27 21:57:04 2018 TCP/UDP: Preserving recently used remote address: [AF_INET]104.156.228.101:1198
Sun May 27 21:57:04 2018 UDP link local: (not bound)
Sun May 27 21:57:04 2018 UDP link remote: [AF_INET]104.156.228.101:1198
Sun May 27 21:57:04 2018 SIGINT[hard,] received, process exiting
winchendonsprings commented 6 years ago

Still happening


~ sudo pia -dfks 45                   
 [*] Connected, OpenVPN is running daemonized on PID 1835                    
 [*] Changed DNS to PIA servers.
 [*] Firewall enabled.
 [X] WARNING: New OpenVPN log entries detected:                         
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7951 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7952 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7953 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7954 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7955 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7956 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7957 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #7958 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8061 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8062 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8064 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8065 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8066 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8091 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8092 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8093 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8094 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8182 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8183 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8198 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:36 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #8199 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:39 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #10599 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:39 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #10602 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:39 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #10603 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:39 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #10604 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:41 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #12172 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:42 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #13052 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:42 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #13035 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:42 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #13036 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:42 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #13037 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:43 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #14818 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:45 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17024 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:45 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17025 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:45 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17026 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:45 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17027 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17476 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17509 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17510 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17511 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17698 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings
     Thu Jun 14 23:46:46 2018 Authenticate/Decrypt packet error: bad packet ID (may be a replay): [ #17709 ] -- see the man page entry for --no-replay and --replay-window for more info or silence this warning with --mute-replay-warnings

 [*] Restored DNS servers.
 [>] Restarting VPN...
 [>] Connecting to US_Silicon_Valley, Please wait.../usr/bin/pia: line 245: warning: command substitution: ignored null byte in input
 [X] OpenVPN exited unexpectedly. Please review log:                    
Thu Jun 14 23:46:48 2018 OpenVPN 2.4.5 x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Mar  4 2018
Thu Jun 14 23:46:48 2018 library versions: OpenSSL 1.1.0h  27 Mar 2018, LZO 2.10
Thu Jun 14 23:46:48 2018 SIGINT[hard,] received, process exiting
winchendonsprings commented 6 years ago

I should note that this does not happen with the official PIA linux deb package.

I'm on debian testing. If there's any more log info I can provide let me know.