How to install a program on a DDWRT hacked router

66

Solution 1

To install things on a router with DD-WRT, you must enable a few things in the router administration interface. First, enable JFFS2 on the Management tab of the Administration section. Second, enable SSHd on the Services tab of the Services section. If you need to access files from another computer, the easiest way is to share them via Windows File Sharing/SMB, and then mount it via the CIFS Automount section of the Management tab of the Administration section. You can also use SCP if you desire.

Once you've done that, you can access your router via SSH. To do so on Linux and Mac OS X, just run ssh [router IP address]. To do so on Windows, you'll need PuTTY or another SSH client.

Once you're on, you have access to a full Linux BusyBox shell. But, that's only half the battle. Routers don't come with x86-based processors, so you can't just copy a binary from a Linux machine and have it work. It has to be compiled for the processor included with your particular router and designed to work on BusyBox.

However, there are many packages compiled for routers, that can be installed with the package manager created by the OpenWRT project and included with DD-WRT, called ipkg (as another user indicated while I was writing this answer). The ipkg documentation has instructions for using the ipkg command and several sources of packages for DD-WRT.

Solution 2

You can use the ipkg package tool from openwrt: http://www.dd-wrt.com/wiki/index.php/Ipkg

Share:
66

Related videos on Youtube

Dominik
Author by

Dominik

Updated on September 17, 2022

Comments

  • Dominik
    Dominik over 1 year

    How would I redirect all pages on my website that have /de/.php or /en/.php in the URL? I dont want to redirect domain.com/index.php though, only domain.com/de/.php or /en/*.php.

    • Justin Iurman
      Justin Iurman over 9 years
      A 301 redirect, right but... Where to?
    • Dominik
      Dominik over 9 years
      to the main domain only, so to domain.com
  • Dominik
    Dominik over 9 years
    Thank you! I added it to my .htaccess but domain.com/de/test.php still gives me a 404 instead of 301.
  • Justin Iurman
    Justin Iurman over 9 years
    Did you put RewriteEngine On before ? Is your htaccess in root folder ? Are mod_rewrite enabled and htaccess allowed in your Apache config ?
  • Dominik
    Dominik over 9 years
    I did, however the .htaccess was pretty long and at the bottom it didnt work. I moved it up right after RewriteEngine On and it works like a charm now. Thank you!