fix set rights in install and a .conf a import Tunnel Filedialog Part 1 /home when open
This commit is contained in:
@ -184,7 +184,7 @@ class ImportTunnel:
|
||||
filepath = filedialog.askopenfilename(initialdir=Path('/home/'), title='Select Wireguard config '
|
||||
'File',
|
||||
filetypes=[('WG config files', '*.conf')], )
|
||||
os.chmod(filepath, 0o600)
|
||||
|
||||
with open(filepath, 'r') as file:
|
||||
read = file.read()
|
||||
path_split = filepath.split('/')
|
||||
@ -224,7 +224,7 @@ class ImportTunnel:
|
||||
ShowAddress.init_and_report(self, data)
|
||||
ShowAddress.show_data(self)
|
||||
check_call(['nmcli', 'con', 'mod', self.a, 'connection.autoconnect', 'no'])
|
||||
|
||||
os.chmod(str(wg_read), 0o600)
|
||||
if 'PrivateKey = ' not in read:
|
||||
msg_window()
|
||||
except EOFError:
|
||||
|
Reference in New Issue
Block a user