vmrc icon indicating copy to clipboard operation
vmrc copied to clipboard

spaces in the `vm_password` will cause root to have no password

Open calvinhp opened this issue 10 years ago • 3 comments

Setting the vm_password to a value like "change me" will result in root having no password on boot of the VM.

calvinhp avatar Jan 27 '15 14:01 calvinhp

This could probably be fixed by adding quotation marks around "$1" in mkvm.sh.functions: f_set_password() ## $1 password $2 mount point ## { echo "$1" | pw -V ${2}/etc/ usermod root -h 0 }

Could you try this and let me know if it resolves it?

Thanks!

michaeldexter avatar Jan 30 '15 06:01 michaeldexter

Did you have a chance to try this?

michaeldexter avatar May 31 '15 08:05 michaeldexter

I just tested and if I put a space in the password, the resulting password for root is empty, but if I take the space out it is set correctly with that change to the code.

calvinhp avatar May 31 '15 19:05 calvinhp