OpenGarage › Forums › OpenGarage Firmware › WPA2-Enterprise?
- This topic has 5 replies, 3 voices, and was last updated 6 years, 12 months ago by penright.
-
AuthorPosts
-
September 24, 2016 at 12:15 am #100
RonRN18ParticipantI am curious if this device will connect with my WAP which uses WPA2-Enterprise. The reason for using WPA2-Enterprise is because it allows seamless swapping between 2.4GHz and 5GHz. In the video, it appears to only show an SSID with a password but with Enterprise, you use a username and password, which gets verified with a RADIUS server. If this is documented somewhere, where I can I find that? I’ve been looking for something like this for a while. I was going to build something myself with an Arduino but it was going to definitely cost more and I prefer the distance sensors of this device, rather than my design of a magnetic switch.
October 1, 2016 at 10:18 pm #144
RayKeymasterI don’t think it supports WPS2-Enterprise. This is more of a general question for ESP8266 module — I don’t think I’ve read its support for WPA2-Enterprise, or 5G anywhere, so I assume it doesn’t.
November 22, 2017 at 4:24 pm #788
penrightParticipantIs this the support that is needed …
I will start working on a hello world .ino to test the lib, but if it works then who can wire it into the OG app?
November 24, 2017 at 10:21 am #791
RayKeymasterThanks for the information. Indeed support for WPA2-Enterprise has been added to the ESP8266 library, and it can be integrated into the firmware now. The only thing is that we don’t have a WPA2-Enterprise router in house to test (they seem rather expensive), so ideally we will need to find some users to help test this feature.
November 24, 2017 at 2:22 pm #793
penrightParticipantWell I have have one and I am willing to test.
Using Hallgeir Holien instruction I did get it to connect to the one in our building.
Here is a thread of my trialsMy biggest issue was how to convert Holien instructions into windows.
There could be still one issue. Holien instructions have you hack the libwpa2.a file. You have to change the [email protected] to your email address.
I wonder why that is not part of config parameters?I going to see if I can keep OG from trying to config WIFI and see if it works otherwise.
After following his instructions here is my hello world.
extern "C" { #include "user_interface.h" #include "wpa2_enterprise.h" } #include <Arduino.h> #include <ESP8266WiFi.h> #include <ESP8266HTTPClient.h> // SSID to connect to static const char* ssid = "MySSID"; // Username for authentification static const char* username = "MyUserName"; // Password for authentification static const char* password = "MyPassword"; const int ledPin = 0; void setup() { Serial.begin(115200); pinMode(ledPin, OUTPUT); Serial.print("Tryingonnect to "); Serial.println(ssid); wifi_station_disconnect(); wifi_set_opmode(STATION_MODE); struct station_config wifi_config; memset(&wifi_config, 0, sizeof(wifi_config)); strcpy((char*)wifi_config.ssid, ssid); strcpy((char*)wifi_config.password, password); wifi_station_set_config(&wifi_config); wifi_station_clear_cert_key(); wifi_station_clear_enterprise_ca_cert(); wifi_station_set_wpa2_enterprise_auth(1); wifi_station_set_enterprise_username((uint8*)username, strlen(username)); wifi_station_set_enterprise_password((uint8*)password, strlen(password)); wifi_station_connect(); Serial.print("Status: "); Serial.println(wifi_station_get_connect_status()); // Wait for connection AND IP address from DHCP while (WiFi.status() != WL_CONNECTED) { delay(2000); Serial.print("Status: "); Serial.print(wifi_station_get_connect_status()); Serial.print(" IP: "); Serial.println(WiFi.localIP()); } // Now we are connected Serial.println(""); Serial.println("WiFi connected"); Serial.println("IP address: "); Serial.println(WiFi.localIP()); } // setup void loop() { }
November 27, 2017 at 10:43 am #795
penrightParticipant@keymaster, Still trying to find out for sure, but for now looks like there is a bug.
Been emailing Holien, the step to hack the libwpa2.a file, If I understand right, is because espressif did not wire the user name.
And espressif only distributes binary libraries, we have to wait for them to fix it. -
AuthorPosts
- You must be logged in to reply to this topic.
OpenGarage › Forums › OpenGarage Firmware › WPA2-Enterprise?