Raspberry Pi (Mostly) Captive Portal

I am trying to build a sort of captive portal out of a RPi3. I started by creating an access point following these instructions. Next I configured dnsmasq to point all traffic on wlan0 at itself. echo 'address=/#/172.24.1.1' >> /etc/dnsmasq.conf

Once connected all traffic is redirected back to my node app. Now here is where my problem begins. All traffic gets sent to my node app, including traffic that originates from the raspberry pi, so while on the box I am unable to telnet to any websites, or install apps.

I believe the issue is with the iptable rules.

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE   iptables -A FORWARD -i eth0 -o wlan0 -m state --state RELATED,ESTABLISHED -j ACCEPT   iptables -A FORWARD -i wlan0 -o eth0 -j ACCEPT   

I need all traffic that originates from the raspberry pi to be able to go out to the internet (through eth0)and all traffic that comes in through wlan0 to continue to redirect to my node app.

Any help would be greatly appreciated.

Regards, Austin

Replay

Category: iptables Time: 2016-07-29 Views: 0

Related post

iOS development

Android development

Python development

JAVA development

Development language

PHP development

Ruby development

search

Front-end development

Database

development tools

Open Platform

Javascript development

.NET development

cloud computing

server

Copyright (C) avrocks.com, All Rights Reserved.

processed in 0.118 (s). 12 q(s)