Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Here are software that related with Samsung F series TVs.
Please don't create any new topic here unless you have software to post/release.

bobiturboto
SamyGO Project Donor
Posts: 489
Joined: Sun Mar 23, 2014 8:15 pm
Location: Bulgaria

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by bobiturboto »

FOR F SERIES YOU HAVE TO DO THIS!!!!!!

You have to use dropbearmulti from archive attached in this post to get scp working for telnet and SSH.

Upload and replace /mnt/opt/privateer/usr/sbin/dropbearmulti with the attached file.

Locate these lines in /mnt/etc/init.d/01_02_telnet.init :

Code: Select all

$SYSROOT/bin/busybox2 telnetd -p 23 -l $SYSROOT/bin/ash &  >> $LOGFILE 2>&1
Replace the line with this:

Code: Select all

	echo "export PS1='root@tv:\w \$ '" >> /mtd_rwarea/profile
	echo -e "ENV=/dtv/.ashrc\nexport ENV\n" >> /mtd_rwarea/profile
	echo "PS1='root@tv:\w \$ '" >> /mtd_rwarea/profile
	echo -e "ENV=/dtv/.ashrc\nexport ENV\n" >> /mtd_rwarea/profile
	/bin/mount -o bind "$SYSROOT/bin/sh" /bin/sh
	export HOME=/mnt/
	export PS1='root@tv:\w \$ '
	$SYSROOT/bin/busybox2 telnetd -p 23 -l $SYSROOT/bin/sh &  >> $LOGFILE 2>&1
In the same file find this part:

Code: Select all

        if [ ! -e /mtd_rwarea/passwd ]; then
                echo "root:saJvQKUdIxRW2:0:0:SamyGO secured Root:$NEW_HOME:$SYSROOT/bin/ash" > /mtd_rwarea/passwd
        fi
Replace it with this:

Code: Select all

	ln -s /mnt/bin/ /dtv/bin
		if [ ! -e /mtd_rwarea/passwd ]; then
                echo "root:saJvQKUdIxRW2:0:0:SamyGO secured Root:$HOME:/bin/sh" > /mtd_rwarea/passwd
        fi
Then run this commands:

Code: Select all

umount /mtd_rwarea/passwd
rm /mtd_rwarea/passwd
Execute the listed commands through telnet connection.

Code: Select all

chmod +x /mnt/opt/privateer/usr/sbin/dropbearmulti
rm /mnt/opt/privateer/usr/sbin/dropbear
ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/bin/dbclient
ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/bin/scp
ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/opt/privateer/usr/sbin/dropbear
Reboot your TV and after that you will have fixed telnet and working ssh access with scp and ssh history.
Default ssh user is root and the password is SamyGO

Credits to sectroyer.
You do not have the required permissions to view the files attached to this post.
Last edited by bobiturboto on Sun Jul 06, 2014 6:20 pm, edited 1 time in total.
sectroyer
Official SamyGO Developer
Posts: 6305
Joined: Wed May 04, 2011 5:10 pm

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by sectroyer »

I changed the tutorial. No need to edit passwd manually. Running this is enough:

Code: Select all

umount /mtd_rwarea/passwd
rm /mtd_rwarea/passwd
I do NOT support "latest fw" at ALL. If you have one you should block updates on router and wait for it to STOP being "latest":)
If you want me to help you please paste FULL log(s) to "spoiler"/"code" bbcodes or provide link(s) to pasted file(s) on https://pastebin.com Otherwise "NO HELP"!!!
If you want root DISABLE internet access to your device!!!!
DO NOT EVER INSTALL FIRMWARE UPGRADE !!!!
bobiturboto
SamyGO Project Donor
Posts: 489
Joined: Sun Mar 23, 2014 8:15 pm
Location: Bulgaria

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by bobiturboto »

sectroyer wrote:I changed the tutorial. No need to edit passwd manually. Running this is enough:

Code: Select all

umount /mtd_rwarea/passwd
rm /mtd_rwarea/passwd
Sometimes umount throwing me the errors about busy resources. For this reason I have decided to use edit instead of delete. But you are right delete is more mistake proof.
sectroyer
Official SamyGO Developer
Posts: 6305
Joined: Wed May 04, 2011 5:10 pm

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by sectroyer »

Okay glad you have everything working
I do NOT support "latest fw" at ALL. If you have one you should block updates on router and wait for it to STOP being "latest":)
If you want me to help you please paste FULL log(s) to "spoiler"/"code" bbcodes or provide link(s) to pasted file(s) on https://pastebin.com Otherwise "NO HELP"!!!
If you want root DISABLE internet access to your device!!!!
DO NOT EVER INSTALL FIRMWARE UPGRADE !!!!
User avatar
juusso
SamyGO Moderator
Posts: 10129
Joined: Sun Mar 07, 2010 6:20 pm

Re: Fixing SamyGO telnet/SSH/SCP/bash on C series

Post by juusso »

For D series i did part of E series recomendations and got scp + history:
sectroyer wrote:For scp we also needto change dropbearmulti to the one from the archive. Then we just make a symbolic link to dbclient:

Code: Select all

ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/bin/dbclient
ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/bin/scp
ln -s /mnt/opt/privateer/usr/sbin/dropbearmulti /mnt/opt/privateer/usr/sbin/dropbear
After this I have working bash history, telnet, ssh and scp :)
Used attached binaries. To start ssh just enable script ( 03_03_sshd.init )
LE40B653T5W,UE40D6750,UE65Q8C
Have questions? Read SamyGO Wiki, Search on forum first!
FFB (v0.8), FFB for CI+ . Get root on: C series, D series, E series, F series, H series. rooting K series, exeDSP/exeTV patches[C/D/E/F/H]

DO NOT EVER INSTALL FIRMWARE UPGRADE
gogo
SamyGO Project Donor
Posts: 185
Joined: Sat May 17, 2014 9:24 am
Location: Croatia

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by gogo »

When I start '03_03_sshd.init' script I get this error:

/mnt/opt/privateer/usr/sbin/dropbear: line 1: syntax error: unexpected word (expecting ")")
Samsung TV: UE46F6500
bobiturboto
SamyGO Project Donor
Posts: 489
Joined: Sun Mar 23, 2014 8:15 pm
Location: Bulgaria

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by bobiturboto »

gogo wrote:When I start '03_03_sshd.init' script I get this error:

/mnt/opt/privateer/usr/sbin/dropbear: line 1: syntax error: unexpected word (expecting ")")
If you have F series you need to follow the instructions from here and should work viewtopic.php?f=63&t=7455&p=61496#p60720
Tested with F8000
Keep in your mind if you use ftp for dropbear file transfer, the transfer mode needs to be binary type.
gogo
SamyGO Project Donor
Posts: 185
Joined: Sat May 17, 2014 9:24 am
Location: Croatia

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by gogo »

bobiturboto wrote:
gogo wrote:When I start '03_03_sshd.init' script I get this error:

/mnt/opt/privateer/usr/sbin/dropbear: line 1: syntax error: unexpected word (expecting ")")
If you have F series you need to follow the instructions from here and should work viewtopic.php?f=63&t=7455&p=61496#p60720
Tested with F8000
Keep in your mind if you use ftp for dropbear file transfer, the transfer mode needs to be binary type.
I forgot type binary in ftp shell
Samsung TV: UE46F6500
gogo
SamyGO Project Donor
Posts: 185
Joined: Sat May 17, 2014 9:24 am
Location: Croatia

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by gogo »

Why this command don't work?

umount /mtd_rwarea/passwd
umount: can't umount /mtd_rwarea/passwd: Invalid argument
Samsung TV: UE46F6500
sectroyer
Official SamyGO Developer
Posts: 6305
Joined: Wed May 04, 2011 5:10 pm

Re: Fixing SamyGO telnet/SSH/SCP/bash on C/D/E/F series

Post by sectroyer »

gogo wrote:Why this command don't work?

umount /mtd_rwarea/passwd
umount: can't umount /mtd_rwarea/passwd: Invalid argument
because you are not using latest stuff :) As a result your /mtd_rwarea/passwd is not mounted. You can check it by running:

Code: Select all

mount
I do NOT support "latest fw" at ALL. If you have one you should block updates on router and wait for it to STOP being "latest":)
If you want me to help you please paste FULL log(s) to "spoiler"/"code" bbcodes or provide link(s) to pasted file(s) on https://pastebin.com Otherwise "NO HELP"!!!
If you want root DISABLE internet access to your device!!!!
DO NOT EVER INSTALL FIRMWARE UPGRADE !!!!

Post Reply

Return to “[F] Software”