From 3c777278534f2cd319a87d35dc6847abd396c516 Mon Sep 17 00:00:00 2001 From: Sid Dahiya <53239974+sid-dahiya@users.noreply.github.com> Date: Mon, 6 Mar 2023 13:37:48 -0800 Subject: [PATCH] Add StampEventIKeyForConcerns option in Java layer (#1107) * Add StampEventIKeyForConcerns option in Java layer * Update modules version and bump version * Bump version to speed up release. --- .../com/microsoft/applications/events/PrivacyGuard.java | 8 ++++++-- .../applications/events/PrivacyGuardInitConfig.java | 6 ++++++ lib/include/public/Version.hpp | 6 +++--- lib/jni/PrivacyGuard_jni.cpp | 6 +++++- lib/modules | 2 +- 5 files changed, 21 insertions(+), 7 deletions(-) diff --git a/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuard.java b/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuard.java index 5f673cc8d..d29618e84 100644 --- a/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuard.java +++ b/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuard.java @@ -15,6 +15,7 @@ private static native boolean nativeInitializePrivacyGuard( boolean UseEventFieldPrefix, boolean ScanForUrls, boolean DisableAdvancedScans, + boolean StampEventIKeyForConcerns, String domainName, String machineName, Object[] userNames, @@ -31,7 +32,8 @@ private static native boolean nativeInitializePrivacyGuardWithoutCommonDataConte String SummaryEventName, boolean UseEventFieldPrefix, boolean ScanForUrls, - boolean DisableAdvancedScans + boolean DisableAdvancedScans, + boolean StampEventIKeyForConcerns ); /** @@ -61,6 +63,7 @@ public static boolean initialize(PrivacyGuardInitConfig initConfig) initConfig.UseEventFieldPrefix, initConfig.ScanForUrls, initConfig.DisableAdvancedScans, + initConfig.StampEventIKeyForConcerns, initConfig.DataContext.domainName, initConfig.DataContext.machineName, initConfig.DataContext.userNames.toArray(), @@ -78,7 +81,8 @@ public static boolean initialize(PrivacyGuardInitConfig initConfig) initConfig.SummaryEventName, initConfig.UseEventFieldPrefix, initConfig.ScanForUrls, - initConfig.DisableAdvancedScans + initConfig.DisableAdvancedScans, + initConfig.StampEventIKeyForConcerns ); } } diff --git a/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuardInitConfig.java b/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuardInitConfig.java index 084c7bb83..c5ded57ef 100644 --- a/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuardInitConfig.java +++ b/lib/android_build/maesdk/src/main/java/com/microsoft/applications/events/PrivacyGuardInitConfig.java @@ -69,4 +69,10 @@ public PrivacyGuardInitConfig(ILogger logger, CommonDataContext context) * Default value is `false`. */ public boolean DisableAdvancedScans = false; + + /** + * (OPTIONAL) Should stamp the iKey for the scanned event as an additional property on Concerns. + * Default value is `false`. + */ + public boolean StampEventIKeyForConcerns = false; } diff --git a/lib/include/public/Version.hpp b/lib/include/public/Version.hpp index 4d2e64473..592f478b0 100644 --- a/lib/include/public/Version.hpp +++ b/lib/include/public/Version.hpp @@ -6,8 +6,8 @@ #define MAT_VERSION_HPP // WARNING: DO NOT MODIFY THIS FILE! // This file has been automatically generated, manual changes will be lost. -#define BUILD_VERSION_STR "3.7.46.1" -#define BUILD_VERSION 3,7,46,1 +#define BUILD_VERSION_STR "3.7.62.1" +#define BUILD_VERSION 3,7,62,1 #ifndef RESOURCE_COMPILER_INVOKED #include "ctmacros.hpp" @@ -18,7 +18,7 @@ namespace MAT_NS_BEGIN { uint64_t const Version = ((uint64_t)3 << 48) | ((uint64_t)7 << 32) | - ((uint64_t)46 << 16) | + ((uint64_t)62 << 16) | ((uint64_t)1); } MAT_NS_END diff --git a/lib/jni/PrivacyGuard_jni.cpp b/lib/jni/PrivacyGuard_jni.cpp index 4f7c06d9d..8fd23867a 100644 --- a/lib/jni/PrivacyGuard_jni.cpp +++ b/lib/jni/PrivacyGuard_jni.cpp @@ -53,7 +53,8 @@ Java_com_microsoft_applications_events_PrivacyGuard_nativeInitializePrivacyGuard jstring SummaryEventName, jboolean UseEventFieldPrefix, jboolean ScanForUrls, - jboolean DisableAdvancedScans) { + jboolean DisableAdvancedScans, + jboolean StampEventIKeyForConcerns) { if (spPrivacyGuard != nullptr) { return false; } @@ -76,6 +77,7 @@ Java_com_microsoft_applications_events_PrivacyGuard_nativeInitializePrivacyGuard config.UseEventFieldPrefix = static_cast(UseEventFieldPrefix); config.ScanForUrls = static_cast(ScanForUrls); config.DisableAdvancedScans = static_cast(DisableAdvancedScans); + config.StampEventIKeyForConcerns = static_cast(StampEventIKeyForConcerns); spPrivacyGuard = std::make_shared(config); return true; @@ -92,6 +94,7 @@ Java_com_microsoft_applications_events_PrivacyGuard_nativeInitializePrivacyGuard jboolean UseEventFieldPrefix, jboolean ScanForUrls, jboolean DisableAdvancedScans, + jboolean StampEventIKeyForConcerns, jstring domainName, jstring machineName, jobjectArray userNames, @@ -131,6 +134,7 @@ Java_com_microsoft_applications_events_PrivacyGuard_nativeInitializePrivacyGuard config.UseEventFieldPrefix = static_cast(UseEventFieldPrefix); config.ScanForUrls = static_cast(ScanForUrls); config.DisableAdvancedScans = static_cast(DisableAdvancedScans); + config.StampEventIKeyForConcerns = static_cast(StampEventIKeyForConcerns); spPrivacyGuard = std::make_shared(config); return true; diff --git a/lib/modules b/lib/modules index 6eb4b9334..883a3e3b9 160000 --- a/lib/modules +++ b/lib/modules @@ -1 +1 @@ -Subproject commit 6eb4b93345b4ce62406dc4669d7d086fb179a5ee +Subproject commit 883a3e3b9c63fa713bdde31bf7417e63e416fe4e