Piratebox for A5-V11 Router

Posted by Timeless 
This forum is currently read only. You can not log in or make any changes. This is a temporary situation.
Now, this forum is in read-only mode. You find details Details hereContinue on /r/PirateBox
Piratebox for A5-V11 Router
May 18, 2015 07:51PM
Hi PiratePeople smiling smiley

I have some questions about the general OpenWRT releases. I have a 8USD A5-V11 also known as a "Generic Ebay 3/4g Modem router"

I managed to run OpenWRT Chaos Calmer with Overlay on a External ext4 partition of 50MB. This device itself has only 4MB of flash.

But now I want to install PirateBox 1.0 to this device. I followed the Tutorial "Link" but this it seems that the .sig file is missing so the signature check fails.

I tried to install the [piratebox_1.0.1-8_all.ipk] package manually. But it fails for some reason on a Extroot partition. But my device already has a overlay of 50MB so plenty of space for a Piratebox installtion I guess?

Can someone assist me on how to install PirateBox on a generic Chaos Calmer OpenWRT release?

Regards,
Time

"The greatest good you can do for another, is not to share your own riches, but to reveal to him, his own."
- Benjamin Disraeli -
Re: Piratebox for A5-V11 Router
May 19, 2015 04:10PM
Close, but not close enough winking smiley
This tutorial explains how to come from a plain device to a piratebox using the extroot, you already managed to configure.

Hope that helps,
moving this thread to openwrt.

best regards
Matthias


This is only my signature.
Piratebox for A5-V11 Router
May 19, 2015 04:10PM
-- moved topic --

"The greatest good you can do for another, is not to share your own riches, but to reveal to him, his own."
- Benjamin Disraeli -
Re: Piratebox for A5-V11 Router
May 19, 2015 04:45PM
But what about the Overlay?
Does it need to be Extroot? isn't Overlay enough?

Because according to your suggested tutorial it seems that some terms are using the wrong way?
It does mention "Enable extroot" while the command states "uci set fstab.@mount[-1].target=/overlay" which really is just the Overlay Partition.

This makes everything a Little complicated.

But it seems that PirateBox does support Chaos Calmer (aka newest trunk as for 18-05-2015) on a A5-V11 target then?
Re: Piratebox for A5-V11 Router
May 19, 2015 04:50PM
How you create additional storage (overlay, exchange) doesn't matter! It is only important (for that howto) that you have enough space on your / partition.
Skip those parts about extroot.

Using this difficult technique, piratebox will work on the latest trunk images. .. but it is not "noobie save" enough to make it available for all.


This is only my signature.
Re: Piratebox for A5-V11 Router
May 19, 2015 06:13PM
Hi,

Ok, what about the space requirements? its not specifically mentioned. It seems that 50MB is not enough because my installer freezes during configuration piratebox. and after a reboot my 52MB is 100% used.

Im now going to try with a 258MB overlay partition.
Re: Piratebox for A5-V11 Router
May 19, 2015 06:57PM
Ok. great I've managed to install Piratebox partly. Thanks! I really like the project.

The problem I had was that during the installation SSH disconnects so aborting every command that it executed (opkg install *** in this case). I created a script to run the "opkg install piratebox" command so this cannot happen. Also ipv6 support was missing on my image(removed to save space on the 4MB flash) so Installed it on the overlay partition anyway.

Another thing, I like to have LuCi installed. And so it was. But during the install Piratebox seems to replace LuCi partly while LuCi used uhttpd and piratebox lighttpd so it should not interfere I guess. So I had to move the LuCi www folder somewhere else. So Piratebox finds its own.

When i got to 192.168.1.1 I get the Piratebox main page now. But nothing actually works. Chat is not responding and the tabs "Files" "Forum" is not working (result in error 404). I have to Files directory in my www folder. but there is nothing useful inside? how is this configured? is there an application normally listening on these directories or something?

When I go to 192.168.1.1:8080 I get some sort of File upload page. When I upload something its placed on /mnt/usb/Shared which is the mount to my USB stick. So Piratebox main part is working. but thats about it sad smiley could it be that DNSmask is not running? im not using the Piratebox DNS actually


What could be the problem?



Edited 2 time(s). Last edit at 05/19/2015 07:12PM by Timeless.
Re: Piratebox for A5-V11 Router
May 19, 2015 08:36PM
Quote

Another thing, I like to have LuCi installed. And so it was. But during the install Piratebox seems to replace LuCi partly while LuCi used uhttpd and piratebox lighttpd so it should not interfere I guess. So I had to move the LuCi www folder somewhere else. So Piratebox finds its own.
No, it is not directly interfering, but uhttpd (i think that is the name) gets deactivated during the installation. You need to change the port of it in /etc/config/uhttpd
after that run the following to re-enable it
/etc/init.d/uhttpd enable 
/etc/init.d/uhttpd start
Keep in mind, that you can't change dependend configuration in opt/piratebox like your IP. PirateBox is not designed to work together with the default uci stuff.


Quote

But nothing actually works. Chat is not responding
That might the bug, described in one of the other threads (too lazy to search it).
The problem is, that the timestamp of the chat.html file is in the year 1970, which seems to not be refreshed by the javascript on the browser- until the chat file is once rewritten (due to a message).

Quote

and the tabs "Files"
As you run on ext3 based filesystem, maybe some permissions are wrong or the linked folder does not exists.
Quote

"Forum" is not working (result in error 404)
imageboard and minidlna is not covered by that howto

Quote

I have to Files directory in my www folder. but there is nothing useful inside? how is this configured? is there an application normally listening on these directories or something?
Not pretty sure what you are asking. Can rephrase the questions again please?

Quote

When I go to 192.168.1.1:8080 I get some sort of File upload page. When I upload something its placed on /mnt/usb/Shared which is the mount to my USB stick. So Piratebox main part is working.
Good

Quote

but thats about it sad smiley could it be that DNSmask is not running? im not using the Piratebox DNS actually
That is the reason why, yes. The hostname is hardcoded in the index.html

best regards Matthias
Re: Piratebox for A5-V11 Router
May 19, 2015 09:13PM
Hi,

Thanks for your help so far! great assistance.
Quote

That might the bug, described in one of the other threads (too lazy to search it).
The problem is, that the timestamp of the chat.html file is in the year 1970, which seems to not be refreshed by the javascript on the browser- until the chat file is once rewritten (due to a message).
The problem is when I type something in the chat window and press [send] nothing happens. When I reset the page it shows some error for less than a second so its hard to tell what it is. The error message is:

Triggered ajaxError handler on shoutbox

Quote

As you run on ext3 based filesystem, maybe some permissions are wrong or the linked folder does not exists.
I do get some errors in the Part2 installation:
root@piratebox:/mnt/usb/PirateBox# /opt/piratebox/bin/install_piratebox.sh  /opt/piratebox/conf/piratebox.conf part2
Starting initialize PirateBox Part2..
Distribute HEADER.txt into /opt/piratebox/share/Shared
Distribute README.txt into /opt/piratebox/share/Shared
chown: /opt/piratebox/share: Operation not permitted
chown: /opt/piratebox/www/board: Operation not permitted
chown: /opt/piratebox/www/Shared: Operation not permitted
and the linked folders are still owned by root. My overlay is formatted as ext4 and my usb folder is vfat. I cannot change the permission of either of the folders.

I quess that this is the problem?
It does not seem to be my problem, because when I mount my vfat partition as another user, in this case "nobody" which will set all permissions as expected. but still I'm unable to visit the Files page. sad smiley

root@piratebox:/opt/piratebox/www# ls -l
lrwxrwxrwx    1 root     root            27 May 19 19:59 Shared -> /opt/piratebox/share/Shared
lrwxrwxrwx    1 root     root            26 May 19 19:59 board -> /opt/piratebox/share/board
drwxr-xr-x    2 nobody   nogroup       1024 Dec 26 08:15 cgi-bin
-rw-rw-r--    1 nobody   nogroup        289 May 19 19:59 chat_content.html
-rwxr-xr-x    1 nobody   nogroup       1406 Dec 26 08:15 favicon.ico
-rw-r--r--    1 nobody   nogroup          0 May 19 19:59 forban_link.html
-rw-r--r--    1 nobody   nogroup       3776 Dec 26 08:15 index.html
-rwxr-xr-x    1 nobody   nogroup      94840 Dec 26 08:15 jquery.min.js
drwxr-xr-x    3 nobody   nogroup       1024 Dec 26 08:15 library
-rw-r--r--    1 nobody   nogroup       2992 Dec 26 08:15 menu.png
-rw-r--r--    1 nobody   nogroup         15 Dec 26 08:15 ncsi.txt
-rw-r--r--    1 nobody   nogroup       6607 Dec 26 08:15 piratebox-logo-horizontal-white.png
-rwxr-xr-x    1 nobody   nogroup      12637 Dec 26 08:15 piratebox-logo-small.png
-rwxr-xr-x    1 nobody   nogroup        201 Dec 26 08:15 redirect.html
-rwxr-xr-x    1 nobody   nogroup       3715 Dec 26 08:15 scripts.js
-rw-r--r--    1 nobody   nogroup          0 Dec 26 08:15 station_cnt.txt
-rw-r--r--    1 nobody   nogroup       5040 Dec 26 08:15 style.css

Quote

Not pretty sure what you are asking. Can rephrase the questions again please?

What I mean is that the www/Shared/ folder only contains 2 files (excluding the files I uploaded) HEADER.txt and README.txt. is this normal? shouldn't there be a Index.html in that folder? The SHARED link is still owned by root so maybe that is why I get the 404 error? when I make a copy of the HEADER.txt file and name it index.html I get the basic layout of the website. but thats about it. no files sad smiley

Quote

No, it is not directly interfering, but uhttpd (i think that is the name) gets deactivated during the installation. You need to change the port of it in /etc/config/uhttpd
after that run the following to re-enable it

/etc/init.d/uhttpd enable
/etc/init.d/uhttpd start

Keep in mind, that you can't change dependend configuration in opt/piratebox like your IP. PirateBox is not designed to work together with the default uci stuff.
Yeah you are indeed correct. I changed the port to 8080 initialy not knowing that port 8080 is already used. When I changed it to another port LuCi started working again.



Edited 1 time(s). Last edit at 05/19/2015 10:02PM by Timeless.
Re: Piratebox for A5-V11 Router
May 19, 2015 10:32PM
Ok... wait.

It seems that everything is configured OK... but Firefox was simply the problem.
When I visit my Piratebox with InternetExplorer then everything works as expected. I can even download my uploaded files. and the Shoutbox is also working smiling smiley.

Firefox was expecting a specific date format (dd,mm,yyyy instead of dd-mm-yyyy) for the shoutbox and Files. but it is now fixed smiling smiley

Great, I Have a working PirateBox now.

The only thing is. when I try to visit http://[something].[some_extention] I get redirected to the PirateBox, which is good. But this does not work fot https:// sites. So if someone has a https:// page in his request he/she will get a timeout or 404 error.



Edited 3 time(s). Last edit at 05/19/2015 10:43PM by Timeless.
Re: Piratebox for A5-V11 Router
May 20, 2015 06:56PM
https is not supported, because it is encrypted.
In addition we don't want to exploid SSL certificates, so we simply doesn't answer requests on this port


This is only my signature.
Re: Piratebox for A5-V11 Router
May 25, 2016 09:58PM
Hey Timeless, I just grabbed one of these off dx.com. This post is about a year old. When it comes in, I will adapt this tutorial to the A5-V11 device and make changes as needed. Once I have something working, I will write out a wiki page on it.


PirateBox Installs:
2x Zsun's (both testing, one with serial interface)
A5-V11 (mostly for OpenWRT testing DIY)
2x RPi Zero's
(one active in car 24/7, gets a lot of hits at Walmart, movie theaters and the mall)
2x RPi3's (both home servers, one Ubuntu custom install along side a ton of other services)
1x RPi2 (currently work server)



Edited 1 time(s). Last edit at 10/01/2017 05:53PM by TheExpertNoob.