I must be missing something here. It sounds like you used to have:
script-on-box --telnet--> hardware.
And now the hardware doesn't accept telnet connections, and you've got your script-on-box that doesn't know how to do ssh. So you want to do:
script-on-box --telnet--> another box --ssh--> hardware
Net::Telnet will allow you to connect to an ssh session, so you could just spawn an ssh connection to the piece of hardware, then attach that ssh connection to your Net::Telnet object. (Search for 'spawn' in the Net::Telnet perldoc for an example of this.) Your script would continue to behave as it has in the past, interacting with a Net::Telnet object that just happens to be speaking ssh.
But I assume you already know this, so what am I missing?