mirror of
https://github.com/Telecominfraproject/wlan-cloud-opensync-controller.git
synced 2025-11-01 11:07:49 +00:00
Static GW handles captive portal profile
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package com.telecominfraproject.wlan.opensync.external.integration;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
@@ -42,6 +44,9 @@ public class OpensyncExternalIntegrationSimple implements OpensyncExternalIntegr
|
||||
|
||||
@Value("${tip.wlan.ovsdb.radiusProfileFileName:/app/config/ProfileRadius.json}")
|
||||
private String radiusProfileFileName;
|
||||
|
||||
@Value("${tip.wlan.ovsdb.captiveProfileFileName:/app/config/ProfileCaptive.json}")
|
||||
private String captiveProfileFileName;
|
||||
|
||||
@Value("${tip.wlan.ovsdb.locationFileName:/app/config/LocationBuildingExample.json}")
|
||||
private String locationFileName;
|
||||
@@ -86,6 +91,16 @@ public class OpensyncExternalIntegrationSimple implements OpensyncExternalIntegr
|
||||
|
||||
List<com.telecominfraproject.wlan.profile.models.Profile> radiusProfiles = com.telecominfraproject.wlan.profile.models.Profile
|
||||
.listFromFile(radiusProfileFileName, com.telecominfraproject.wlan.profile.models.Profile.class);
|
||||
|
||||
|
||||
List<com.telecominfraproject.wlan.profile.models.Profile> captiveProfiles = null;
|
||||
File captiveFile = new File(captiveProfileFileName);
|
||||
if (captiveFile.exists()) {
|
||||
captiveProfiles = com.telecominfraproject.wlan.profile.models.Profile
|
||||
.listFromFile(captiveProfileFileName, com.telecominfraproject.wlan.profile.models.Profile.class);
|
||||
} else {
|
||||
LOG.info("Captive file is not provided");
|
||||
}
|
||||
|
||||
equipment.setProfileId(apProfile.getId());
|
||||
|
||||
@@ -99,6 +114,7 @@ public class OpensyncExternalIntegrationSimple implements OpensyncExternalIntegr
|
||||
ret.setSsidProfile(ssidProfiles);
|
||||
ret.setRadiusProfiles(radiusProfiles);
|
||||
ret.setEquipmentLocation(location);
|
||||
ret.setCaptiveProfiles(captiveProfiles);
|
||||
|
||||
} catch (IOException e) {
|
||||
LOG.error("Cannot read config file", e);
|
||||
@@ -110,7 +126,7 @@ public class OpensyncExternalIntegrationSimple implements OpensyncExternalIntegr
|
||||
}
|
||||
|
||||
public void processMqttMessage(String topic, Report report) {
|
||||
LOG.info("Received PlumeStatsReport on topic {} for ap {}\n{}", topic, report.getNodeID(), report);
|
||||
LOG.info("LYNN Received PlumeStatsReport on topic {} for ap {}\n{}", topic, report.getNodeID(), report);
|
||||
}
|
||||
|
||||
public void processMqttMessage(String topic, FlowReport flowReport) {
|
||||
|
||||
@@ -14,5 +14,5 @@
|
||||
<stringAttribute key="org.eclipse.jdt.launching.MODULE_NAME" value="opensync-gateway-static-process"/>
|
||||
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="opensync-gateway-static-process"/>
|
||||
<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.m2e.launchconfig.sourcepathProvider"/>
|
||||
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="--add-opens java.base/java.lang=ALL-UNNAMED -Dssl.props=file://${project_loc:opensync-gateway-static-process}/src/main/resources/app/certs/ssl.properties -Dtip.wlan.httpClientConfig=file://${project_loc:opensync-gateway-static-process}/src/main/resources/app/certs/httpClientConfig.json -Djavax.net.ssl.keyStore=${tip_wlan_service_certs}/client_keystore.jks -Djavax.net.ssl.keyStorePassword=mypassword -Djavax.net.ssl.trustStore=${tip_wlan_service_certs}/truststore.jks -Djavax.net.ssl.trustStorePassword=mypassword -Dtip.wlan.ovsdb.managerAddr=${local_server_address} -Dtip.wlan.ovsdb.listenPort=6640 -Dtip.wlan.ovsdb.redirector.listenPort=6643 -Dtip.wlan.ovsdb.timeoutSec=30 -Dtip.wlan.ovsdb.trustStore=${tip_wlan_service_certs}/truststore.jks -Dtip.wlan.ovsdb.keyStore=${tip_wlan_service_certs}/server.pkcs12 -Dtip.wlan.ovsdb.customerEquipmentFileName=${project_loc:opensync-ext-static}/src/main/resources/EquipmentExample.json -Dtip.wlan.ovsdb.apProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileAPExample.json -Dtip.wlan.ovsdb.ssidProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileSsid.json -Dtip.wlan.ovsdb.locationFileName=${project_loc:opensync-ext-static}/src/main/resources/LocationBuildingExample.json -Dtip.wlan.ovsdb.radiusProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileRadius.json -Dtip.wlan.mqttBroker.address.internal=${local_server_address} -Dtip.wlan.mqttBroker.address.external=${local_server_address} -Dtip.wlan.mqttBroker.listenPort=1883 -Dspring.profiles.include=use_ssl,use_webtoken_auth,use_single_ds,RestTemplateConfiguration_X509_client_cert_auth,opensync_static_config,mqtt_receiver,ovsdb_redirector,ovsdb_manager"/>
|
||||
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="--add-opens java.base/java.lang=ALL-UNNAMED -Dssl.props=file://${project_loc:opensync-gateway-static-process}/src/main/resources/app/certs/ssl.properties -Dtip.wlan.httpClientConfig=file://${project_loc:opensync-gateway-static-process}/src/main/resources/app/certs/httpClientConfig.json -Djavax.net.ssl.keyStore=${tip_wlan_service_certs}/client_keystore.jks -Djavax.net.ssl.keyStorePassword=mypassword -Djavax.net.ssl.trustStore=${tip_wlan_service_certs}/truststore.jks -Djavax.net.ssl.trustStorePassword=mypassword -Dtip.wlan.ovsdb.managerAddr=${local_server_address} -Dtip.wlan.ovsdb.listenPort=6640 -Dtip.wlan.ovsdb.redirector.listenPort=6643 -Dtip.wlan.ovsdb.timeoutSec=30 -Dtip.wlan.ovsdb.trustStore=${tip_wlan_service_certs}/truststore.jks -Dtip.wlan.ovsdb.keyStore=${tip_wlan_service_certs}/server.pkcs12 -Dtip.wlan.ovsdb.customerEquipmentFileName=${project_loc:opensync-ext-static}/src/main/resources/EquipmentExample.json -Dtip.wlan.ovsdb.apProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileAPExample.json -Dtip.wlan.ovsdb.ssidProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileSsid.json -Dtip.wlan.ovsdb.locationFileName=${project_loc:opensync-ext-static}/src/main/resources/LocationBuildingExample.json -Dtip.wlan.ovsdb.radiusProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileRadius.json -Dtip.wlan.ovsdb.captiveProfileFileName=${project_loc:opensync-ext-static}/src/main/resources/ProfileCaptive.json -Dtip.wlan.mqttBroker.address.internal=${local_server_address} -Dtip.wlan.mqttBroker.address.external=${local_server_address} -Dtip.wlan.mqttBroker.listenPort=1883 -Dspring.profiles.include=use_ssl,use_webtoken_auth,use_single_ds,RestTemplateConfiguration_X509_client_cert_auth,opensync_static_config,mqtt_receiver,ovsdb_redirector,ovsdb_manager"/>
|
||||
</launchConfiguration>
|
||||
|
||||
Reference in New Issue
Block a user