Page 10 of 30

Re: Fully automated rooting script

Posted: Sat Dec 15, 2018 11:12 pm
by martenjacobs
If rooting using the script is successful, you could connect using the generated ssh key pair. I haven’t used them on Windows (because bleegh), but from any unix they work fine. Once you have ssh access you can set the password you want.

The rooting script searches for a disabled root user, which is a known issue at the moment, as seen here.
If you really want to set a password from the script, you may be able to circumvent the issue by changing a line in payload/patch_toon.sh, but I haven’t been able to test this:
Change the line

Code: Select all

sed -i -e "s/^root:DISABLED:/root:$PASSENC:/" /etc/passwd
To

Code: Select all

sed -i -e "s/^root:[^:]*:/root:$PASSENC:/" /etc/passwd

Re: Fully automated rooting script

Posted: Sat Dec 15, 2018 11:39 pm
by alcomys
TheHogNL wrote:Yes, without the proper busybox you won't get user login prompt on serial port.

You can just easily set your root password from the uboot method. SSH login requires a root password to be set. It doesn't allow a empty password.

thanks , can u explane how to change the root passwd from u-boot login ?
i have changed the passwd file en removed the DISABLED from the root passwd but i have an empty password now.

best regards,trey

Re: Fully automated rooting script

Posted: Sat Dec 15, 2018 11:44 pm
by alcomys
martenjacobs wrote:If rooting using the script is successful, you could connect using the generated ssh key pair. I haven’t used them on Windows (because bleegh), but from any unix they work fine. Once you have ssh access you can set the password you want.

The rooting script searches for a disabled root user, which is a known issue at the moment, as seen here.
If you really want to set a password from the script, you may be able to circumvent the issue by changing a line in payload/patch_toon.sh, but I haven’t been able to test this:
Change the line

Code: Select all

sed -i -e "s/^root:DISABLED:/root:$PASSENC:/" /etc/passwd
To

Code: Select all

sed -i -e "s/^root:[^:]*:/root:$PASSENC:/" /etc/passwd
Thanks for that i had also my idea that the random passwd was not writed to /etc/passwd because it was never changed after rooted.
i try to change the script tomorrow and give it a try to root again.
i let you know what it does.

Beste regards,trey

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 8:33 am
by mAiden
Think that this one will also work on uboot:

Code: Select all

sed -i 's/root:[^:]*/root:FTR0zlZvsHEF2/' /etc/passwd
It change the root password to 'toon'

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 9:29 am
by TheHogNL
mAiden wrote:Think that this one will also work on uboot:

Code: Select all

sed -i 's/root:[^:]*/root:FTR0zlZvsHEF2/' /etc/passwd
It change the root password to 'toon'
This is correct. Nice copy from the TSC script mAiden :lol:

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 9:42 am
by mAiden
TheHogNL wrote:
mAiden wrote:Think that this one will also work on uboot:

Code: Select all

sed -i 's/root:[^:]*/root:FTR0zlZvsHEF2/' /etc/passwd
It change the root password to 'toon'
This is correct. Nice copy from the TSC script mAiden :lol:
Sorry, Copy paste was even faster :D

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 12:28 pm
by alcomys
mAiden wrote:
TheHogNL wrote:
mAiden wrote:Think that this one will also work on uboot:

Code: Select all

sed -i 's/root:[^:]*/root:FTR0zlZvsHEF2/' /etc/passwd
It change the root password to 'toon'
This is correct. Nice copy from the TSC script mAiden :lol:
Sorry, Copy paste was even faster :D
So if i understand this is toon as root passwd ? (FTR0zlZvsHEF2)

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 12:55 pm
by marcelr
Yep, that's the encrypted version of it.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 2:12 pm
by alcomys
marcelr wrote:Yep, that's the encrypted version of it.
yep this did the trick !
i can now login using password toon :)
the only question left about this problem is , can i use my own password ? and how can i change that from u-boot ?

thanks for this help.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 3:21 pm
by TheHogNL
You don't need the u-boot login method to change your password.
Please try to find out yourself how to change a root password on a linux machine. Some trying and looking yourself is appriciated in here.

You might find out how darn easy it is to change your 'passwd'. I think it is even mentioned in the manual.

I mean, all your earlier questions are a bit of : 'nah i don't like to figure out myself, just ask directly'

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 4:07 pm
by alcomys
TheHogNL wrote:You don't need the u-boot login method to change your password.
Please try to find out yourself how to change a root password on a linux machine. Some trying and looking yourself is appriciated in here.

You might find out how darn easy it is to change your 'passwd'. I think it is even mentioned in the manual.

I mean, all your earlier questions are a bit of : 'nah i don't like to figure out myself, just ask directly'
thanks i know a lot about linux and i know how to change passwd on linux but some Uclinux is to different for me that's why i ask, but i do google first nexttime before i ask things here.
(nah i don't like to figure out myself) about this am not lazy ive been almost one week at testing and trying my self, but if everyone new all what to do. this forum did not exist or am i wrong ?

thanks.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 5:41 pm
by TheHogNL
I just want to point out that everything what you have asked was written in a manual, doc or asked multiple times on the forum before.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 7:07 pm
by marcelr
You can change the password by issueing the command

Code: Select all

passwd
Please note that some versions of busybox on Toon do not have passwd implemented. In these cases you will need to exchange the original busybox with the one from the forum file server.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 8:42 pm
by martenjacobs
TheHogNL wrote:I just want to point out that everything what you have asked was written in a manual, doc or asked multiple times on the forum before.
Also, I think we should keep this thread focused on the rooting script. Many of the questions asked were not about the script at all, and just create noise which others may now have to dig through to find the information they need.

Re: Fully automated rooting script

Posted: Sun Dec 16, 2018 9:17 pm
by marcelr
martenjacobs wrote:
TheHogNL wrote:I just want to point out that everything what you have asked was written in a manual, doc or asked multiple times on the forum before.
Also, I think we should keep this thread focused on the rooting script. Many of the questions asked were not about the script at all, and just create noise which others may now have to dig through to find the information they need.
Fair point, let's also stick to our respectful way of communicating, and maybe encourage new members to ask their (sometimes basic or general) questions in separate threads.