{"id":125,"date":"2016-06-11T22:00:46","date_gmt":"2016-06-12T02:00:46","guid":{"rendered":"http:\/\/www.hackspot.net\/CircleBlog\/?p=125"},"modified":"2016-06-12T23:48:10","modified_gmt":"2016-06-13T03:48:10","slug":"theres-no-longer-any-point-to-cracking-the-root-password","status":"publish","type":"post","link":"http:\/\/www.hackspot.net\/CircleBlog\/2016\/06\/11\/theres-no-longer-any-point-to-cracking-the-root-password\/","title":{"rendered":"There&#8217;s no longer any point to cracking the root password"},"content":{"rendered":"<p>When I first got serial port access to my Circle, I grabbed the \/etc\/shadow file and started running &#8220;John The Ripper&#8221; to attempt to crack the root password (it&#8217;s been running for 47 days). \u00a0The hope was that I could crack the password, making it easier for others to get into their Circle devices (without requiring a serial port).<\/p>\n<p>Well, I just installed the latest firmware from Circle, and found that they have changed to using key-based ssh login instead of password. \u00a0In the process, they&#8217;ve removed the root password (so you can&#8217;t login as root anymore, unless you have their private ssh key).<\/p>\n<p>The new \/mnt\/shares\/usr\/bin\/startcircle script has the following line:<\/p>\n<pre>[ -f $DIR\/scripts\/authorized_keys ] &amp;&amp; { diff $DIR\/scripts\/authorized_keys \/etc\/dropbear\/authorized_keys &gt; \/dev\/null || { cp -f $DIR\/scripts\/authorized_keys \/etc\/dropbear\/authorized_keys; <strong>sed -i -e 's\/root:[^:]*:\/root:*:\/g' \/etc\/shadow<\/strong>; } }<\/pre>\n<p>The above line copies an ssh &#8216;authorized_keys&#8217; file from \/mnt\/shares\/usr\/bin\/scripts to \/etc\/dropbear. \u00a0It also removes the password for the user &#8216;root&#8217; in &#8216;\/etc\/shadow&#8217;.<\/p>\n<p>The new &#8216;\/etc\/dropbear\/authorized_keys&#8217; has one entry for Circle&#8217;s key:<\/p>\n<pre>ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAuIaD23ac41XZp5AcSSOunHXHYN38dF2YX+rmb0QT4zxKFnccl6BpzoxGb604rPc4eQ477glWyM4D\/jTIyaKqmA7P1iVMym8v5nSXH6haSc\/KrzV5EizmalXd4+eoK8ddSgpoci0P9oul3yiWtvccwN5WQ5H\/DZhyYvdM73kKnYh3JUllx8JnGi1Qa0nhNGfrhIqaApTc\/AyIAFR9I8wtp5KR98xRH5u\/hEm1IMB5lo7yS6yJUcupIctnW\/C2qUOD7WtWzZvJtgAmmhh+A1XLU42PruPtTfQ2EAHUmNJ+xVssUl3N2cIhvCt1sm5o8DymttOS4xot6Ni06UZ\/LK\/iKw== tzhang@gateway<\/pre>\n<p>It&#8217;s not possible to brute-force an ssh RSA key, and it&#8217;s no longer possible to login as &#8216;root&#8217; with a password, so there&#8217;s no longer any point to continue the password cracking process.<\/p>\n<p>No worries, though &#8211; we can still get in without a serial port or the root password. \u00a0I&#8217;ll post details on modifying a firmware update image to add a new user (with root privileges) soon.<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When I first got serial port access to my Circle, I grabbed the \/etc\/shadow file and started running &#8220;John The Ripper&#8221; to attempt to crack the root password (it&#8217;s been running for 47 days). \u00a0The hope was that I could crack the password, making it easier for others to get into their Circle devices (without &hellip; <a href=\"http:\/\/www.hackspot.net\/CircleBlog\/2016\/06\/11\/theres-no-longer-any-point-to-cracking-the-root-password\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;There&#8217;s no longer any point to cracking the root password&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/posts\/125"}],"collection":[{"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/comments?post=125"}],"version-history":[{"count":4,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/posts\/125\/revisions"}],"predecessor-version":[{"id":152,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/posts\/125\/revisions\/152"}],"wp:attachment":[{"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/media?parent=125"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/categories?post=125"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.hackspot.net\/CircleBlog\/wp-json\/wp\/v2\/tags?post=125"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}