Post

Routeur projet LEDE

Routeur projet LEDE

Routeur projet LEDE

LEDE a20-olinuxino-micro

The LEDE Project (“Linux Embedded Development Environment”) is a Linux operating system based on OpenWrt. It is a complete replacement for the vendor-supplied firmware of a wide range of wireless routers and non-network devices. See the Table of Hardware for supported devices. For more information about LEDE Project organization, see the About LEDE pages.

Installation image lede-17.01.4-sunxi-sun7i-a20-olinuxino-micro-ext4-sdcard.img.gz
sha256sum : 51752a40179598dd1ce99e50d16eb580652141bf0c3cb56c39769150bbe0a55d

Identifier SDcard : dmesg
Vérifier checksum : sha256sum lede-17.01.4-sunxi-sun7i-a20-olinuxino-micro-ext4-sdcard.img.gz
Flash de la SDcard (en mode su)
zcat lede-17.01.4-sunxi-sun7i-a20-olinuxino-micro-ext4-sdcard.img.gz > /dev/sdx #remplacer sdx par celui vu dans dmesg

Connecter un adaptateur USB/Série et lancer minicom en mode su
Insérer la SDcard et connecter l’alimentation

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
BusyBox v1.25.1 () built-in shell (ash)

     _________
    /        /\      _    ___ ___  ___
   /  LE    /  \    | |  | __|   \| __|
  /    DE  /    \   | |__| _|| |) | _|
 /________/  LE  \  |____|___|___/|___|                      lede-project.org
 \        \   DE /
  \    LE  \    /  -----------------------------------------------------------
   \  DE    \  /    Reboot (17.01.4, r3560-79f57e422d)
    \________\/    -----------------------------------------------------------

=== WARNING! =====================================
There is no root password defined on this device!
Use the "passwd" command to set up a new password
in order to prevent unauthorized SSH logins.
--------------------------------------------------
root@LEDE:/# 

Routeur Linksys WRT54GL

Model No : WRT54GL v1.1
S/N : CL7B6M102711
MAC 20:AA:4B:08:5A:FD
FG No : 1000-06571

alt text

WRT54GL version Vitesse CPU RAM Mémoire flash Préfixe du numéro de série Chipset Notes
1.1 200MHz 16MB 4MB CL7B CL7C Broadcom BCM5352Exxx Rev. 0.8 La particularité de ce processeur, c’est qu’il peut être surcadencé jusqu’à 250 MHz en agissant directement sur le paramètre adéquat en nvram. Pour monter plus haut, une version patchée du CFE est nécessaire.

Ajout carte SD

Les cartes MMC/SD sont équipées d’une interface SPI qui facilite la connexion au routeur via les lignes GPIO. Il y a 4 connexions: CS, DI, DO et CLK. En plus de 3.3V et Masse.

Adding SD card to WRT54GL

Pin Direction WRT54GL Name SD Card Name color
GPIO 0 (Output) Unknown Not used  
GPIO 1 Output POWER LED Not used  
GPIO 2 Output WHITE LED DI/MOSI Green
GPIO 3 Output AMBER LED CLK/SCK Blue
GPIO 4 Input FRONT BUTTON DO/MISO Yellow
GPIO 5 Output Unknown Not used  
GPIO 6 Input Unknown Not used  
GPIO 7 Output DMZ LED CS Orange

alt text

1-Télécharger le module http://programmingstuff.free.fr/files/openwrt/whiterussian/mmc/1_3_4/gpio2/mmc.o dans le dossier /lib/modules/2.4.37.9/

1
2
cd /lib/modules/2.4.37.9
wget http://programmingstuff.free.fr/files/openwrt/whiterussian/mmc/1_3_4/gpio2/mmc.o

2-Masque GPIO pour le WRT54GL qui utilise GPIO line 2, 3, 4, et 7 https://wiki.openwrt.org/oldwiki/port.gpio?s[]=adding%20up:
Hex values: 0x04 + 0x08 + 0x10 + 0x80 = 0x9c

1
echo 09c > /proc/diag/gpiomask

3-Charger le module

1
insmod mmc

OpenWrt

Site https://wiki.openwrt.org

Techdata: Linksys WRT54GL 1.0, 1.1
Linksys WRT54G, WRT54GL and WRT54GS
Setup OpenVPN using OpenWRT
OpenWRT, Access Point only config. LAN and PUBLIC wireless on an existing subnet

Linksys WRT54GL 1.0, 1.1 OpenWrt 10.03.1 –> http://downloads.openwrt.org/backfire/10.03.1/brcm-2.4/

A partir du “firmware update” de Linksys web http://192.168.1.1 , charger le firmware openwrt-wrt54g-squashfs.bin
Se connecter en “USB/Serial”

1
sudo minicom

lors de votre première connexion à OpenWrt, réglez les paramètres NVRAM suivants pour activer tftpd au démarrage:

1
2
3
4
nvram set boot_wait=on
nvram set boot_time=10
nvram set wait_time=10
nvram commit && reboot

Se reconnecter

1
sudo minicom
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
BusyBox v1.15.3 (2011-11-24 02:12:13 CET) built-in shell (ash)
Enter 'help' for a list of built-in commands.

  _______                     ________        __
 |       |.-----.-----.-----.|  |  |  |.----.|  |_
 |   -   ||  _  |  -__|     ||  |  |  ||   _||   _|
 |_______||   __|_____|__|__||________||__|  |____|
          |__| W I R E L E S S   F R E E D O M
 Backfire (10.03.1, r29592) ------------------------
  * 1/3 shot Kahlua    In a shot glass, layer Kahlua 
  * 1/3 shot Bailey's  on the bottom, then Bailey's, 
  * 1/3 shot Vodka     then Vodka.
 ---------------------------------------------------
root@OpenWrt:/# help
Built-in commands:
------------------
        . : [ [[ alias bg break cd chdir command continue echo eval exec
        exit export false fg getopts hash help jobs kill let local printf
        pwd read readonly return set shift source test times trap true
        type ulimit umask unalias unset wait

Modifier l’adresse IP Lan
vi /etc/config/network
Remplacer 192.168.1.1 par 192.168.0.70

Se connecter via le web http://192.168.0.70
Modifier le mot de passe administrateur
Télécharger le dernier openwrt-brcm-2.4-squashfs.trx
Aller dans “System/Flash Firmware” pour sélectionner et upgrader

Connexions possible
web : http://192.168.0.70
ssh : ssh root@192.168.0.70
Serial : sudo minicom (liaison USB/Serial)

Routeur wifi anonymisant avec Tor et OpenWRT
Configuration de base OpenWrt
Linksys Wrt54gl sous OpenWrt

Mode tftp

Pour garantir le fonctionnement du mode tftp (utiliser en cas de blocage du routeur pour charger un firmware)

1
2
3
4
nvram set boot_wait=on
nvram set boot_time=10
nvram set wait_time=10 #important for some models
nvram commit && reboot

On peut charger un firmware en mode tftp , pour cela il faut installer un client tftp sur le poste

1
yaourt -S tftp-hpa  # client tftp archlinux/manjaro

Firmware tomato

Tomato est un micrologiciel de remplacement petit, léger et simple pour les routeurs Linksys WRT54G/GL/GS, Buffalo WHR-G54S/WHR-HP-G54 et autres routeurs Broadcom. Il comporte une nouvelle interface graphique facile à utiliser, un nouveau moniteur d’utilisation de la bande passante, des restrictions d’accès et de QOS plus avancées, permet de nouvelles fonctionnalités sans fil telles que les modes WDS et clients sans fil, augmente les limites des connexions maximales pour P2P, vous permet d’exécuter vos scripts personnalisés ou telnet/ssh in et de faire toutes sortes de choses comme reprogrammer le bouton SES/AOSS, ajoute un sondage de site sans fil pour voir vos voisins wifi, et plus encore.

Tomato_1_28.zip (16MB / SHA1: 5bd25717048abb6b58d316f622bfd79434fe6451)

Charger le firmware via tftp

1
tftp 192.168.0.70 -c put WRT54G_WRT54GL.bin
Cet article est sous licence CC BY 4.0 par l'auteur.