Questions tagged [iptables]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0
votes
0answers
15 views

How can I bypass android 9 VPN with iptables?

I'm targeting specific app with UID rule -m owner --uid-owner 1337 and I want this app always bypass VPN and use direct Wi-fi/Mobile Data connection. Ideally, I also want it to be universal, if ...
0
votes
0answers
10 views

How can I block several ips with wildcard method?

How can I block several ips with only one ip Like I have 123.45.67.000 123.45.67.001 123.45.67.002 123.45.67.003 n so on There is changing only in last digit Is it possible to block all ips belongs ...
3
votes
1answer
962 views

How to send all internet traffic to a SOCKS5 proxy server in local network?

I got the inspiration here. It looks like AFWall+ is able to create a NAT forwarding policy to keep all traffic going through a SOCKS5 proxy and fool Google apps into thinking they are not connected ...
0
votes
0answers
17 views

Individual commands run okay, but shell script throws errors [duplicate]

I'm trying to create a shell script to configure iptables and add a few routes to my device running Android 10. I have root access. Here's the script. I called it script.sh: #!/system/bin/sh ...
0
votes
0answers
317 views

AFWall+ not blocking consistently

I'm running a rooted pixel 3 (Magisk) with the "liboemcrypt disabler" module for running Netflix, Magisk Hide and the dg.db edit to disable attestation for running Google Pay. The firewall will work ...
1
vote
1answer
303 views

Restricting an app to only send internet traffic but not receive that back?

Is there a way or app to restrict some apps on my Android, or the whole device, to only send internet data packets but not receive them back? I want to confuse a game app by doing this. It restricts ...
1
vote
0answers
130 views

Cannot connect to Wifi iptables error

Lately my Google Pixel 2 will not connect to my Homewifi. It tries to connect all the time. Looking into the Log I get an iptables error: 05-06 10:03:56.253 1120-1355/? D/RecurrenceRule: Resolving ...
2
votes
1answer
792 views

Android DHCP Port Redirection

I am working on a MirrorLink implementation for the Google Pixel (Android 8.1.0). I must implement a DHCP server; however, Android applications cannot listen on reserved ports. The Android ...
1
vote
0answers
301 views

How to keep iptables changes on android after reboot?

If I do any changes to iptables on Android (my phone is running CyanogenMod 11 - Android 4.4.3), then these changes are lost after phone reboot. What should I do to keep them saved?
1
vote
0answers
508 views

Where should I place iptables update on Android at boot time?

I need to write specific values in the routing system using the iptables command for Android. The overall idea is that the user can navigate only using the provided DNS configuration. I've tried to ...
1
vote
0answers
299 views

Android VPN service's policy based routing relative to iptables (specific behavior question, android 5.0, 5.1)

Background: Several phones, different firmwares Elephone p7000, Android 5.0 based rom Xiaomi redmi note 2, three different roms (5.1 based Cyaonogen, 5.0 based AOSP derivative) Rooted. Installed a ...
1
vote
0answers
949 views

Configuring Android to IP FORWARDING

Android version : Lollipop. Rooted: Yes. I'm trying to connect a PC to a Laptop via a WLAN. I'm using my android as a WifiAdapter. I connected the android node to the WLAN. With a USB cable ...
1
vote
0answers
469 views

reverse tethering - offline for some applications

I try to get internet on my phone from my computer without instlling any tools. My configuration looks like : mybox -----(Ethernet)------[my computer]------(USB)-----[the phone] I enabled usb ...
2
votes
0answers
863 views

How to Reverse Usb Tethering with VPN [tun0 interface] routing?

I have a big problem and after many days I can't find any solution because I'm not Linux experienced user... Problem: I'm using USB [Reverse] Tether (Windows share internet with android phone via USB ...
1
vote
1answer
323 views

Forward tethered device?

Alright, so I have a raspberry pi (192.168.42.53 on rndis0) that is tethered to an android tablet to access the internet. The tablet is connected to my home LAN via WiFi (on wlan0). How do I forward ...
1
vote
1answer
4k views

How to enable Android Ip forwarding

In linux we can, # echo 1 > /proc/sys/net/ipv4/ip_forward or, # sysctl -w net.ipv4.ip_forward=1 There is no sysctl command nor /proc/sys/net/ipv4/ip_forward file in Android. Is there an ...
1
vote
2answers
2k views

App that survives a factory reset

My problem is theoretical at this moment. I am investigating if it is possible or not, before spending hours on it. I have a rooted phone. I want to add an entry to the IPTABLES on startup. If the ...
3
votes
1answer
10k views

How can I add iptables rules that persist across reboots?

I want to add an iptables rule on my Android phone. I used: iptables -t nat -A PREROUTING -p 6 -d 192.168.66.1 --dport 80 -j DNAT --to 192.168.66.1:808 ...as root. This rule can be checked in adb ...
2
votes
2answers
11k views

DNAT iptables rule on rooted Android phone?

How i can set iptables rule like this on my rooted Android phone: iptables -t nat -A PREROUTING -i wlan0 -s 192.168.1.100 -p tcp --dport 80 -j DNAT -–to-destination 192.168.1.101:8080 ... since ...
0
votes
1answer
412 views

How can I debug Droidwall blocking every app?

Starting some time ago, I have noticed that when Droidwall (1.5.7) is enabled, no apps can access wifi. Although the app is checked, it doesn't work, until I turn the firewall completely off. This ...