automate OTP credentials for multi-factor authentication

Background: I work with one or more terminal command-line always opened and having to pick up my phone to generate an OTP breaks my flow; also it’s always nice to have an alternate source of multi-factor authentication if something bad happens, one day you could lose or break your trusty mobile device. Therefore I was looking for a way to login through Okta portals without a phone. You may argument that this defeats the whole meaning of MFA, but let’s say it’s only an hack for research and fun purpose … ...

June 14, 2022 · Andrea Manzini

how to display the IP address of a virtual machine before logon

For testing or development purposes, I do a wide use of small linux virtual machines. After spawning a new guest (Virtualbox, VMWare or any other), often you want to log on over ssh but you don’t yet know its ip address. You need to login as ‘root’ in the console just to issue a quick ‘ifconfig’, and after writing down the address, you logout and connect with your comfortable terminal. In order to save some time and keystrokes, I put this in my rc.local of all my guest VMs: ...

May 5, 2014 · Andrea Manzini

Automate Cisco ssh connections with plink in Windows

A quick and dirty way to send a bunch of commands to any ssh device (in my case, Cisco appliances)… create a plain old batch file with commands echoed inside: execute the batch, piping its output to plink.exe (putty command link ssh client): c:\> commands.bat | plink -ssh -l username -pw password 11.22.33.44

May 27, 2013 · Andrea Manzini