User Tools

Site Tools


inbox:howto:telnet_enable

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

inbox:howto:telnet_enable [2012/10/06 14:16]
inbox:howto:telnet_enable [2013/06/27 12:25] (current)
Line 1: Line 1:
 ====== Enable telnet login with password ====== ====== Enable telnet login with password ======
 ===== (Without dropbear) ===== ===== (Without dropbear) =====
-  +This is useful if you don't mind **security** and you don't have **enough space or resources** for dropbear in your device. 
-Patch your build tree: +Tested succesfully in Backfire 10.03.2 
- +  - Patch your build tree with this file\\ <code diff>
-<code diff>+
 Index: package/​base-files/​files/​bin/​login.sh Index: package/​base-files/​files/​bin/​login.sh
 =================================================================== ===================================================================
---- package/​base-files/​files/​bin/​login.sh +--- package/​base-files/​files/​bin/​login.sh (revision: 33603) 
-+++ package/​base-files/​files/​bin/​login.sh ++++ package/​base-files/​files/​bin/​login.sh (copia de trabajo) 
-@@ -2,+2,@@+@@ -2,15 +2,14 @@
  # Copyright (C) 2006-2010 OpenWrt.org  # Copyright (C) 2006-2010 OpenWrt.org
    
Line 20: Line 19:
  cat << EOF  cat << EOF
   === IMPORTANT ============================   === IMPORTANT ============================
-@@ -11,6 +11,5 @@ +   Use '​passwd'​ to set your login password 
-   ​this will disable telnet and enable SSH+-  ​this will disable telnet and enable SSH 
 ++  this will enable telnet login with password
   ------------------------------------------   ------------------------------------------
  EOF  EOF
Line 28: Line 28:
 - -
 -exec /bin/ash --login -exec /bin/ash --login
-</​code>​ + 
-<​code>​make menuconfig</​code>​ +</​code>​ Copy the above content to a file: //​telnet_enable.patch//​. And patch your build tree \\ <​code>​patch -p0 -i telnet_enable.patch</​code>​ 
-Enable login at Location: +  - Configure the build tree \\ <​code>​ 
-<​code>​+make menuconfig 
 +</​code>​ Enable ​**//login//** at Location: <​code>​
 -> Base system ​ -> Base system ​
    -> busybox    -> busybox
      -> Configuration ​      -> Configuration ​
         -> Login/​Password Management Utilities         -> Login/​Password Management Utilities
-</​code>​ +</​code>​ <​code>​
-<​code>​+
 ┌──────────────────────── Login/​Password Management Utilities ────────────────────────┐ ┌──────────────────────── Login/​Password Management Utilities ────────────────────────┐
-│  Arrow keys navigate the menu.  <​Enter>​ selects submenus --->​. ​ Highlighted letters │  ​ 
-│  are hotkeys. ​ Pressing <Y> includes, <N> excludes, <M> builds as package. ​ Press   ​│  ​ 
-│  <​Esc><​Esc>​ to exit, <?> for Help, </> for Search. ​ Legend: [*] built-in ​ [ ]       ​│  ​ 
-│  excluded ​ <M> package ​ < > package capable ​                                        ​│  ​ 
 │ ┌─────────────────────────────────────────────────────────────────────────────────┐ │  ​ │ ┌─────────────────────────────────────────────────────────────────────────────────┐ │  ​
 │ │ [ ] Support for shadow passwords ​                                               │ │  ​ │ │ [ ] Support for shadow passwords ​                                               │ │  ​
Line 62: Line 58:
 │ │ [ ]   Check new passwords for weakness ​                                         │ │  ​ │ │ [ ]   Check new passwords for weakness ​                                         │ │  ​
 │ │ [ ] cryptpw ​                                                                    │ │  ​ │ │ [ ] cryptpw ​                                                                    │ │  ​
 +│ └─v(+)────────────────────────────────────────────────────────────────────────────┘ │  ​
 +├─────────────────────────────────────────────────────────────────────────────────────┤  ​
 +│                          <​Select> ​   < Exit >    < Help >                           ​│  ​
 +└─────────────────────────────────────────────────────────────────────────────────────┘ ​
 +</​code>​ Disable **//​dropbear//​** at Location: <​code>​ -> Base system
 +</​code>​ <​code>​
 +┌──────────────────────────────────── Base system ────────────────────────────────────┐
 +│ ┌─────────────────────────────────────────────────────────────────────────────────┐ │  ​
 +│ │ <*> base-files................................... Base filesystem for OpenWrt ​  │ │  ​
 +│ │ < > block-hotplug...................... Automount and autocheck block devices ​  │ │  ​
 +│ │ < > br2684ctl.................... ATM Ethernet bridging configuration utility ​  │ │  ​
 +│ │ < > bridge........................... Ethernet bridging configuration utility ​  │ │  ​
 +│ │ <*> busybox................................ Core utilities for embedded Linux  -│ │  ​
 +│ │ < > dnsmasq................................ A lightweight DNS and DHCP server ​  │ │  ​
 +│ │ < > dropbear........................................ Small SSH2 client/​server ​  │ │  ​
 +│ │ < > ead.............................................. Emergency Access Daemon ​  │ │  ​
 +│ │ < > firewall................................................ OpenWrt firewall ​  │ │  ​
 +│ │ <*> hotplug2 ​                                                                   │ │  ​
 +│ │ <*> libc........................................................... C library ​  │ │  ​
 +│ │ <*> libgcc............................................... GCC support library ​  │ │  ​
 +│ │ --- libpthread.......................................... POSIX thread library ​  │ │  ​
 +│ │ --- librt................................ POSIX.1b RealTime extension library ​  │ │  ​
 +│ │ < > libstdcpp.................................... GNU Standard C++ Library v3   │ │  ​
 +│ │ <*> mtd............................... Update utility for trx firmware images ​  │ │  ​
 +│ │ <*> opkg...................................... opkg package management system ​  │ │  ​
 │ └─v(+)────────────────────────────────────────────────────────────────────────────┘ │  ​ │ └─v(+)────────────────────────────────────────────────────────────────────────────┘ │  ​
 ├─────────────────────────────────────────────────────────────────────────────────────┤  ​ ├─────────────────────────────────────────────────────────────────────────────────────┤  ​
Line 67: Line 88:
 └─────────────────────────────────────────────────────────────────────────────────────┘ ​ └─────────────────────────────────────────────────────────────────────────────────────┘ ​
 </​code>​ </​code>​
- +  - Now compile OpenWrt <​code>​ 
-Build your system without dropbear (ssh daemon). Next time you set a password you'​ll ​login via telnet.+make V=99 
 +</​code>​ 
 +  - Flash the built firmware into your device. Set a password with **passwd**. Next time you login via telnet ​it will prompt your root password.
inbox/howto/telnet_enable.1349525813.txt.bz2 · Last modified: 2012/10/06 14:16 (external edit)