RE: [PATCH] Added captive portal possibility

2015-10-19 Thread Craig McQueen
On 19-Oct-2015 7:29 PM Alexandre Chataignon wrote: > On 10/16/2015 07:52 AM, Craig McQueen wrote: > > I'm interested in this concept. I applied your patch to ConnMan 1.30, and > I've been testing it. > > > > In my testing with DNS queries using the Linux 'dig' utility, I found it > > returns > mal

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Alexandre Chataignon
On 10/19/2015 11:40 AM, Patrik Flykt wrote: I was thinking of any connection going to e.g. port 80 would be forced to the locally used x.x.x.1 address on the tether interface. Like an automatic proxy solution. This can then be refined to work only for a subset of hosts, by looking up e.g. www.goo

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Patrik Flykt
Hi, On Mon, 2015-10-19 at 10:26 +0200, Alexandre Chataignon wrote: > This solution was the first I implemented (no need to modify connman > source code). > > The problem is that in your case, DNS requests are answered by a remote > DNS server. However, as I said, the tethering mode he

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Alexandre Chataignon
On 10/16/2015 07:52 AM, Craig McQueen wrote: I'm interested in this concept. I applied your patch to ConnMan 1.30, and I've been testing it. In my testing with DNS queries using the Linux 'dig' utility, I found it returns malformed responses. That is because the 'dig' query includes an additio

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Alexandre Chataignon
On 10/19/2015 09:55 AM, Patrik Flykt wrote: A captive portal is easier to implement by setting a NAT rule that redirects incoming connections to a desired port on the local x.x.x.1 tethering interface. Once the captive portal stuff is cleared out, the redirecting NAT rule for that host can be mod

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Patrik Flykt
On Fri, 2015-10-16 at 16:52 +1100, Craig McQueen wrote: > So the patch would need to be improved as follows: > > * Check that the query first question is for an A record, and only > send an A record if so. > * Calculate the correct length of the query header and question > record(s), in order to p

Re: [PATCH] Added captive portal possibility

2015-10-19 Thread Patrik Flykt
Hi, On Wed, 2015-09-23 at 11:20 +0200, Alexandre Chataignon wrote: > This patch adds the possibility to enable a captive portal while connman > is in tethering mode by sending its own IP via the DNS proxy (which acts > as a DNS server more than a proxy in this case). > > I needed this

RE: [PATCH] Added captive portal possibility

2015-10-15 Thread Craig McQueen
Alexandre Chataignon wrote: > This patch adds the possibility to enable a captive portal while connman is in > tethering mode by sending its own IP via the DNS proxy (which acts as a DNS > server more than a proxy in this case). > > I needed this usage for an IoT device, in which the tethering mod