Posts

Showing posts with the label ssh

MacOS Ventura: not able to ssh to ruckus switch (diffie-hellman-group1-sha1)

 I upgrade to Ventura and replaced my Intel MacMini with an M2 MacBook Air ... everything was working, then I wanted to ssh to my Ruckus ICX 7150-C12 (08.0.95fT211), and got an error: Unable to negotiate with my-switch port 22: no matching key exchange method found. Their offer: diffie-hellman-group14-sha1,diffie-hellman-group1-sha1 Hummm, WTF.... I've seen similar things before when you upgrade FW or OS suddenly ssh will no longer work as a protocol or cipher have been deprecated. As I do not feel like upgrading my switch I had to do something else. I found this on serverfaul t, helped to a part of the way, and then a bit more googling I found the solution, which might be overkill. I ended up adding this in my ~/.ssh/config for the switch: Host my-switch KexAlgorithms=+diffie-hellman-group1-sha1 PubkeyAcceptedKeyTypes ssh-ed25519,ssh-rsa,rsa-sha2-256,rsa-sha2-512 HostkeyAlgorithms +ssh-rsa    And now I can access my switch again. Yes, I know upgrading...

Using Borg backup across SSH with sshkeys

Borgbackup is a fantastic piece of software. It's a free deduplicating archiver with compression and encryption, which reduces the amount of storage one needs to have to be able to keep backup archive for a very long term. One of the great small things it can do is that it can run across the wire using ssh, authenticating with sshkeys. Sadly the documentation is not 100% correct, and it lack one bit of information for one to be able to get it to run. The steps to get it working are: Follow the documentation to install borg Create a user on the destination server which will be the one who owns the repo. On the destination create the repo: borg init <path/repo name> On the source create an sshkey without passphrase (it is possible to do this with a passphrase - I just couldn't be bothered), and distribute the key to the destination server/user. Create a script which is use to setup a few environment variables which borg needs: BORG_PASSCOMMAND="cat <fil...

VMware ESXi 5 - VNC to a guest

One of the more annoying things is that by default one have to use the vSphere client to access the console of a guest. Some people have decided to modify the firewall on the host to get direct access to the guest, but there is a simpler way to accomplish this. enable ssh key authentication on the host add the following to the guest configuration (needed no matter what) RemoteDisplay.vnc.enabled = "true" RemoteDisplay.vnc.port = "<port number for the vnc server>" configure your vnc client to use ssh, for example with Chicken of the VNC : Host: <your vmware esxi host> Port: the port number specified for the guest [X] Tunnel over SSH SSH Host: root@<your vmware esxi host>

VMware ESXi 5 - ssh key authentication

One of the big mysteries about VMware ESXi is how to enable ssh key authentication, as there are many solution. From making a .tgz file and store it in /bootbank, to more elaborate solutions where one modifies one of the .tgz files. The easiest way is simply to copy your .pub file to /etc/ssh/keys-root/authorized_keys and presto it will work for the root user.