-
Notifications
You must be signed in to change notification settings - Fork 565
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Class not found when starting vpnconfiguration #151
Comments
Hmm, that's very weird. Did you compile it by yourself or did you take the release (which version)? |
I grabbed latest release from here, 2.3, running run win64 version |
OK, thank you for your stacktrace. According to stackoverflow, Maybe this may fix the problem: diff --git a/app/src/main/java/com/genymobile/gnirehtet/GnirehtetService.java b/app/src/main/java/com/genymobile/gnirehtet/GnirehtetService.java
index 7e8b716..57ddc20 100644
--- a/app/src/main/java/com/genymobile/gnirehtet/GnirehtetService.java
+++ b/app/src/main/java/com/genymobile/gnirehtet/GnirehtetService.java
@@ -55,6 +55,7 @@ public class GnirehtetService extends VpnService {
public static void start(Context context, VpnConfiguration config) {
Intent intent = new Intent(context, GnirehtetService.class);
+ intent.setExtrasClassLoader(GnirehtetService.class.getClassLoader());
intent.setAction(ACTION_START_VPN);
intent.putExtra(GnirehtetService.EXTRA_VPN_CONFIGURATION, config);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { |
what would i need to do to go about running this change? |
SHA256: 2fe53280e3af495d78cb4edd14e6690d015f34fd47bb0d12ada8431006bc7ca4 |
Seems its still running into the same error |
Sorry, I did not precise: you need to reinstall it.
(otherwise it will keep the old version) |
I tried reinstall, uninstall and installing again, still outputting same errors |
What about: diff --git a/app/src/main/java/com/genymobile/gnirehtet/GnirehtetControlReceiver.java b/app/src/main/java/com/genymobile/gnirehtet/GnirehtetControlReceiver.java
index 0437951..3b7996a 100644
--- a/app/src/main/java/com/genymobile/gnirehtet/GnirehtetControlReceiver.java
+++ b/app/src/main/java/com/genymobile/gnirehtet/GnirehtetControlReceiver.java
@@ -97,6 +97,7 @@ public class GnirehtetControlReceiver extends BroadcastReceiver {
private void requestAuthorization(Context context, Intent vpnIntent, VpnConfiguration config) {
// we must send the intent with startActivityForResult, so we need to send it from an activity
Intent intent = new Intent(context, AuthorizationActivity.class);
+ intent.setExtrasClassLoader(GnirehtetControlReceiver.class.getClassLoader());
intent.putExtra(AuthorizationActivity.EXTRA_VPN_INTENT, vpnIntent);
intent.putExtra(EXTRA_VPN_CONFIGURATION, config);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); SHA256: 36f86daefd87512aa707d4bef7f2d12d156297017945f5c0eb1db14d4b08ce34 |
OK, so I don't know what the problem is. I cannot reproduce it on my device. This intent should be correct (and is correct on many devices), I don't understand why it can't find
At worst, |
Ah, but with the patch, your logs do not contain the error. |
If you take the v2.3 release, do you reproduce the first error, or get logs like these ones? |
I managed to resolve the issue. |
Attempting to get this working, running on Windows 7 and Samsung galaxy s7, android version 8.0.0
Was getting the broadcast completed: result=0 and was looking through other issues on here and was looking through my adb logcat and found the following (attached full logcat.txt too):
logcat.txt
The text was updated successfully, but these errors were encountered: