Tweaking iptables for Captive Portal (Anish's Python approach, thx to Nikos Fotiou)#870
Tweaking iptables for Captive Portal (Anish's Python approach, thx to Nikos Fotiou)#870holta merged 10 commits intoiiab:masterfrom
Conversation
|
Is this tested with IIAB 6.6/master on Raspbian? (And ideally also on Ubuntu 18.04?) See background: Captive Portal @m-anish is working on with @tim-moody and @jvonau @ #826 |
|
How does this PR (#870) compare to Anish's prototype at https://github.com/iiab/iiab/compare/master...m-anish:captive_portal?expand=1 ? |
|
@jvonau responded:
|
| py_captive_portal_enabled: True | ||
| captive_portal_port: "9090" | ||
| captive_portal_username: "Admin" | ||
| captive_portal_password: "g0adm1n" |
There was a problem hiding this comment.
Thx to @jvonau who fixed this from Admin/g0adm1n to Admin/changeme
@m-anish suggests we consider removing the password entirely, "it can just be a simple html page with a button, or as Tim said, a timer"
FYI regardless, @jvonau clarifies this form/pages "adds the iptables rules to allow internet access"
| block_DNS: False | ||
| # Captive Portal highly experimental as of July 2018: https://github.com/iiab/iiab/pull/870 | ||
| py_captive_portal_install: True | ||
| py_captive_portal_enabled: False |
There was a problem hiding this comment.
Can we place these 3 lines into our local_vars.yml files as well?
# Captive Portal highly experimental as of July 2018: https://github.com/iiab/iiab/pull/870
py_captive_portal_install: True
py_captive_portal_enabled: False
|
CLARIF from @jvonau:
|
|
Additionally, as promised, here is the apache configuration. I am attaching two things - one the entire sites-available folder, and second 001-captive_portal.conf which in itself should also be enough. Please rename the conf file from .conf.txt to just .conf (github wouldn't let me paste with that extension) |
|
Thx to @jvonau who fixed Admin/g0adm1n to Admin/changeme in this PR's roles/network/defaults/main.yml @m-anish suggests we consider removing the password entirely, "it can just be a simple html page with a button, or as Tim said, a timer" FYI regardless, @jvonau clarifies this form/pages "adds the iptables rules to allow internet access" |
|
Chat Excerpt: Holt: When should PR #870 be merged, after testing on what OS's/environments? |
|
We agreed to merge during our community/team call today (http://minutes.iiab.io) @jvonau smoke-tested on Raspbian Lite ~10 days ago. Possible future improvements:
|
|
@m-anish please help us refine & help me document at http://FAQ.IIAB.IO (or other places) so this is increasingly usable by all! |
|
[Aside: @m-anish had tested on NUC with named/BIND ...if confirmed/refined, this should later be written up as part of #608 in http://FAQ.IAB.IO] FYI TK Kang is looking into whether this works (on IIAB 6.6/master on his RPi 3) by placing @m-anish's 001-captive_portal.conf in /etc/apache2/sites-available and then changing these 3 variables in /etc/iiab/local_vars.yml from False to True: And then running: Then he's trying @tim-moody's test:
|
|
TK Kang confirms the above works for him: Visiting site http://any-random-letters.org takes him to http://any-random-letters.org/home (showing IIAB's actual home page & content). Others kindly please confirm, and help create a PR. |
|
After a few more days of testing this Captive Portal, TK writes:
|
|
TK corroborates a problem @tim-moody has found:
|
|
To help @tim-moody understand what install recipe is best to try, @jvonau suggests:
|
What follows is a log of testing the captive portal receipe above -ghunt
and copy apache config file to /etc/apache2/sites-available. Then create symbolic link from that file to sites-enabled (did TK know that was required? -- not listed in the receipe) RESULTS: (first with ethernet wire connected)
Disconnect the ethernet wire and collect more data:No change in behavior -- mac or android |
|
Thanks for your careful documentation. |
|
Thought part of the test was to exclude the apache config file to see if
the 503 Service unavailable changes
…On Thu, Aug 9, 2018 at 9:10 PM Tim Moody ***@***.***> wrote:
Thanks for your careful documentation.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#870 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AFUjvmacgysrSaWyBvqWr-KDET5yrbg7ks5uPOujgaJpZM4VBBcp>
.
|
Fixes Bug
Description of changes proposed in this pull request.
Based on @m-anish 's https://github.com/m-anish/named_redirect which builds off Nikos Fotiou's https://github.com/nikosft/captive-portal/blob/master/captive_portal.py
Smoke-tested in operating system.
Mention a team member for further information or comment using @ name