Wifi authentication

Related to the development libraries, released by Curt Binder
Post Reply
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Wifi authentication

Post by rimai »

I patched the libraries to allow for wifi authentication.
https://github.com/reefangel/Libraries/issues/71
Basically, it is not http authentication as we were originally trying.
It's actually using the portal key as authentication.
I need people to test it.
My initial tests worked fine.
Here is how it will work.
You must use the Portal function with a key in your code. Example:

Code: Select all

ReefAngel.Portal("reefangel","mysecretkey");
Then, everytime you use the webserver, you must call it with the key like this:
http://ipaddress:2000/?key=mysecretkey
http://ipaddress:2000/r99?key=mysecretkey
If you fail to provide the correct key, the controller will simply display "Invalid Key".
We will need the apps to be updated for this to work with the key.
Roberto.
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Wifi authentication

Post by rimai »

This idea was actually sparked by a chat I had with thekameleon :)
Thanks for the contribution!!!
Roberto.
binder
Posts: 2871
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Wifi authentication

Post by binder »

rimai wrote:This idea was actually sparked by a chat I had with thekameleon :)
Thanks for the contribution!!!
Great contribution.

I can add that in to the Android app if it works out well.
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: Wifi authentication

Post by thekameleon »

Its not perfect but if you make a random enough key, it will prevent random url generators from turning on your ATO by accident... On this point... would it be possible to support both the key in the url get as well as a post (in the body)?
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Wifi authentication

Post by rimai »

Have you pulled the git branch and tested it?
The controller only accepts GET requests
Roberto.
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: Wifi authentication

Post by thekameleon »

I have the latest 1.0.5 and I tried it both with and without the key and in both queires I got results... Is there something else I need to turn on?
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: Wifi authentication

Post by thekameleon »

Did you take care of the portal page to submit the key as well. casue if it does work and you di not the portal page would stop working right?
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Wifi authentication

Post by rimai »

I did not push the changes for wifi key authentication.
It's still pending in the issue list on a separate branch.
I need to make sure it works with web browser and also, we need to make sure that the apps can be updated as it will break them.
Roberto.
binder
Posts: 2871
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Wifi authentication

Post by binder »

rimai wrote:I did not push the changes for wifi key authentication.
It's still pending in the issue list on a separate branch.
I need to make sure it works with web browser and also, we need to make sure that the apps can be updated as it will break them.
I honestly have not tested it with my android app. I know I need to but I have been focusing on some other drastic improvements instead.
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: Wifi authentication

Post by thekameleon »

OK fair enough. I will also incorporate into my apps and service I am working on. Does the portal currently send the key now?
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Wifi authentication

Post by rimai »

No, it does not.
Roberto.
Post Reply