Setting up Satellite Internet Connection: Difference between revisions

From Alpine Linux
(22 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[Category:Networking]]
= Satellite Internet Connection HOW-TO =
= Satellite Internet Connection HOW-TO =


== Introduction ==
== Introduction ==


This document briefly explains Satellite technology, how it works, what do you need, configuration and how to sharing it between several clients. So the main focus is the Internet connection, satellite TV is not reviewed.
This document briefly explains Satellite technology, how it works, what you need, configuration, and how to share it between several clients. The main focus is an Internet connection, i.e. satellite TV is not covered.


== How does it work? ==
== How does it work? ==


So first we make the request (using land Internet connection) to the Sat-Server usually via a tunnel, after it will retrieve out info from Internet and it will send it to Satellite; in the end we would receive data from the it to our home using a parabolic antenna and a Sat Card.   
First we make the request (using a land Internet connection) to the Sat-Server usually via a tunnel. It will retrieve our info from the Internet and send it to the Satellite. Ultimately, we'll receive data from the satellite to our home using a parabolic antenna and a Sat Card.   


Satellite works very well with protocols, which have a little request data and a much bigger answer size. Although, a big time of answer is the biggest problem of satellite connection that may prevent using interactive services such as VoIP. The delay of answer may be considered basing on that a typical Sat distance is like 36.000 km, so an average overall delay time is 300-400 ms.   
Satellite works very well with protocols which have a small request data size and a much larger answer size. Large response delay is the biggest problem with satellite internet service. That may prevent using interactive services such as VoIP. The delay is caused by the distance the satellite is from the earth's surface,
typically 36000 km. Average overall delay time is 300-400 ms.   


To install the little satellite system we need:
To install the satellite system we need:


* DVB-S Card
* DVB-S Card
* Parabolic Antenna (Satellite Dish)
* Parabolic Antenna (Satellite Dish)
* LNB Digital Converter  
* LNB Digital Converter


== Technical Information ==
== Technical Information ==


A satellite link as a classical Wireless link is very different from Wired link. It may cause some additional problems to solve, such as reachability, privacy problems and so on. Also there could be weather problems, particularly in snow or rain conditions.   
A satellite link as is very different from Wired link. It may cause additional problems such as reachability, privacy, etc. There could also be weather related problems, particularly in snow or rain conditions.   


=== Antenna / Converter ===
=== Antenna / Converter ===
   
   
A parabolic antenna gives a very high gain in RX. A frequency that is being received from the satellite transponder is from 11GHz up to 12.7 GHz. The Digital Converter transforms it to 1-2 GHz and send signal to the DVB-S card receiver through the coax cable up to 30-40m. This documents assumes that your parabolic antenna is properly mounted and calibrated as well as proper converter (usually Ku-band) is used.
A parabolic antenna has a very high gain. The satellite transponder frequency is from 11 GHz to 12.7 GHz. The Digital Converter translates it to 1-2 GHz and sends the signal to a DVB-S card receiver through as much as 30-40 km of coaxial cable. This document assumes your parabolic antenna is properly mounted and boresighted as well as the proper converter (usually Ku-band) is used.


=== DVB-S Receiver Card ===   
=== DVB-S Receiver Card ===   


DVB-S card receives analog signals via coax cable and converts it to digital signals pretty like Ethernet card, after that the OS transforms it to a TCP/IP packets.
DVB-S card receives analog signals via coax cable and converts them to digital signals similar to those found on an Ethernet. After that, the OS transforms it to TCP/IP packets.


== DVB Setup ==
== DVB Setup ==


'''1. Install DVB-S Card and check if system recognized it'''
===Install DVB-S Card and check if system recognized it===


Please note, that in most cases you need PCI version 2.1 or higher (check DVB card specifications). In practice it is Pentium-III or later systems.
Note: in most cases you need PCI version 2.1 or later (check your DVB card specifications) i.e. a Pentium-III or newer system.


  # lspci | grep -i "multimedia controller"
{{Cmd|lspci | grep -i "multimedia controller"}}


'''2. Make sure that kernel modules are loaded'''
===Make sure that kernel modules are loaded===


You have to use Alpine 1.7.10 release or higher that should load appropriate kernel modules for DVB card on startup. You may check if DVB devices are installed.
You must use Alpine 1.7.10 release or newer that should load appropriate kernel modules for DVB card on startup. To check if DVB devices are installed, run:


  # ls -la /dev/dvb*
{{Cmd|ls -la /dev/dvb*}}


'''3. Install LinuxTV Applications'''
===Install LinuxTV Applications===
    
    
  # apk_add linuxtv-dvb-apps
{{Cmd|apk_add linuxtv-dvb-apps}}


'''4. Create and edit file ''channels.conf'''''
===Create and edit file ''channels.conf''===


This file contains settings for each Satellite you are using. For example the satellite ''Sirius-4 Nordic Beam'' has the following parameters: Freq - 12322Mhz, Polarization - vertical, Symbol Rate - 27.654711Ms/s, FEC -7/8.
channels.conf contains settings for each Satellite you are using. For example the satellite ''Sirius-4 Nordic Beam'' has the following parameters:


Anyway, all parameters you have to receive from ISP or find in the Internet. Please look at [http://www.sat2k.com/ivs.htm Satellite Parameters] and [http://www.ses-sirius.com/english/ SES SIRIUS].  
* Freq - 12322Mhz
* Polarization - vertical
* Symbol Rate - 27.654711Ms/s
* FEC -7/8.
 
You'll need to get the parameters from your ISP or find them on the Internet. See [http://www.sat2k.com/ivs.htm Satellite Parameters] and [http://www.ses-sirius.com/english/ SES SIRIUS].  


The following example is for "Sirius-4 Nordic Beam":
The following example is for "Sirius-4 Nordic Beam":


  # echo "Sirius4-Nord:12322:v:0:27500:0:0:0" >> /etc/channels.conf
{{Cmd|echo "Sirius4-Nord:12322:v:0:27500:0:0:0" >> /etc/channels.conf}}


'''5. Tune DVB Receiver'''
===Tune DVB Receiver===


Check configured channels:
Check configured channels:


  # szap -c /etc/channels.conf -q
{{Cmd|szap -c /etc/channels.conf -q}}


Tune the channel number 001:
Tune to channel number 001:


  # szap -c /etc/channels.conf -n 1
{{Cmd|szap -c /etc/channels.conf -n 1}}


In some cases you may need to run this command permanently in background because of a bug in kernel modules for some dvb cards.
In some cases you may need to run this command permanently in the background because of a bug in the kernel modules for some dvb cards.


  Option A:
* Option A:


      # szap -c /etc/channels.conf -n 1 > /dev/null 2>&1 &
{{Cmd|szap -c /etc/channels.conf -n 1 > /dev/null 2>&1 &}}


  Option B:
* Option B:


      # start-stop-daemon --start --background --exec /usr/bin/szap -- -c /etc/channels.conf -n 1
{{Cmd|start-stop-daemon --start --background --exec /usr/bin/szap -- -c /etc/channels.conf -n 1}}


'''6. Set up DVB network interface'''
===Set up DVB network interface===


Your ISP provides you the PID, which is used for select a transmission between many signal from same frequency.
Your ISP provides you the PID, which is used for select a particular transmission from many signals on the same frequency.


  # dvbnet -a 0 -p $PID
{{Cmd|dvbnet -a 0 -p $PID}}


  # ifconfig dvb0_0 hw ether $MAC
{{Cmd|ifconfig dvb0_0 hw ether $MAC
  # ifconfig dvb0_0 $IP netmask 255.255.255.255 up
ifconfig dvb0_0 $IP netmask 255.255.255.255 up}}


Here $IP is any IP address, which does not match with any other adrres in your network. The $MAC you specify here is usually the MAC address of your DVB card, in some cases ISP calculates MAC address for you. In any case ISP sends data only for registered MAC addresses.
Here $IP is any IP address, which does not match any address on your network. The $MAC you specify here is usually the MAC address of your DVB card, in some cases ISP supplies MAC address for you. In any case, the ISP sends data only for registered MAC addresses.


Due to nature of satellite connection, the dvb interface receives packets, which have been originated from other sources, actually ether from land internet connection interface or, in most cases, from virtual tunnel device. So in order to allow receiving such packets the source validation should be disabled on dvb0_0 interface.   
Due to the nature of a satellite connection, the DVB interface receives packets, which have originated from other sources, usually from either a land internet connection or, in most cases, from a virtual tunnel device. In order receive such packets, the source validation should be disabled on the dvb0_0 interface.   


  # echo "0" > /proc/sys/net/ipv4/conf/dvb0_0/rp_filter
{{Cmd|echo "0" > /proc/sys/net/ipv4/conf/dvb0_0/rp_filter}}


Another way to achieve that is to allow the shorewall to control that using ROUTE_FILTER and routefilter parameters.
Another way to achieve that is to allow shorewall to control it using ROUTE_FILTER and routefilter parameters.


'''7. Test if satellite interface is receiving data'''
===Test if satellite interface is receiving data===


You should see many packets for other clients of your ISP.
You should see many packets for other clients of your ISP.


  # apk_add tcpdump
{{Cmd| apk add tcpdump}}
  # tcpdump -n -i dvb0_0
{{Cmd|tcpdump -n -i dvb0_0}}


== Authentication with ISP ==
== Authentication with ISP ==


Before you receive your data via satellite your ISP should authenticate you as their registered client. There are several common techniques could be used:
Before you receive your data via satellite, your ISP should authenticate you as their registered client. There are several common techniques in use:


* Some ISPs use the "Proxy Authentication", when you used their proxy, you also need to give login and password to continue the request. Once done, the ISP use your IP address to calculate your MAC address, to which send the answer.   
* Some ISPs use "Proxy Authentication." When you use their proxy, you also need to supply a login name and password to continue the request. Once done, the ISP uses your IP address to calculate your MAC address, to which it sends the answer.   


* Some other ISPs require you make a VPN connection (using your login and password) first, then they will control your registration account (where they retrieve your MAC address) and will send data to your card (your MAC address).   
* Other ISPs require you to make a VPN connection (using your login and password) first, then they will control your registration account (where they retrieve your MAC address) and will send data to your card (your MAC address).   


* If you have static public IP, perhaps, the most convenient way is when ISPs suggest making a GRE/IPIP tunnel, which is used to sent authenticated requests to ISP satellite server. Consequently ISP sends back answers via satellite you are connected to.
* If you have a static public IP, perhaps the most convenient way is when ISPs suggest making a GRE/IPIP tunnel which is used to send authenticated requests to the ISP's satellite server. Subsequently, the ISP sends replies via the satellite you are connected to.


Here is an example of setting up GRE tunnel with a ISP:
Here is an example of setting up GRE tunnel with an ISP:


'''1. Make static routes'''
===Make static routes===


All queries to DNS servers of your land ISP should go via land line.
All queries to DNS servers of your land ISP should go via land line.


  # route add $DNS1 gw $DEFAULT_LAND_GATEWAY
{{Cmd|route add $DNS1 gw $DEFAULT_LAND_GATEWAY}}
  # route add $DNS2 gw $DEFAULT_LAND_GATEWAY
{{Cmd|route add $DNS2 gw $DEFAULT_LAND_GATEWAY}}


GRE packets should always go via land default gateway.   
GRE packets should always go via land default gateway.   


  # route add $SAT_ISP_GRE_IP gw $DEFAULT_LAND_GATEWAY
{{Cmd|route add $SAT_ISP_GRE_IP gw $DEFAULT_LAND_GATEWAY}}


It is assumed that $DEFAULT_LAND_GATEWAY is default gateway given by the land ISP, $DNSx are your DNS servers provided by the land ISP and $SAT_ISP_GRE_IP is remote IP of GRE tunnel of the satellite ISP.
It is assumed that $DEFAULT_LAND_GATEWAY is the default gateway given by the land ISP, $DNSx are your DNS servers provided by the land ISP and $SAT_ISP_GRE_IP is the remote IP of the satellite ISP's GRE tunnel.


Changes of default route will be made after a tunnel interface is created.
Changes of default route will be made after a tunnel interface is created.


'''2. Make GRE tunnel and setup tunnel interface'''
===Make GRE tunnel and set up the tunnel interface===


  # apk_add iproute2
{{Cmd|apk_add iproute2}}


  # modprobe ip_gre
{{Cmd|modprobe ip_gre}}
  # modprobe tun
{{Cmd|modprobe tun}}


  # ip tunnel add tun0 mode gre local $MY_STATIC_IP remote $SAT_ISP_GRE_IP ttl 250
{{Cmd|ip tunnel add tun0 mode gre local $MY_STATIC_IP remote $SAT_ISP_GRE_IP ttl 250}}
  # ifconfig tun0 $LOCAL_TUN_IP pointopoint $REMOTE_TUN_IP up
{{Cmd|ifconfig tun0 $LOCAL_TUN_IP pointopoint $REMOTE_TUN_IP up}}


Parameters of a tunnel such as $SAT_ISP_GRE_IP, $LOCAL_TUN_IP, $REMOTE_TUN_IP are provided by the satellite ISP.
Tunnel Parameters, such as $SAT_ISP_GRE_IP, $LOCAL_TUN_IP and $REMOTE_TUN_IP are provided by the satellite ISP.


Now make new default route that goes via tunnel interface. So most requests will go via GRE tunnel to satellite ISP with source IP as $LOCAL_TUN_IP. Answers expected via dvb interface for destination IP as $LOCAL_TUN_IP.
Now make a new default route that uses the tunnel interface. Most requests will go to the satellite ISP via the GRE tunnel with a source IP of $LOCAL_TUN_IP. Answers are expected via the DVB interface for the destination IP $LOCAL_TUN_IP.


  # route del default
{{Cmd|route del default}}
  # route add default dev tun0
{{Cmd|route add default dev tun0}}


'''3. Test satellite internet connectivity
===Test satellite internet connectivity===


  # ping wiki.alpinelinux.org
{{Cmd|ping wiki.alpinelinux.org}}


  # tcpdump -n -i tun0
{{Cmd|tcpdump -n -i tun0}}
  # tcpdump -n -i dvb0_0 host $LOCAL_TUN_IP
{{Cmd|tcpdump -n -i dvb0_0 host $LOCAL_TUN_IP}}


== Sharing Satellite Internet Connection ==
== Sharing a Satellite Internet Connection ==


It is assumed that we need to share the satellite internet with clients in a local network that already is connected via second Ethernet interface to satellite internet machine. This requires enabling IP forwarding, set up simple SNAT masquerading and traffic filtering rules. The easiest way is to use Shorewall for that purpose.
It is assumed we need to share the satellite internet with clients in a local network connected via a second Ethernet interface to a satellite internet machine. This requires enabling IP forwarding and setting up simple SNAT masquerading and traffic filtering rules. The easiest way is to use Shorewall for that purpose.
===Install shorewall===


''' 1. Install shorewall'''
{{Cmd|apk add shorewall}}


  # apk_add shorewall
===Set up ''shorewall.conf''===
 
'''2. Set up ''shorewall.conf'''''


   IP_FORWARDING=yes
   IP_FORWARDING=yes
Line 166: Line 172:
   CLAMPMSS=Yes # See '''RFC2923'''
   CLAMPMSS=Yes # See '''RFC2923'''


'''3. Set up ''zones'''''
===Set up ''zones''===


   inet ipv4
   inet ipv4
Line 173: Line 179:
   dvb  ipv4
   dvb  ipv4


'''4. Set up ''interfaces'''''
===Set up ''interfaces''===


   loc  eth1    detect  routefilter
   loc  eth1    detect  routefilter
Line 180: Line 186:
   dvb  dvb0_0  -     
   dvb  dvb0_0  -     


'''5. Set up ''policy'''''
===Set up ''policy''===


   loc  all  REJECT  info
   loc  all  REJECT  info
Line 186: Line 192:
   all  all  DROP    info
   all  all  DROP    info


'''6. Set up SNAT masquerading in ''masq'''''
===Set up SNAT masquerading in ''masq''===


   tun0  eth1
   tun0  eth1


'''7. Set up ''params'''''
===Set up ''params''===


   #This IP address are provided by the satellite ISP
   #This IP address are provided by the satellite ISP
Line 196: Line 202:
   LOCAL_TUN_IP=
   LOCAL_TUN_IP=


'''7. Set up ''rules'''''
===Set up ''rules''===


   SECTION ESTABLISHED
   SECTION ESTABLISHED
Line 216: Line 222:
   Ping/ACCEPT  fw  tun           
   Ping/ACCEPT  fw  tun           
   Ping/ACCEPT  pr  tun
   Ping/ACCEPT  pr  tun
 
===Set up ''tunnels''===
'''8. Set up ''tunnels'''''


   gre  inet  $SAT_ISP_GRE_IP
   gre  inet  $SAT_ISP_GRE_IP
Line 229: Line 234:
== More information  ==
== More information  ==


[http://en.wikipedia.org/wiki/Satellite_dish Satellite Dish]
* [http://en.wikipedia.org/wiki/Satellite_dish Satellite Dish]
[http://en.wikipedia.org/wiki/Ku_band Ku-band]
* [http://en.wikipedia.org/wiki/Ku_band Ku-band]
[http://www.linuxtv.org/wiki LinuxTV Wiki]
* [http://www.linuxtv.org/wiki LinuxTV Wiki]
[http://www.hack-it.net/How-To/Sat-HOWTO.html Satellite HOW-TO]
* [http://www.hack-it.net/How-To/Sat-HOWTO.html Satellite HOW-TO]
[http://tier.cs.berkeley.edu/wiki/HOWTO:IPTunnelling IP Tunnelling HOW-TO]
* [http://tier.cs.berkeley.edu/wiki/HOWTO:IPTunnelling IP Tunnelling HOW-TO]
[http://www.sat2k.com/ivs.htm Satellite Parameters]  
* [http://www.sat2k.com/ivs.htm Satellite Parameters]  
[http://www.ses-sirius.com/english/ SES SIRIUS]
* [http://www.ses-sirius.com/english/ SES SIRIUS]
[http://www.shorewall.net Shorewall]
* [http://www.shorewall.net Shorewall]
[http://http://lartc.org/howto Linux Advanced Routing & Traffic Control HOWTO]
* [http://http://lartc.org/howto Linux Advanced Routing & Traffic Control HOWTO]

Revision as of 19:53, 24 July 2021

Satellite Internet Connection HOW-TO

Introduction

This document briefly explains Satellite technology, how it works, what you need, configuration, and how to share it between several clients. The main focus is an Internet connection, i.e. satellite TV is not covered.

How does it work?

First we make the request (using a land Internet connection) to the Sat-Server usually via a tunnel. It will retrieve our info from the Internet and send it to the Satellite. Ultimately, we'll receive data from the satellite to our home using a parabolic antenna and a Sat Card.

Satellite works very well with protocols which have a small request data size and a much larger answer size. Large response delay is the biggest problem with satellite internet service. That may prevent using interactive services such as VoIP. The delay is caused by the distance the satellite is from the earth's surface, typically 36000 km. Average overall delay time is 300-400 ms.

To install the satellite system we need:

  • DVB-S Card
  • Parabolic Antenna (Satellite Dish)
  • LNB Digital Converter

Technical Information

A satellite link as is very different from Wired link. It may cause additional problems such as reachability, privacy, etc. There could also be weather related problems, particularly in snow or rain conditions.

Antenna / Converter

A parabolic antenna has a very high gain. The satellite transponder frequency is from 11 GHz to 12.7 GHz. The Digital Converter translates it to 1-2 GHz and sends the signal to a DVB-S card receiver through as much as 30-40 km of coaxial cable. This document assumes your parabolic antenna is properly mounted and boresighted as well as the proper converter (usually Ku-band) is used.

DVB-S Receiver Card

DVB-S card receives analog signals via coax cable and converts them to digital signals similar to those found on an Ethernet. After that, the OS transforms it to TCP/IP packets.

DVB Setup

Install DVB-S Card and check if system recognized it

Note: in most cases you need PCI version 2.1 or later (check your DVB card specifications) i.e. a Pentium-III or newer system.

lspci

Make sure that kernel modules are loaded

You must use Alpine 1.7.10 release or newer that should load appropriate kernel modules for DVB card on startup. To check if DVB devices are installed, run:

ls -la /dev/dvb*

Install LinuxTV Applications

apk_add linuxtv-dvb-apps

Create and edit file channels.conf

channels.conf contains settings for each Satellite you are using. For example the satellite Sirius-4 Nordic Beam has the following parameters:

  • Freq - 12322Mhz
  • Polarization - vertical
  • Symbol Rate - 27.654711Ms/s
  • FEC -7/8.

You'll need to get the parameters from your ISP or find them on the Internet. See Satellite Parameters and SES SIRIUS.

The following example is for "Sirius-4 Nordic Beam":

echo "Sirius4-Nord:12322:v:0:27500:0:0:0" >> /etc/channels.conf

Tune DVB Receiver

Check configured channels:

szap -c /etc/channels.conf -q

Tune to channel number 001:

szap -c /etc/channels.conf -n 1

In some cases you may need to run this command permanently in the background because of a bug in the kernel modules for some dvb cards.

  • Option A:

szap -c /etc/channels.conf -n 1 > /dev/null 2>&1 &

  • Option B:

start-stop-daemon --start --background --exec /usr/bin/szap -- -c /etc/channels.conf -n 1

Set up DVB network interface

Your ISP provides you the PID, which is used for select a particular transmission from many signals on the same frequency.

dvbnet -a 0 -p $PID

ifconfig dvb0_0 hw ether $MAC ifconfig dvb0_0 $IP netmask 255.255.255.255 up

Here $IP is any IP address, which does not match any address on your network. The $MAC you specify here is usually the MAC address of your DVB card, in some cases ISP supplies MAC address for you. In any case, the ISP sends data only for registered MAC addresses.

Due to the nature of a satellite connection, the DVB interface receives packets, which have originated from other sources, usually from either a land internet connection or, in most cases, from a virtual tunnel device. In order receive such packets, the source validation should be disabled on the dvb0_0 interface.

echo "0" > /proc/sys/net/ipv4/conf/dvb0_0/rp_filter

Another way to achieve that is to allow shorewall to control it using ROUTE_FILTER and routefilter parameters.

Test if satellite interface is receiving data

You should see many packets for other clients of your ISP.

apk add tcpdump

tcpdump -n -i dvb0_0

Authentication with ISP

Before you receive your data via satellite, your ISP should authenticate you as their registered client. There are several common techniques in use:

  • Some ISPs use "Proxy Authentication." When you use their proxy, you also need to supply a login name and password to continue the request. Once done, the ISP uses your IP address to calculate your MAC address, to which it sends the answer.
  • Other ISPs require you to make a VPN connection (using your login and password) first, then they will control your registration account (where they retrieve your MAC address) and will send data to your card (your MAC address).
  • If you have a static public IP, perhaps the most convenient way is when ISPs suggest making a GRE/IPIP tunnel which is used to send authenticated requests to the ISP's satellite server. Subsequently, the ISP sends replies via the satellite you are connected to.

Here is an example of setting up GRE tunnel with an ISP:

Make static routes

All queries to DNS servers of your land ISP should go via land line.

route add $DNS1 gw $DEFAULT_LAND_GATEWAY

route add $DNS2 gw $DEFAULT_LAND_GATEWAY

GRE packets should always go via land default gateway.

route add $SAT_ISP_GRE_IP gw $DEFAULT_LAND_GATEWAY

It is assumed that $DEFAULT_LAND_GATEWAY is the default gateway given by the land ISP, $DNSx are your DNS servers provided by the land ISP and $SAT_ISP_GRE_IP is the remote IP of the satellite ISP's GRE tunnel.

Changes of default route will be made after a tunnel interface is created.

Make GRE tunnel and set up the tunnel interface

apk_add iproute2

modprobe ip_gre

modprobe tun

ip tunnel add tun0 mode gre local $MY_STATIC_IP remote $SAT_ISP_GRE_IP ttl 250

ifconfig tun0 $LOCAL_TUN_IP pointopoint $REMOTE_TUN_IP up

Tunnel Parameters, such as $SAT_ISP_GRE_IP, $LOCAL_TUN_IP and $REMOTE_TUN_IP are provided by the satellite ISP.

Now make a new default route that uses the tunnel interface. Most requests will go to the satellite ISP via the GRE tunnel with a source IP of $LOCAL_TUN_IP. Answers are expected via the DVB interface for the destination IP $LOCAL_TUN_IP.

route del default

route add default dev tun0

Test satellite internet connectivity

ping wiki.alpinelinux.org

tcpdump -n -i tun0

tcpdump -n -i dvb0_0 host $LOCAL_TUN_IP

Sharing a Satellite Internet Connection

It is assumed we need to share the satellite internet with clients in a local network connected via a second Ethernet interface to a satellite internet machine. This requires enabling IP forwarding and setting up simple SNAT masquerading and traffic filtering rules. The easiest way is to use Shorewall for that purpose.

Install shorewall

apk add shorewall

Set up shorewall.conf

 IP_FORWARDING=yes
 ROUTE_FILTER=No
 CLAMPMSS=Yes # See RFC2923

Set up zones

  inet ipv4
  loc  ipv4
  tun  ipv4
  dvb  ipv4

Set up interfaces

  loc   eth1    detect   routefilter
  inet  eth0    detect   norfc1918,routefilter
  tun   tun0    -        norfc1918,routefilter
  dvb   dvb0_0  -     

Set up policy

  loc   all  REJECT  info
  dvb   all  REJECT  info
  all   all  DROP    info

Set up SNAT masquerading in masq

  tun0  eth1

Set up params

  #This IP address are provided by the satellite ISP
  SAT_ISP_GRE_IP=
  LOCAL_TUN_IP=

Set up rules

  SECTION ESTABLISHED
  REJECT        dvb  fw:!$LOCAL_TUN_IP
  SECTION RELATED
  REJECT        dvb  fw:!$LOCAL_TUN_IP
 
  SECTION NEW
  DNS/ACCEPT    fw   inet
  Ping/ACCEPT   fw   inet
  #Allow Web/FTP queries via GRE tunnel to ISP
  # Answers come as RELATED/ESTABLISHED traffic via DVB
  Web/ACCEPT    fw   tun
  Web/ACCEPT    loc  tun            
  FTP/ACCEPT    fw   tun           
  FTP/ACCEPT    loc  tun            
  Ping/ACCEPT   fw   tun           
  Ping/ACCEPT   pr   tun

Set up tunnels

  gre  inet   $SAT_ISP_GRE_IP

Conclusion

This document reviewed just basic ideas how to setup and share satellite internet connection. Further releases of Alpine Linux will include start up and configuration scripts (see Mailing Lists). Note, that more advanced traffic routing is beyond of scope of this document.

Another advanced topic that is beyond of scope is how to use remote proxy/VPN services to protect/encrypt your Satellite traffic against grabbers. This configuration may protect HTTP/POP3 and other types of data against unauthorized grabbing with attempts to sniff personal mail, electronic addresses and other information.

More information