Skip to content

RF MODEM Access POINT

wifiBlocker EUROPE edited this page Oct 15, 2024 · 29 revisions

Prerequisite

Alpine Linux installed, Apache Server installed and CGI enabled

/etc/hostname contains line:

iblocker80xy

where 80xy is the port on which the camera will be tunneled to server 8x.ab4.17z.22x:80xy. 80xy is the variable=remote_port.

The same hostname should be added also in /etc/hosts.

Packets:

apk add --no-cache musl-dev apache2 curl

apk add --no-cache openrc perl perl-dev make gcc

apk add --no-cache musl-dev     -mandatory for next cpan commands

cpan -i Device::Modem

cpan -i CGI

cpan -i Device::SerialPort

rc-service apache2 start

rc-update add apache2 

mkdir -p /opt/IB/BLOCKED_COUNTRIES/IPSETS

mkdir -p /var/www/localhost/cgi-bin/piwall/INSERTED

chown apache:www-data /var/www/localhost/cgi-bin/piwall/INSERTED

iBlocker *html and *cgi scripts copied to Alpine Linux, and LTE modem attached via USB cable.

Group

~# addgroup apache dialout

~# addgroup iblocker apache

Reboot


httpd.conf

Add ExecCGI in line "Options Indexes FollowSymLinks ExecCGI" in httpd.conf

Uncomment below lines:

 LoadModule cgi_module modules/mod_cgi.so

 ScriptAlias /cgi-bin/ "/var/www/localhost/cgi-bin/"

in httpd.conf


RIGHTS

mkdir /home/iblocker/BACKUP

chown apache:www-data /home/iblocker/BACKUP/

ROUTING

Add below lines in /etc/network/interfaces

auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp
iface eth0 inet6 dhcp
echo 2 > /proc/sys/net/ipv6/conf/eth0/accept_ra

auto wlan0
iface wlan0 inet static
address 172.25.1.1/24
iface wlan0 inet6 static
address fdda:8765:4321:fdda::1
netmask 64

IPv4

iptables -A FORWARD -i usb0 -j ACCEPT

iptables -t nat -A POSTROUTING -o usb0 -j MASQUERADE

/etc/init.d/iptables save

IPv6

ip6tables -A FORWARD -i usb0 -j ACCEPT

ip6tables -t nat -A POSTROUTING -o usb0 -j MASQUERADE

/etc/init.d/ip6tables save

Reboot.

NOTE: in case eth0 is used (instead of usb0), below commands should be used:

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

/etc/init.d/iptables save

ip6tables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

/etc/init.d/ip6tables save

Basic Operations


Modem


Cell ID


Simulator


Clone this wiki locally