Compare commits

..

10 Commits
1.1b ... 1.1c

15 changed files with 69 additions and 20 deletions

Binary file not shown.

BIN
Makefile

Binary file not shown.

View File

@@ -1,8 +1,10 @@
# GÉANTLink # GÉANTLink
Suite of EAP supplicants for Microsoft Windows - IEEE 802.1X plug-ins for enterprise network authentication Suite of EAP supplicants for Microsoft Windows - IEEE 802.1X clients for enterprise network authentication
## Features ## Features
- Integrates into Windows seamlessly
- Wired and wireless network support
### Authentication methods ### Authentication methods
- EAP-TTLS with the following inner methods: - EAP-TTLS with the following inner methods:
@@ -13,7 +15,7 @@ Suite of EAP supplicants for Microsoft Windows - IEEE 802.1X plug-ins for enterp
### Security ### Security
- Microsoft Windows Credential Manager stored user credentials - Microsoft Windows Credential Manager stored user credentials
- User credentials can be shared between different network profiles - User credentials can be shared between different network profiles, regardless of their connection: wired or wireless
- Encrypted EapHost inter-process communication - Encrypted EapHost inter-process communication
- TLS: - TLS:
- Separate trusted root CA list - Separate trusted root CA list
@@ -29,11 +31,15 @@ Suite of EAP supplicants for Microsoft Windows - IEEE 802.1X plug-ins for enterp
- Lockable network profile configuration - Lockable network profile configuration
### Deployment ### Deployment
- Released as multi-lingual 32 and 64-bit MSI packages - Released as multi-lingual 32 and 64-bit MSI packages; Group Policy deployment supported
- [MsiUseFeature utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/MsiUseFeature) for GÉANTLink install state testing (for embedding GÉANTLink into other setup packages) - [MsiUseFeature utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/MsiUseFeature) for GÉANTLink install state testing (for embedding GÉANTLink into other setup packages)
- [CredWrite utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/CredWrite) for automated user credential import to Credential Manager - [CredWrite utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/CredWrite) for automated user credential import to Credential Manager
- [WLANManager utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/WLANManager) to allow network profile configuration dialog shortcuts - [WLANManager utility](https://github.com/Amebis/GEANTLink/tree/ver1.1/WLANManager) to allow network profile configuration dialog shortcuts
### Supported operating systems
- Windows Vista, Windows Server 2008
- Windows 7, Windows Server 2008 R2
## Download ## Download
Binaries are available for download [here](https://github.com/Amebis/GEANTLink/releases). Binaries are available for download [here](https://github.com/Amebis/GEANTLink/releases).

View File

@@ -60,6 +60,10 @@ static int WLANManager()
return -1; return -1;
} }
wstring interface_name;
if (nArgs >= 5 && _wcsicmp(pwcArglist[3], L"interface") == 0)
interface_name = pwcArglist[4];
// Open WLAN handle. // Open WLAN handle.
DWORD dwNegotiatedVersion; DWORD dwNegotiatedVersion;
wlan_handle wlan; wlan_handle wlan;
@@ -83,20 +87,55 @@ static int WLANManager()
interfaces.reset(pInterfaceList); interfaces.reset(pInterfaceList);
} }
tstring_guid devclass_net(GUID_DEVCLASS_NET);
bool profile_found = false;
for (DWORD i = 0; i < interfaces->dwNumberOfItems; i++) { for (DWORD i = 0; i < interfaces->dwNumberOfItems; i++) {
if (interfaces->InterfaceInfo[i].isState == wlan_interface_state_not_ready) { if (interfaces->InterfaceInfo[i].isState == wlan_interface_state_not_ready) {
// This interface is not ready. // This interface is not ready.
continue; continue;
} }
if (!interface_name.empty()) {
// Read the interface name from registry.
reg_key key;
if (key.open(HKEY_LOCAL_MACHINE, tstring_printf(_T("SYSTEM\\CurrentControlSet\\Control\\Network\\%s\\%s\\Connection"), devclass_net.c_str(), tstring_guid(interfaces->InterfaceInfo[i].InterfaceGuid).c_str()).c_str(), 0, KEY_READ)) {
wstring name;
if (RegQueryStringValue(key, _T("Name"), name) == ERROR_SUCCESS && _wcsicmp(interface_name.c_str(), name.c_str()) != 0) {
// Not the interface we are interested in.
continue;
}
}
}
unique_ptr<WLAN_PROFILE_INFO_LIST, WlanFreeMemory_delete<WLAN_PROFILE_INFO_LIST> > profiles;
{
// Get a list of profiles.
WLAN_PROFILE_INFO_LIST *pProfileList;
DWORD dwResult = WlanGetProfileList(wlan, &(interfaces->InterfaceInfo[i].InterfaceGuid), NULL, &pProfileList);
if (dwResult != ERROR_SUCCESS) {
DisplayError(_T("%s function failed (error %u)."), _T("WlanGetProfileList"), dwResult);
return 4;
}
profiles.reset(pProfileList);
}
for (DWORD j = 0; j < profiles->dwNumberOfItems; j++)
if (_wcsicmp(profiles->ProfileInfo[j].strProfileName, pwcArglist[2]) == 0) {
profile_found = true;
break;
}
if (!profile_found)
continue;
// Launch WLAN profile config dialog. // Launch WLAN profile config dialog.
WLAN_REASON_CODE wlrc; WLAN_REASON_CODE wlrc = L2_REASON_CODE_SUCCESS;
DWORD dwResult = WlanUIEditProfile(WLAN_UI_API_VERSION, pwcArglist[2], &(interfaces->InterfaceInfo[i].InterfaceGuid), NULL, WLSecurityPage, NULL, &wlrc); DWORD dwResult = WlanUIEditProfile(WLAN_UI_API_VERSION, pwcArglist[2], &(interfaces->InterfaceInfo[i].InterfaceGuid), NULL, WLSecurityPage, NULL, &wlrc);
if (dwResult != ERROR_SUCCESS) { if (dwResult != ERROR_SUCCESS) {
DisplayError(_T("%s function failed (error %u)."), _T("WlanUIEditProfile"), dwResult); // WlanUIEditProfile() displays own error dialog on failure.
//DisplayError(_T("%s function failed (error %u)."), _T("WlanUIEditProfile"), dwResult);
return 5; return 5;
} } else if (wlrc != WLAN_REASON_CODE_SUCCESS) {
if (wlrc != WLAN_REASON_CODE_SUCCESS) {
tstring reason; tstring reason;
if (WlanReasonCodeToString(wlrc, reason, NULL) == ERROR_SUCCESS) if (WlanReasonCodeToString(wlrc, reason, NULL) == ERROR_SUCCESS)
DisplayError(_T("%s function failed: %s"), _T("WlanUIEditProfile"), reason.c_str()); DisplayError(_T("%s function failed: %s"), _T("WlanUIEditProfile"), reason.c_str());
@@ -107,6 +146,9 @@ static int WLANManager()
break; break;
} }
if (!profile_found)
DisplayError(_T("%ls profile not found."), pwcArglist[2]);
return 0; return 0;
} }

View File

@@ -3,7 +3,7 @@ Invokes standard Windows Wireless Network Properties dialog
##Usage ##Usage
``` ```
WLANManager profile <name> WLANManager profile <name> [interface <name>]
``` ```
- `name` - The name of the network profile (not neccessarely the same as SSID) - `name` - The name of the network profile (not neccessarely the same as SSID)

View File

@@ -28,6 +28,7 @@
#include <Windows.h> #include <Windows.h>
#include <CommCtrl.h> #include <CommCtrl.h>
#include <devguid.h>
#include <tchar.h> #include <tchar.h>
#include <memory> #include <memory>

View File

@@ -29,7 +29,7 @@
// Product version as a single DWORD // Product version as a single DWORD
// Note: Used for version comparison within C/C++ code. // Note: Used for version comparison within C/C++ code.
// //
#define PRODUCT_VERSION 0x01010500 #define PRODUCT_VERSION 0x01010600
// //
// Product version by components // Product version by components
@@ -39,26 +39,26 @@
// //
#define PRODUCT_VERSION_MAJ 1 #define PRODUCT_VERSION_MAJ 1
#define PRODUCT_VERSION_MIN 1 #define PRODUCT_VERSION_MIN 1
#define PRODUCT_VERSION_REV 5 #define PRODUCT_VERSION_REV 6
#define PRODUCT_VERSION_BUILD 0 #define PRODUCT_VERSION_BUILD 0
// //
// Human readable product version and build year for UI // Human readable product version and build year for UI
// //
#define PRODUCT_VERSION_STR "1.1b" #define PRODUCT_VERSION_STR "1.1c"
#define PRODUCT_BUILD_YEAR_STR "2017" #define PRODUCT_BUILD_YEAR_STR "2017"
// //
// Numerical version presentation for ProductVersion propery in // Numerical version presentation for ProductVersion propery in
// MSI packages (syntax: N.N[.N[.N]]) // MSI packages (syntax: N.N[.N[.N]])
// //
#define PRODUCT_VERSION_INST "1.1.5" #define PRODUCT_VERSION_INST "1.1.6"
// //
// The product code for ProductCode property in MSI packages // The product code for ProductCode property in MSI packages
// Replace with new on every version change, regardless how minor it is. // Replace with new on every version change, regardless how minor it is.
// //
#define PRODUCT_VERSION_GUID "{B7D36075-0DE9-4157-B27C-9B180D16EF05}" #define PRODUCT_VERSION_GUID "{82DBB47E-71F9-4E67-B728-CACB4480B63E}"
// //
// Product vendor // Product vendor

Binary file not shown.