Tens of thousands of home routers at risk with duplicate SSH keys

The setup mistake could put the routers at risk of being compromised

Tens of thousands of home routers from Telefónica de España share the same SSH key pairs.

Tens of thousands of home routers from Telefónica de España share the same SSH key pairs.

A setup mistake has apparently left hundreds of thousands of home routers running the SSH (Secure Shell) remote access tool with identical private and public keys.

John Matherly used Shodan, a specialized search engine for querying Internet-connected devices, and found more than 250,000 devices that appear to be deployed by Telefónica de España sharing the same public SSH key.

Matherly, who founded Shodan, performed the search after someone posted a shorter version of a public key -- called a fingerprint -- for their device.

He was surprised to find more than 250,000 other devices, mostly in Spain, that shared the same public key fingerprint. It means the devices -- which are likely home routers -- also have the same private key, which could pose a security risk.

A different search found another 150,000 devices, mostly in China and Taiwan, that have the same problem.

Matherly said in a phone interview on Wednesday it is possible the manufacturers copied the same operating system image to all of the routers.

Another explanation is that an ISP reflashed the devices with custom settings, but did so insecurely, Matherly said. Newly imaged devices running SSH should be configured to generate their own unique key pairs.

But it is questionable whether SSH should be running on a home router anyway. It is used by administrators to enable encrypted, remote access to a system, but that capability isn't usually needed for home routers. All of the Telefónica de España routers were running a version of SSH called Dropbear.

"It's kind of weird that [SSH] is there in the first place," said Matherly, who also blogged about his findings. "You don't need to change your Wi-Fi password when you're away from home. It's very unusual."

The settings for a home router can usually be accessed by those on its local network through a password-protected Web interface.

Matherly said another problem of thousands of devices sharing the same key pair is that there is no way to verify a specific device. The public key fingerprint is a way to verify that a device is who it says it is, but if many devices share the fingerprint, it's impossible to tell, Matherly said.

It's hard to say if the key errors means that a remote attacker could log into all of the devices, as it would depend on how the routers are configured for remote authentication.

But "the biggest issue I see is that if you compromise one of them, you know that every other device is going to be exactly the same," Matherly said.

Matherly said he didn't take it that far and that he only queried the devices with Shodan, which goes through the motions of setting up a connection with a router, including collecting its public fingerprint, but doesn't try to login.

It would be near impossible for consumers to figure out how to generate new SSH keys or turn SSH off in the routers, Matherly said.

The problem is not unique to home routers. Cloud computing providers have occasionally made mistakes by not generating fresh SSH keys with new instances of virtual machines, Matherly said.

"This kind of issue actually happens all over the cloud," he said.

Send news tips and comments to jeremy_kirk@idg.com. Follow me on Twitter: @jeremy_kirk

Join the CSO newsletter!

Error: Please check your email address.

Tags Shodansecurity

More about SSH

Show Comments

Featured Whitepapers

Editor's Recommendations

Solution Centres

Stories by Jeremy Kirk

Latest Videos

  • 150x50

    CSO Webinar: The Human Factor - Your people are your biggest security weakness

    ​Speakers: David Lacey, Researcher and former CISO Royal Mail David Turner - Global Risk Management Expert Mark Guntrip - Group Manager, Email Protection, Proofpoint

    Play Video

  • 150x50

    CSO Webinar: Current ransomware defences are failing – but machine learning can drive a more proactive solution

    Speakers • Ty Miller, Director, Threat Intelligence • Mark Gregory, Leader, Network Engineering Research Group, RMIT • Jeff Lanza, Retired FBI Agent (USA) • Andy Solterbeck, VP Asia Pacific, Cylance • David Braue, CSO MC/Moderator What to expect: ​Hear from industry experts on the local and global ransomware threat landscape. Explore a new approach to dealing with ransomware using machine-learning techniques and by thinking about the problem in a fundamentally different way. Apply techniques for gathering insight into ransomware behaviour and find out what elements must go into a truly effective ransomware defence. Get a first-hand look at how ransomware actually works in practice, and how machine-learning techniques can pick up on its activities long before your employees do.

    Play Video

  • 150x50

    CSO Webinar: Get real about metadata to avoid a false sense of security

    Speakers: • Anthony Caruana – CSO MC and moderator • Ian Farquhar, Worldwide Virtual Security Team Lead, Gigamon • John Lindsay, Former CTO, iiNet • Skeeve Stevens, Futurist, Future Sumo • David Vaile - Vice chair of APF, Co-Convenor of the Cyberspace Law And Policy Community, UNSW Law Faculty This webinar covers: - A 101 on metadata - what it is and how to use it - Insight into a typical attack, what happens and what we would find when looking into the metadata - How to collect metadata, use this to detect attacks and get greater insight into how you can use this to protect your organisation - Learn how much raw data and metadata to retain and how long for - Get a reality check on how you're using your metadata and if this is enough to secure your organisation

    Play Video

  • 150x50

    CSO Webinar: How banking trojans work and how you can stop them

    CSO Webinar: How banking trojans work and how you can stop them Featuring: • John Baird, Director of Global Technology Production, Deutsche Bank • Samantha Macleod, GM Cyber Security, ME Bank • Sherrod DeGrippo, Director of Emerging Threats, Proofpoint (USA)

    Play Video

  • 150x50

    IDG Live Webinar:The right collaboration strategy will help your business take flight

    Speakers - Mike Harris, Engineering Services Manager, Jetstar - Christopher Johnson, IT Director APAC, 20th Century Fox - Brent Maxwell, Director of Information Systems, THE ICONIC - IDG MC/Moderator Anthony Caruana

    Play Video

More videos

Blog Posts