From c436a555bcd4025a139068351792560db24f8519 Mon Sep 17 00:00:00 2001 From: Shabirmean Date: Fri, 29 Apr 2016 16:41:19 +0530 Subject: [PATCH] Changes to use keystones provided by default and subsequent modifications to the agent enrolment code --- .../agent/enrollment/EnrollmentManager.java | 12 +++++++++--- .../src/main/resources/certs/wso2certs.jks | Bin 0 -> 11731 bytes .../src/main/resources/p2.inf | 3 +++ 3 files changed, 12 insertions(+), 3 deletions(-) create mode 100644 features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/certs/wso2certs.jks diff --git a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.impl/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/agent/enrollment/EnrollmentManager.java b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.impl/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/agent/enrollment/EnrollmentManager.java index a4347cbae..87cd25e28 100644 --- a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.impl/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/agent/enrollment/EnrollmentManager.java +++ b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.impl/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/agent/enrollment/EnrollmentManager.java @@ -44,6 +44,7 @@ import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.core.AgentManager; import org.wso2.carbon.device.mgt.iot.virtualfirealarm.agent.exception.AgentCoreOperationException; import sun.security.x509.X509CertImpl; +import java.io.IOException; import java.math.BigInteger; import java.net.MalformedURLException; import java.net.URL; @@ -82,6 +83,7 @@ public class EnrollmentManager { private static final String KEY_PAIR_ALGORITHM = "RSA"; private static final String PROVIDER = "BC"; private static final String SIGNATURE_ALG = "SHA1withRSA"; + private static final String CERT_IS_CA_EXTENSION = "is_ca"; private static final int KEY_SIZE = 2048; // Seed to our PRNG. Make sure this is initialised randomly, NOT LIKE THIS @@ -376,9 +378,9 @@ public class EnrollmentManager { log.debug(((X509Certificate) cert).getIssuerDN().getName()); } - //TODO: Need to identify the correct certificate. - // I have chosen the CA cert based on its BasicConstraint criticality being set to "true" - if (((X509CertImpl) cert).getBasicConstraintsExtension().isCritical()) { + // I have chosen the CA cert based on its BasicConstraintExtension "is_ca" being set to "true" + // This is because the returned keystore may contain many certificates including RAs. + if (((Boolean) ((X509CertImpl) cert).getBasicConstraintsExtension().get(CERT_IS_CA_EXTENSION))) { serverCertPublicKey = cert.getPublicKey(); } } @@ -396,6 +398,10 @@ public class EnrollmentManager { String errorMsg = "Could not retrieve [Server-Certificates] from the response message from SCEP-Server."; log.error(errorMsg); throw new AgentCoreOperationException(errorMsg, e); + } catch (IOException e) { + String errorMsg = "Error occurred whilst trying to get property ['is_ca'] from the retreived Certificates"; + log.error(errorMsg); + throw new AgentCoreOperationException(errorMsg, e); } return serverCertPublicKey; diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/certs/wso2certs.jks b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/certs/wso2certs.jks new file mode 100644 index 0000000000000000000000000000000000000000..00589cdf0d75c0f87bdf9dc63d601d58abb3e0d1 GIT binary patch literal 11731 zcmd6M1yEgGmnHAv?ry;)$iv-(dywD(g1fuBySux)1}8W{65JhvyEpm1?!VK2_srB( z%~btW?^M0L@2z{!xwX&Q>#X&1{BjHi1_pc^kZ%J324$!B#n8^-?XR+Ki9sP47;G@e z57r-q1O@jV3IGA11)>4~kYEsgu-0is6VJA$IKyOHOFzZ%Dw`i`+lTlgF^PDfsDvN3 zSm>Lp=TrjokIx_bFjH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ll5XjySQ?pw@jAK^);`}i zIuWkpTk)cN>4;zBfS=}v^oyM`-VKJ;ROp`_jO< z56qYOvX`VyRJn3+eWI@N;Z>4^TQ{Ylh^Ge)FdvnV*t(`l8GqbkRogt#C(eABADXlt zYObyCbs1CN&i=`8B&sOSdHg`$%KqLh)bv1^Kk#^kC0d;QLp}7)!E;FREyv`M0Zre4 zO$gS!1}vNpv;SM*;e7D?r*iri1|Al+x0U?~Jbx$tUjxqxI0mIfr0@s0m{WMNk6ucZ!ObhcjLXS&p1Uw0sKf<3O};4<57SkzGS7x6B!XMg zroo+5Muq=n^%X8Xx6g5kGvnLH0fkzlrxG9aM@8A2oMV-h_loWwuXgi_)8Z-E)yg3( zw~Gm`kYpADUx|$@0>tJpRi7hZjZ77W>sh^aKAawos8gXhOJNWsi(t)>h0SOU0$SsaJtCn&Kc>I`S*vNDMZLfip2LSy^MBcZwjHOr4xq( z)y!4w0+kwIYSllE{Md}pZWua7{FvWXr`VuMoRK&VPGuz!g{;y z;CF}i_4Tn@0EYcukpG3NEwuib0RK^-M(HNkD;~IBYH;Q$IRUO@G{{rWhCgJR%&?@9 zr9z5~`#vJ<+x_-IQE_MzG*szOI_^yW_t)z^le26n55Gp@rqW@aw&j=HTXcCs!j&ua zZLezWic(ye#N6-GCS}fi$qctZK537-8C4B&dn=^WmHi;RA0O48Bo&6LVsaEM{|%CH BICB61 literal 0 HcmV?d00001 diff --git a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf index ec1c2fafb..1cf4d078d 100644 --- a/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf +++ b/features/iot-plugins-feature/virtual-fire-alarm-plugin-feature/org.wso2.carbon.device.mgt.iot.virtualfirealarm.feature/src/main/resources/p2.inf @@ -14,6 +14,8 @@ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../featur org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.virtualfirealarm_${feature.version}/datasources/,target:${installFolder}/../../conf/datasources/,overwrite:true);\ org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../database/);\ org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.virtualfirealarm_${feature.version}/database/,target:${installFolder}/../../database/,overwrite:true);\ +org.eclipse.equinox.p2.touchpoint.natives.mkdir(path:${installFolder}/../../resources/security/);\ +org.eclipse.equinox.p2.touchpoint.natives.copy(source:${installFolder}/../features/org.wso2.carbon.device.mgt.iot.virtualfirealarm_${feature.version}/certs/,target:${installFolder}/../../resources/security/,overwrite:true);\ instructions.unconfigure = \ org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../conf/device-types/virtual_firealarm.json);\ @@ -30,3 +32,4 @@ org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../dep org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.type-view);\ org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.policy-edit);\ org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../deployment/server/jaggeryapps/devicemgt/app/units/cdmf.unit.device.type.virtual_firealarm.policy-view);\ +org.eclipse.equinox.p2.touchpoint.natives.remove(path:${installFolder}/../../resources/security/wso2certs.jks);\