From a161ec1105983d9ebc40a4f2ccc3472e54d988a4 Mon Sep 17 00:00:00 2001 From: tc-wleite Date: Wed, 30 Oct 2024 22:09:47 -0300 Subject: [PATCH 1/3] '#2337: Sort messages properly, after merging process. --- .../src/main/java/iped/parsers/whatsapp/WhatsAppParser.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/iped-parsers/iped-parsers-impl/src/main/java/iped/parsers/whatsapp/WhatsAppParser.java b/iped-parsers/iped-parsers-impl/src/main/java/iped/parsers/whatsapp/WhatsAppParser.java index 247510dbe5..f61f3454d0 100644 --- a/iped-parsers/iped-parsers-impl/src/main/java/iped/parsers/whatsapp/WhatsAppParser.java +++ b/iped-parsers/iped-parsers-impl/src/main/java/iped/parsers/whatsapp/WhatsAppParser.java @@ -735,6 +735,11 @@ public int compare(WhatsAppContext o1, WhatsAppContext o2) { logger.info("Creating separate report for {}", DB.getPath()); //$NON-NLS-1$ } + // sort messages + for (Chat chat : dbChatList) { + Message.sort(chat.getMessages()); + } + // create report for main dbs and backups which main db was not found createReport(dbChatList, searcher, contacts, handler, extractor, account, tmpDB, context); From 7a08ee5aaeec34c074f3ac03d7ffa1a2c9724b7f Mon Sep 17 00:00:00 2001 From: Luis Nassif Date: Fri, 1 Nov 2024 18:40:46 -0300 Subject: [PATCH 2/3] closes #2335: force audio resampling to 16khz by @hauck-jvsh --- iped-app/resources/config/conf/AudioTranscriptConfig.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/iped-app/resources/config/conf/AudioTranscriptConfig.txt b/iped-app/resources/config/conf/AudioTranscriptConfig.txt index 7814aa1331..55b7bd9cc8 100644 --- a/iped-app/resources/config/conf/AudioTranscriptConfig.txt +++ b/iped-app/resources/config/conf/AudioTranscriptConfig.txt @@ -51,7 +51,7 @@ implementationClass = iped.engine.task.transcript.VoskTranscriptTask language = auto # Command to convert audios to wav before transcription. Do not change $INPUT or $OUTPUT params. -convertCommand = mplayer -benchmark -vo null -vc null -srate 16000 -af format=s16le,channels=1 -ao pcm:fast:file=$OUTPUT $INPUT +convertCommand = mplayer -benchmark -vo null -vc null -srate 16000 -af format=s16le,resample=16000,channels=1 -ao pcm:fast:file=$OUTPUT $INPUT # Mime types or supertypes to process. If you want to add videos use ; as separator and update 'convertCommand'. mimesToProcess = audio/3gpp; audio/3gpp2; audio/vnd.3gpp.iufp; audio/x-aac; audio/x-aiff; audio/amr; audio/amr-wb; audio/amr-wb+; audio/mp4; audio/ogg; audio/vorbis; audio/x-oggflac; audio/x-oggpcm; audio/opus; audio/speex; audio/qcelp; audio/vnd.wave; audio/x-caf; audio/x-ms-wma; audio/x-opus+ogg; audio/ilbc From d2860d6e4296ffd5a74e10d92cb5640961d758f6 Mon Sep 17 00:00:00 2001 From: tc-wleite Date: Thu, 7 Nov 2024 00:28:03 -0300 Subject: [PATCH 3/3] '#2357: Warn the user about possibly corrupted JRE. --- .../src/main/java/iped/app/ui/AppMain.java | 2 +- .../app/ui/splash/SplashScreenManager.java | 26 +++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/iped-app/src/main/java/iped/app/ui/AppMain.java b/iped-app/src/main/java/iped/app/ui/AppMain.java index 3ac075181d..436ab3e223 100644 --- a/iped-app/src/main/java/iped/app/ui/AppMain.java +++ b/iped-app/src/main/java/iped/app/ui/AppMain.java @@ -32,7 +32,7 @@ public class AppMain { private static final String BUNDLED_JRE_VERSION = "11.0.13"; - private static final String HOME_JRE_FOLDER = ".iped/jre-" + BUNDLED_JRE_VERSION; + public static final String HOME_JRE_FOLDER = ".iped/jre-" + BUNDLED_JRE_VERSION; File casePath; diff --git a/iped-app/src/main/java/iped/app/ui/splash/SplashScreenManager.java b/iped-app/src/main/java/iped/app/ui/splash/SplashScreenManager.java index b73efa3268..ed53fe3cb2 100644 --- a/iped-app/src/main/java/iped/app/ui/splash/SplashScreenManager.java +++ b/iped-app/src/main/java/iped/app/ui/splash/SplashScreenManager.java @@ -8,7 +8,9 @@ import java.awt.RenderingHints; import java.awt.SplashScreen; import java.awt.geom.Rectangle2D; +import java.io.File; +import iped.app.ui.AppMain; import iped.engine.Version; import iped.engine.config.ConfigurationManager; import iped.engine.config.SplashScreenConfig; @@ -157,6 +159,30 @@ public void run() { } } catch (IllegalStateException e) { // Splash was already closed, just ignore this exception. + } catch (NoClassDefFoundError | UnsatisfiedLinkError e) { + // Maybe JRE is corrupted + e.printStackTrace(); + + // Check if the OS is Windows + String os = System.getProperty("os.name"); + if (os != null && os.toLowerCase().startsWith("windows")) { + + // Check if user home is valid + File userHome = new File(System.getProperty("user.home")); + if (userHome != null && userHome.exists() && userHome.isDirectory()) { + + // Check if the is a JRE in user home + File userJrePath = new File(userHome, AppMain.HOME_JRE_FOLDER); + if (userJrePath.exists()) { + + // Warn the user about possibly corrupted JRE + System.err.println("\n\nERROR: User JRE may be corrupted!"); + System.err.println("Please, try to delete \"" + userJrePath.getAbsolutePath() + + "\" folder and run IPED again."); + System.err.println(""); + } + } + } } catch (Exception e) { e.printStackTrace(); }