linuxmuster / linuxmuster-base7

Mangement scripts for linuxmuster.net V7
GNU General Public License v3.0
13 stars 8 forks source link

linuxmuster-opnsense-reset fails #136

Closed FreeInMind closed 2 years ago

FreeInMind commented 2 years ago

OPNSense was installed new. Then linuxmuster-opnsense-reset run on server doesn't work:

root@server:~# linuxmuster-opnsense-reset 
#### linuxmuster-opnsense-reset 2022-02-07 11:29:26                       ####
Sets the firewall to the state after setup.
Custom adjustments made since then are lost.
Note: The firewall will be restartet during the process.
Do you want to continue (YES)? YES
#### Enter the current firewall root password: 
#### Please re-enter the current firewall root password: 
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
/usr/lib/python3/dist-packages/paramiko/rsakey.py:119: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/rsakey.py:99: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/dsskey.py:114: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = key.signer(hashes.SHA1())
/usr/lib/python3/dist-packages/paramiko/ecdsakey.py:184: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = self.signing_key.signer(ecdsa)
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
------------------------------------------------------------------------------
#### firewall                                                             ####
#### Reading setup data ........................................ Success! ####
#### Calculating radius secret ................................. Success! ####
#### Downloading firewall configuration:                                  ####
/usr/lib/python3/dist-packages/paramiko/rsakey.py:119: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/rsakey.py:99: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/dsskey.py:114: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = key.signer(hashes.SHA1())
/usr/lib/python3/dist-packages/paramiko/ecdsakey.py:184: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = self.signing_key.signer(ecdsa)
#### * Download finished successfully.                                    ####
#### * Backing up .............................................. Success! ####
#### * Reading current config .................................. Success! ####
#### * Reading certificates & ssh key .......................... Success! ####
#### * Creating xml configuration file ......................... Success! ####
#### * Saving api credentials .................................. Success! ####
#### Uploading firewall configuration:                                    ####
#### * Upload finished successfully.                                      ####
#### Creating web proxy sso auth config file                              ####
#### Installing extensions and rebooting firewall                         ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "chmod +x /tmp/fwsetup.sh"                                      ####
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "/tmp/fwsetup.sh"                                               ####
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
#### Waiting for opnsense to come up                                      ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Timeout!                                                             ####
root@server:~# linuxmuster-opnsense-reset 
#### linuxmuster-opnsense-reset 2022-02-07 14:11:53                       ####
Sets the firewall to the state after setup.
Custom adjustments made since then are lost.
Note: The firewall will be restartet during the process.
Do you want to continue (YES)? YES
#### Enter the current firewall root password: 
#### Please re-enter the current firewall root password: 
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
/usr/lib/python3/dist-packages/paramiko/rsakey.py:119: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/rsakey.py:99: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/dsskey.py:114: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = key.signer(hashes.SHA1())
/usr/lib/python3/dist-packages/paramiko/ecdsakey.py:184: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = self.signing_key.signer(ecdsa)
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
------------------------------------------------------------------------------
#### firewall                                                             ####
#### Reading setup data ........................................ Success! ####
#### Calculating radius secret ................................. Success! ####
#### Downloading firewall configuration:                                  ####
/usr/lib/python3/dist-packages/paramiko/rsakey.py:119: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/rsakey.py:99: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  algorithm=hashes.SHA1(),
/usr/lib/python3/dist-packages/paramiko/dsskey.py:114: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = key.signer(hashes.SHA1())
/usr/lib/python3/dist-packages/paramiko/ecdsakey.py:184: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
  signer = self.signing_key.signer(ecdsa)
#### * Download finished successfully.                                    ####
#### * Backing up .............................................. Success! ####
#### * Reading current config .................................. Success! ####
#### * Reading certificates & ssh key .......................... Success! ####
#### * Creating xml configuration file ......................... Success! ####
#### * Saving api credentials .................................. Success! ####
#### Uploading firewall configuration:                                    ####
#### * Upload finished successfully.                                      ####
#### Creating web proxy sso auth config file                              ####
#### Installing extensions and rebooting firewall                         ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "chmod +x /tmp/fwsetup.sh"                                      ####
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "/tmp/fwsetup.sh"                                               ####
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
#### Waiting for opnsense to come up                                      ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * Unable to establish a SSH connection!                              ####
#### Executing ssh command on 10.0.0.254:                                 ####
#### * -> "exit"                                                          ####
#### * SSH connection successfully established.                           ####
#### * Execution finished successfully.                                   ####
#### Deleting old keytab.                                                 ####
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 601, in urlopen
    chunked=chunked)
  File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 346, in _make_request
    self._validate_conn(conn)
  File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 852, in _validate_conn
    conn.connect()
  File "/usr/lib/python3/dist-packages/urllib3/connection.py", line 360, in connect
    _match_hostname(cert, self.assert_hostname or hostname)
  File "/usr/lib/python3/dist-packages/urllib3/connection.py", line 370, in _match_hostname
    match_hostname(cert, asserted_hostname)
  File "/usr/lib/python3.6/ssl.py", line 331, in match_hostname
    % (hostname, dnsnames[0]))
ssl.CertificateError: hostname 'firewall.linuxmuster.lan' doesn't match 'firewall.gymneureut.de'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 440, in send
    timeout=timeout
  File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 639, in urlopen
    _stacktrace=sys.exc_info()[2])
  File "/usr/lib/python3/dist-packages/urllib3/util/retry.py", line 398, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='firewall.linuxmuster.lan', port=443): Max retries exceeded with url: /api/proxysso/service/deletekeytab (Caused by SSLError(CertificateError("hostname 'firewall.linuxmuster.lan' doesn't match 'firewall.gymneureut.de'",),))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/sbin/linuxmuster-opnsense-reset", line 108, in <module>
    res = firewallApi('get', apipath)
  File "/usr/lib/linuxmuster/functions.py", line 548, in firewallApi
    req = requests.get(url, auth=(apikey, apisecret))
  File "/usr/lib/python3/dist-packages/requests/api.py", line 72, in get
    return request('get', url, params=params, **kwargs)
  File "/usr/lib/python3/dist-packages/requests/api.py", line 58, in request
    return session.request(method=method, url=url, **kwargs)
  File "/usr/lib/python3/dist-packages/requests/sessions.py", line 520, in request
    resp = self.send(prep, **send_kwargs)
  File "/usr/lib/python3/dist-packages/requests/sessions.py", line 630, in send
    r = adapter.send(request, **kwargs)
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 506, in send
    raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='firewall.linuxmuster.lan', port=443): Max retries exceeded with url: /api/proxysso/service/deletekeytab (Caused by SSLError(CertificateError("hostname 'firewall.linuxmuster.lan' doesn't match 'firewall.gymneureut.de'",),))
root@server:~# 
HappyBasher commented 2 years ago

Seems that key based ssh connection with python library paramiko is broken.

kiarn commented 2 years ago

Hello,

I will try to test it on my own test server, but this seems more to be a mismatch between hostname and hostname written in the certificate, not really a problem of paramiko. @HappyBasher : thanks for your fix !