diff --git a/build/debian/otgc_native.sh b/build/debian/otgc_native.sh index bccc5a5..8ac5ba2 100755 --- a/build/debian/otgc_native.sh +++ b/build/debian/otgc_native.sh @@ -11,7 +11,7 @@ # Constants PROJECT_NAME="otgc" -VERSION="2.4.0" +VERSION="2.5.0" program=$0 diff --git a/extlibs/patchs/remove_cred_by_credid.patch b/extlibs/patchs/remove_cred_by_credid.patch index 190a2fb..c2f1a47 100644 --- a/extlibs/patchs/remove_cred_by_credid.patch +++ b/extlibs/patchs/remove_cred_by_credid.patch @@ -1,5 +1,5 @@ diff --git a/include/oc_pki.h b/include/oc_pki.h -index acbab8c..c16b512 100644 +index acbab8c7..c16b512b 100644 --- a/include/oc_pki.h +++ b/include/oc_pki.h @@ -45,6 +45,9 @@ int oc_pki_add_trust_anchor(size_t device, const unsigned char *cert, @@ -13,10 +13,10 @@ index acbab8c..c16b512 100644 } #endif diff --git a/security/oc_pki.c b/security/oc_pki.c -index a9306c2..c9b3b15 100644 +index a9306c23..52755576 100644 --- a/security/oc_pki.c +++ b/security/oc_pki.c -@@ -354,6 +354,16 @@ oc_pki_add_trust_anchor(size_t device, const unsigned char *cert, +@@ -354,6 +354,17 @@ oc_pki_add_trust_anchor(size_t device, const unsigned char *cert, return pki_add_trust_anchor(device, cert, cert_size, OC_CREDUSAGE_TRUSTCA); } @@ -27,6 +27,7 @@ index a9306c2..c9b3b15 100644 + if (cred) + { + oc_sec_remove_cred(cred, device); ++ oc_sec_dump_cred(device); + } +} + @@ -34,7 +35,7 @@ index a9306c2..c9b3b15 100644 typedef int dummy_declaration; #endif /* !OC_PKI */ diff --git a/swig/swig_interfaces/oc_pki.i b/swig/swig_interfaces/oc_pki.i -index 2765e56..9910770 100644 +index 2765e562..9910770c 100644 --- a/swig/swig_interfaces/oc_pki.i +++ b/swig/swig_interfaces/oc_pki.i @@ -105,4 +105,6 @@ void jni_pki_set_security_profile(size_t device, diff --git a/pom.xml b/pom.xml index d217ef4..4fc3c4a 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ otgc otgc - 2.4.0 + 2.5.0 UTF-8 diff --git a/src/main/java/org/openconnectivity/otgc/domain/usecase/trustanchor/GetTrustAnchorUseCase.java b/src/main/java/org/openconnectivity/otgc/domain/usecase/trustanchor/GetTrustAnchorUseCase.java index 3a8f7bd..31b7f46 100644 --- a/src/main/java/org/openconnectivity/otgc/domain/usecase/trustanchor/GetTrustAnchorUseCase.java +++ b/src/main/java/org/openconnectivity/otgc/domain/usecase/trustanchor/GetTrustAnchorUseCase.java @@ -45,7 +45,8 @@ public Single> execute() { List trustAnchorList = new ArrayList<>(); for (OcCredential cred : credentials.getCredList()) { if (cred.getCredusage() != null - && cred.getCredusage() == OcfCredUsage.OC_CREDUSAGE_TRUSTCA) { + && (cred.getCredusage() == OcfCredUsage.OC_CREDUSAGE_MFGTRUSTCA + || cred.getCredusage() == OcfCredUsage.OC_CREDUSAGE_TRUSTCA)) { trustAnchorList.add(cred); } } diff --git a/src/main/java/org/openconnectivity/otgc/view/toolbar/ToolbarView.java b/src/main/java/org/openconnectivity/otgc/view/toolbar/ToolbarView.java index 6595aec..c040dca 100644 --- a/src/main/java/org/openconnectivity/otgc/view/toolbar/ToolbarView.java +++ b/src/main/java/org/openconnectivity/otgc/view/toolbar/ToolbarView.java @@ -114,7 +114,7 @@ public OcfOxmType onGetOxM(List supportedOxm) { Platform.runLater(() -> { ChoiceDialog alertDialog = new ChoiceDialog(options.get(0), options); alertDialog.setTitle(resourceBundle.getString("dialog.title.select_oxm")); - alertDialog.setHeaderText("OXM: "); + alertDialog.setHeaderText("OTM: "); Optional result = alertDialog.showAndWait(); if (result.isPresent()) { diff --git a/src/main/java/org/openconnectivity/otgc/view/trustanchor/TrustAnchorViewCell.java b/src/main/java/org/openconnectivity/otgc/view/trustanchor/TrustAnchorViewCell.java index 05f49f9..267449d 100644 --- a/src/main/java/org/openconnectivity/otgc/view/trustanchor/TrustAnchorViewCell.java +++ b/src/main/java/org/openconnectivity/otgc/view/trustanchor/TrustAnchorViewCell.java @@ -28,6 +28,7 @@ public class TrustAnchorViewCell extends ListCell { private GridPane gridPane = new GridPane(); private Label credId = new Label(); private Label credSubject = new Label(); + private Label credUsage = new Label(); public TrustAnchorViewCell() { configureGrid(); @@ -42,6 +43,7 @@ private void configureGrid() { private void addControlsToGrid() { gridPane.add(credId, 0, 0); gridPane.add(credSubject, 0, 1); + gridPane.add(credUsage, 0, 2); } @Override @@ -65,6 +67,7 @@ private void addContent(OcCredential cred) { credId.setText("Credential ID: " + String.valueOf(cred.getCredid())); credSubject.setText("UUID: " + cred.getSubjectuuid()); + credSubject.setText("Usage: " + cred.getCredusage().getValue()); setGraphic(gridPane); } diff --git a/src/main/resources/properties/Strings_en.properties b/src/main/resources/properties/Strings_en.properties index 7f8adae..b19dd3b 100644 --- a/src/main/resources/properties/Strings_en.properties +++ b/src/main/resources/properties/Strings_en.properties @@ -165,7 +165,7 @@ linkdevices.label.role_id=Role ID linkdevices.label.role_authority= Role authority ## Dialog -dialog.title.select_oxm=Select OXM +dialog.title.select_oxm=Select OTM dialog.title.set_device_name=Set device name dialog.title.confirm_reset_mode=Reset device dialog.message.confirm_reset_mode=Are you sure you want to delete all linked devices? @@ -173,4 +173,4 @@ dialog.message.confirm_reset_mode=Are you sure you want to delete all linked dev ## Iotivity oxm.just_works=Just Works oxm.random_pin=Random Pin -oxm.manufacturer_certificate=Manufacturer Certificate \ No newline at end of file +oxm.manufacturer_certificate=PKI \ No newline at end of file