{"id":2115,"date":"2016-11-23T07:47:54","date_gmt":"2016-11-23T13:47:54","guid":{"rendered":"http:\/\/www.wiredprairie.us\/blog\/?p=2115"},"modified":"2016-11-23T07:47:54","modified_gmt":"2016-11-23T13:47:54","slug":"changing-password-requirements-in-linux-subsystem-for-windows-or-bash-on-ubuntu-on-windows","status":"publish","type":"post","link":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/2115","title":{"rendered":"Changing password requirements in Linux Subsystem for Windows (or Bash on Ubuntu on Windows)"},"content":{"rendered":"

While I understand the reasoning, it’s a bit annoying needing to set a secondary password in the Bash on Ubuntu on Windows instance. If you’re on a domain joined computer, or occasionally update your password like you should, there’s a reasonable chance that the password you use for Bash is different than the one you use for general access to your PC. In fact, it’s probably likely.<\/p>\n

Since I have a number of Windows boxes I frequently use, I wanted to create a password that while different from machine to machine, would be easy to remember (and not the same from machine to machine). However, the password I’d wanted to use didn’t always meet the default password requirements.<\/p>\n

So, here’s what I did. From the Bash prompt, I first\u00a0tried to change the password to see if my new password met the complexity and length requirements. If your password works, there’s no more to do!<\/p>\n

$ passwd<\/strong><\/pre>\n

Results:<\/p>\n

(current) UNIX password:\r\nEnter new UNIX password:\r\nRetype new UNIX password:\r\nYou must choose a longer password<\/strong><\/pre>\n

OK. So, I needed to change the requirements. I used the editor nano<\/strong>.<\/p>\n

$ cd \/etc\/pam.d\/<\/strong>\r\n$ sudo nano common-password<\/strong><\/pre>\n

To save the file, use CTRL+O<\/strong> to write out changes, hit ENTER<\/strong>, then CTRL+X<\/strong> to Exit.<\/p>\n

Look for the line:<\/p>\n

password \u00a0 \u00a0 \u00a0 \u00a0[success=1 default=ignore] \u00a0 \u00a0obscure \u00a0pam_unix.so sha512<\/pre>\n

And replace it with (I removed obscure<\/strong> and added minlen=1<\/strong>):<\/p>\n

password \u00a0 \u00a0 \u00a0 \u00a0[success=1 default=ignore] \u00a0 \u00a0 \u00a0pam_unix.so sha512 minlen=1<\/pre>\n

Now, try changing the password again using passwd<\/strong>.<\/p>\n

$ passwd\r\nChanging password for aaron.\r\n(current) UNIX password:\r\nEnter new UNIX password:\r\nRetype new UNIX password:\r\npasswd: password updated successfully<\/pre>\n

Done.<\/strong><\/p>\n

Hopefully I’ll remember to look here the next time I set up Windows and Bash on Ubuntu on Windows (gee, that’s a mouthful!). And more importantly, I won’t encounter this experience again:<\/p>\n

$ sudo apt-get update\r\n[sudo] password for aaron:\r\nSorry, try again.\r\n[sudo] password for aaron:\r\nSorry, try again.\r\n[sudo] password for aaron:\r\nSorry, try again.\r\nsudo: 3 incorrect password attempts<\/pre>\n","protected":false},"excerpt":{"rendered":"

While I understand the reasoning, it’s a bit annoying needing to set a secondary password in the Bash on Ubuntu on Windows instance. If you’re on a domain joined computer, or occasionally update your password like you should, there’s a reasonable chance that the password you use for Bash is different than the one you […]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spay_email":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true},"categories":[5,6],"tags":[172,171],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pd5QIe-y7","jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":1754,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/1754","url_meta":{"origin":2115,"position":0},"title":"Nest Thermostat API using Node JS and Nest API Update","date":"October 9, 2012","format":false,"excerpt":"I\u2019ve been asked by a few people for more details on the API Nest Labs uses for their thermostats, especially regarding setting data (and not just polling). The API uses mostly JSON formatted data POSTed to their web servers. Authentication To authenticate, POST the username and password, encoded as form\u2026","rel":"","context":"In "Coding"","img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1214,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/1214","url_meta":{"origin":2115,"position":1},"title":"Setup for the Asante VoyagerIP Cameras: Wireless Woes","date":"June 13, 2011","format":false,"excerpt":"I recently purchased two new IP cameras from Amazon. The Asante Voyager I and Asante Voyager II. They\u2019re both good cameras with lots of bells and whistles, and a decent amount of configuration options that should satisfy both the geeks and a non-geek. The reason I\u2019m posting this is to\u2026","rel":"","context":"In "General"","img":{"alt_text":"image","src":"https:\/\/i0.wp.com\/www.wiredprairie.us\/blog\/wp-content\/uploads\/2011\/06\/image1.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":1576,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/1576","url_meta":{"origin":2115,"position":2},"title":"Nest Thermostat Review, Update #10: Wifi Settings Missing","date":"March 24, 2012","format":false,"excerpt":"One more brief update about our Nest thermostats. After a few weeks of limited use of our HVAC system due to a very unusually warm late winter and early spring, I\u2019d set the whole house to AWAY mode last evening. However, a bit later, I heard the furnace running. Odd.\u2026","rel":"","context":"In "Recommendations"","img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":1963,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/1963","url_meta":{"origin":2115,"position":3},"title":"Blue Iris 3 and Samsung SmartCam SNH-1011N","date":"October 9, 2013","format":false,"excerpt":"If you\u2019ve got a Samsung SmartCam SNH-1011N and you want to use it with Blue Iris 3, I found a reasonable currently undocumented way to make it work. The camera currently isn\u2019t officially supported by Blue Iris, but it can be made to work with a few simple steps. I\u2019ve\u2026","rel":"","context":"In "General"","img":{"alt_text":"image","src":"https:\/\/i0.wp.com\/www.wiredprairie.us\/blog\/wp-content\/uploads\/2013\/10\/image_thumb1.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":433,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/433","url_meta":{"origin":2115,"position":4},"title":"Ubuntu Linux to be art in two years?","date":"July 24, 2008","format":false,"excerpt":"As reported by The Register, Mark Shuttleworth, founder of Ubuntu Linux said that the company is working to make the Ubuntu desktop \"more beautiful\" in the next two years -- to something that's art. \"I think the great task in front of us in the next two years is to\u2026","rel":"","context":"In "Software"","img":{"alt_text":"image","src":"https:\/\/i0.wp.com\/www.wiredprairie.us\/blog\/wp-content\/uploads\/2008\/07\/image18.png?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":1236,"url":"https:\/\/www.wiredprairie.us\/blog\/index.php\/archives\/1236","url_meta":{"origin":2115,"position":5},"title":"1Password from AgileBits","date":"November 29, 2011","format":false,"excerpt":"Just a quick recommendation \u2013 if you\u2019d like to have a multiple-family member licensed, password management application that works in Windows and OS X, you might want to try 1Password from AgileBits. Through the end of November 2011, they\u2019re offering a 50% off sale, which makes their software a significantly\u2026","rel":"","context":"In "General"","img":{"alt_text":"image","src":"https:\/\/i0.wp.com\/www.wiredprairie.us\/blog\/wp-content\/uploads\/2011\/11\/image.png?resize=350%2C200","width":350,"height":200},"classes":[]}],"_links":{"self":[{"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/posts\/2115"}],"collection":[{"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/comments?post=2115"}],"version-history":[{"count":3,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/posts\/2115\/revisions"}],"predecessor-version":[{"id":2118,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/posts\/2115\/revisions\/2118"}],"wp:attachment":[{"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/media?parent=2115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/categories?post=2115"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wiredprairie.us\/blog\/index.php\/wpjson\/wp\/v2\/tags?post=2115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}