Setting a default root password
Hey guys. During my auto install I want a default root password to be put in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well. Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated. Thanks, -Nick
<quote who="Nicholas DeClario">
Hey guys. During my auto install I want a default root password to be put in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well.
<users config:type="list"> <user> <encrypted config:type="boolean">true</encrypted> <user_password>iE*obscured**</user_password> <username>root</username> </user> </users> where iE*obscured** is obviously replaced with the root passwd hash you've set somewhere. It's also possible to generate this hash from the command line; I didn't do that research for you here.
Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
Thanks, -Nick
-- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
-- Randy Dees c: (704) 618-0887 Random Thought: --------------- We hold these truths to be sacred and undeniable; that all men are created equal and independent, that from that equal creation they derive rights inherent and inalienable, among which are the preservation of life, liberty, and the pursuit of happiness. - Thomas Jefferson, 1743 - 1826
Hey guys. During my auto install I want a default root password to be
To obtain iE*obscured** from the command line, you can use the Perl crypt() function to generate the 13 character hash string. This uses standard DES encryption (one-way) for password hashes. Example for password "cluster" and arbitrary salt "95": $ perl -e 'print crypt("cluster", "95"),"\n"' 95G9p0q.CBtl. -Carl Pecinovsky "Randy Dees" <randy@deesfamily .com> To suse-autoinstall@suse.com 09/08/2004 04:28 cc PM Subject Re: [suse-autoinstall] Setting a default root password <quote who="Nicholas DeClario"> put
in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well.
<users config:type="list"> <user> <encrypted config:type="boolean">true</encrypted> <user_password>iE*obscured**</user_password> <username>root</username> </user> </users> where iE*obscured** is obviously replaced with the root passwd hash you've set somewhere. It's also possible to generate this hash from the command line; I didn't do that research for you here.
Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
Thanks, -Nick
-- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
-- Randy Dees c: (704) 618-0887 Random Thought: --------------- We hold these truths to be sacred and undeniable; that all men are created equal and independent, that from that equal creation they derive rights inherent and inalienable, among which are the preservation of life, liberty, and the pursuit of happiness. - Thomas Jefferson, 1743 - 1826 -- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
Hey guys, thanks for all the info and quick replies! I will give this a try shortly. Thanks! -Nick On Wed, 8 Sep 2004, Carl Pecinovsky wrote:
To obtain iE*obscured** from the command line, you can use the Perl crypt() function to generate the 13 character hash string. This uses standard DES encryption (one-way) for password hashes.
Example for password "cluster" and arbitrary salt "95": $ perl -e 'print crypt("cluster", "95"),"\n"' 95G9p0q.CBtl.
-Carl Pecinovsky
"Randy Dees" <randy@deesfamily .com> To suse-autoinstall@suse.com 09/08/2004 04:28 cc PM Subject Re: [suse-autoinstall] Setting a default root password
Hey guys. During my auto install I want a default root password to be
<quote who="Nicholas DeClario"> put
in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well.
<users config:type="list"> <user> <encrypted config:type="boolean">true</encrypted> <user_password>iE*obscured**</user_password> <username>root</username> </user> </users>
where iE*obscured** is obviously replaced with the root passwd hash you've set somewhere. It's also possible to generate this hash from the command line; I didn't do that research for you here.
Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
Thanks, -Nick
-- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
-- Randy Dees c: (704) 618-0887
Random Thought: --------------- We hold these truths to be sacred and undeniable; that all men are created equal and independent, that from that equal creation they derive rights inherent and inalienable, among which are the preservation of life, liberty, and the pursuit of happiness. - Thomas Jefferson, 1743 - 1826
-- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
-- To unsubscribe, e-mail: suse-autoinstall-unsubscribe@suse.com For additional commands, e-mail: suse-autoinstall-help@suse.com
Hi Nick! I'm setting the root password with a postinstall script. First, you have to get the encrypted password you want to set for "root" from the /etc/shadow file (the second in this file. Then specify a postinstall-script doing this: usermod -p your-encrypted-password-from-shadow root This works for me in 8.2, 9.0, 9.1 Best regards Ing. Wolfgang Skabrond -- TWS Datensysteme Ges.m.b.H. Cobenzlgasse 32/3 A-1190 Wien Tel.: +43/1/32 9 32-0 Fax: +43/1/32 9 32-30 WWW: http://www.tws.at E-Mail: skabrond@tws.at --- Nicholas DeClario schrieb am 08.09.2004, 22:43 ---
Hey guys. During my auto install I want a default root password to be put in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well.
Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
Thanks, -Nick
Hi Nick! I'm setting the root password with a postinstall script. First, you have to get the encrypted password you want to set for "root" from a /etc/shadow file (the second field in this file). Then specify a postinstall-script doing this: usermod -p your-encrypted-password-from-shadow root This works for me in 8.2, 9.0, 9.1 Best regards Ing. Wolfgang Skabrond -- TWS Datensysteme Ges.m.b.H. Cobenzlgasse 32/3 A-1190 Wien Tel.: +43/1/32 9 32-0 Fax: +43/1/32 9 32-30 WWW: http://www.tws.at E-Mail: skabrond@tws.at --- Nicholas DeClario schrieb am 08.09.2004, 22:43 ---
Hey guys. During my auto install I want a default root password to be put in place. I checked numberous documentation and searched quite a bit and couldn't come up with anything. I was going to just do something like 'echo "password" | passwd root --stdin' in a post-install script but the 'passwd' included in SuSE does not support the --stdin option I've seen in the past. I would prefer not to hack up passwd to add this functionality as well.
Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
Thanks, -Nick
Hey guys. During my auto install I want a default root password to be put in place. I checked numberous documentation and searched quite a bit and ... Am I missing something obvious? Is there anyway this can be done? Any help would be appreciated.
in suse 9.0 and 9.1 autoyast editor: security and users -> edit and create users. click configure. set filter -> system users. select root and click edit. you can then enter a password for root.
participants (5)
-
Carl Pecinovsky
-
Ing. Wolfgang Skabrond
-
Nicholas DeClario
-
Rajiv Aaron Manglani
-
Randy Dees