Compare commits

...

11 Commits
1.5.0 ... 2.6.1

8 changed files with 57 additions and 25 deletions

View File

@ -1,3 +1,10 @@
Mon, July 8
-----------
- Fix a bug which caused the profile manager to fail to detect Firefox on some systems
- Fix a bug which caused the profile manager to use an unwritable directory on some systems
- Fix a bug where if user tried to run it from the home directory, the application would make sure that no firefoxes existed in any subdirectory before running
Thu, March 7
------------

View File

@ -12,17 +12,17 @@ noscript
11.4.29
https://addons.mozilla.org/firefox/downloads/file/4206186/noscript-11.4.29.xpi
localcdn-fork-of-decentraleyes
2.6.64
https://addons.mozilla.org/firefox/downloads/file/4243456/localcdn_fork_of_decentraleyes-2.6.64.xpi
2.6.69
https://addons.mozilla.org/firefox/downloads/file/4303757/localcdn_fork_of_decentraleyes-2.6.69.xpi
onion-in-container-browsing
0.82
https://addons.mozilla.org/firefox/downloads/file/3904685/onion_in_container_browsing-0.82.xpi
javascript-restrictor
0.17
https://addons.mozilla.org/firefox/downloads/file/4190089/javascript_restrictor-0.17.xpi
0.18.1
https://addons.mozilla.org/firefox/downloads/file/4310951/javascript_restrictor-0.18.1.xpi
ublock-origin
1.56.0
https://addons.mozilla.org/firefox/downloads/file/4237670/ublock_origin-1.56.0.xpi
1.58.0
https://addons.mozilla.org/firefox/downloads/file/4290466/ublock_origin-1.58.0.xpi
```
## Chromium
@ -32,15 +32,15 @@ __MSG_extensionName__
1.29
https://clients2.google.com/service/update2/crx
NoScript
11.4.18
11.4.30
https://clients2.google.com/service/update2/crx
LocalCDN
2.6.65
2.6.67
https://clients2.google.com/service/update2/crx
uBlock Origin
1.56.0
1.58.0
https://clients2.google.com/service/update2/crx
__MSG_extensionName__
0.17
0.18.1
https://clients2.google.com/service/update2/crx
```

View File

@ -1,3 +1,3 @@
#Build Number for ANT. Do not edit!
#Tue Mar 19 18:47:29 EDT 2024
build.number=717
#Mon Jul 08 17:35:59 EDT 2024
build.number=726

View File

@ -253,6 +253,8 @@ public class I2PBrowser extends I2PGenericUnsafeBrowser {
}
}
}
if (!this.chromium)
this.firefox = true;
}
return visitURL;
}

View File

@ -295,7 +295,7 @@ public class I2PChromium extends I2PChromiumProfileUnpacker {
}
// now, do the same thing, but with user.dir instead of plugin
// list the directories in the user.dir directory
File userDir = new File(System.getProperty("user.dir"));
File userDir = userHomeDir();
if (userDir.exists()) {
if (isWindows()) {
File searchResult = searchFile(userDir, "ungoogled-chromium.exe");

View File

@ -194,15 +194,17 @@ public class I2PCommonBrowser {
*
* @return the log file for the browser launcher
*/
/*private File logFile() {
// validateUserDirectory();
String userDirectory = System.getProperty("user.dir");
File logDirectory = new File(userDirectory, "logs");
if (!logDirectory.exists()) {
logDirectory.mkdirs();
}
return new File(logDirectory, "browserlauncher.log");
}*/
/*
* private File logFile() {
* // validateUserDirectory();
* String userDirectory = System.getProperty("user.dir");
* File logDirectory = new File(userDirectory, "logs");
* if (!logDirectory.exists()) {
* logDirectory.mkdirs();
* }
* return new File(logDirectory, "browserlauncher.log");
* }
*/
/**
* Get the runtime directory, creating it if create=true.
@ -225,7 +227,7 @@ public class I2PCommonBrowser {
* Returns the runtime directory path based on the given override parameter.
*
* @param override the name of the environment variable to override the
* runtime
* runtime
* directory
* @return the runtime directory path as a string
*/
@ -588,6 +590,13 @@ public class I2PCommonBrowser {
* @return the found file or null if not found
*/
public File searchFile(File directory, String search) {
File hd = new File(System.getProperty("user.home"));
if (hd != null) {
if (directory.getAbsolutePath().equals(hd.getAbsolutePath()))
return null;
}
if (directory == null || !directory.exists() || !directory.canRead())
return null;
if (directory.isDirectory()) {
File[] files = directory.listFiles();
for (File file : files) {
@ -602,4 +611,18 @@ public class I2PCommonBrowser {
}
return null;
}
public File userHomeDir() {
File rd = new File(System.getProperty("user.dir"));
File hd = new File(System.getProperty("user.home"));
if (rd == null || !rd.exists()) {
if (hd == null || !hd.exists()) {
if (rd.getAbsolutePath().equals(hd.getAbsolutePath()))
return null;
}
return rd;
}
logger.info("Runtime directory discovered at: " + rd);
return rd;
}
}

View File

@ -292,7 +292,7 @@ public class I2PFirefox extends I2PFirefoxProfileUnpacker {
}
// now, do the same thing, but with user.dir instead of plugin
// list the directories in the user.dir directory
File userDir = new File(System.getProperty("user.dir"));
File userDir = userHomeDir();
if (userDir.exists()) {
if (isWindows()) {
File searchResult = searchFile(userDir, "firefox-esr.exe");

View File

@ -190,7 +190,7 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
// Ubuntu GNOME does not work, SystemTray.isSupported() returns false
String xdg = System.getenv("XDG_CURRENT_DESKTOP");
boolean dflt = SystemVersion.isWindows() || SystemVersion.isMac() ||
//"XFCE".equals(xdg) ||
"XFCE".equals(xdg) ||
"KDE".equals(xdg) || "LXDE".equals(xdg);
return _context.getProperty(PROP_DTG_ENABLED, dflt);
}