mirror of
https://github.com/yggdrasil-network/crispa-android.git
synced 2025-01-22 07:56:30 +00:00
1. added dex loader
This commit is contained in:
parent
2786d8f8ca
commit
d129230898
@ -67,7 +67,7 @@ dependencies {
|
||||
implementation 'com.google.android.material:material:1.3.0-alpha02'
|
||||
implementation 'com.google.code.gson:gson:2.8.6'
|
||||
implementation 'com.hbb20:ccp:2.4.0'
|
||||
implementation "app.artyomd.injector:injector-android:{latest-version}"
|
||||
implementation 'app.artyomd.injector:injector-android:0.5.0'
|
||||
|
||||
testImplementation 'junit:junit:4.12'
|
||||
androidTestImplementation 'androidx.test:runner:1.2.0'
|
||||
|
@ -11,6 +11,8 @@ import android.view.View
|
||||
import android.widget.*
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.preference.PreferenceManager
|
||||
import app.artyomd.injector.DexUtils
|
||||
import dalvik.system.DexFile
|
||||
import io.github.chronosx88.yggdrasil.models.DNSInfo
|
||||
import io.github.chronosx88.yggdrasil.models.PeerInfo
|
||||
import io.github.chronosx88.yggdrasil.models.config.DNSInfoListAdapter
|
||||
@ -22,6 +24,7 @@ import io.github.chronosx88.yggdrasil.models.config.Utils.Companion.deserializeS
|
||||
import io.github.chronosx88.yggdrasil.models.config.Utils.Companion.deserializeStringSet2PeerInfoSet
|
||||
import io.github.chronosx88.yggdrasil.models.config.Utils.Companion.serializeDNSInfoSet2StringList
|
||||
import io.github.chronosx88.yggdrasil.models.config.Utils.Companion.serializePeerInfoSet2StringList
|
||||
import java.io.File
|
||||
import java.lang.reflect.Method
|
||||
import kotlin.concurrent.thread
|
||||
|
||||
@ -149,6 +152,16 @@ class MainActivity : AppCompatActivity() {
|
||||
showToast("The method is: " + m.toString())
|
||||
}
|
||||
}
|
||||
val sourceDir = listOf<File>(File(this.applicationInfo.sourceDir))
|
||||
DexUtils.loadDex(this, sourceDir)
|
||||
showToast("Getting dummy.Dummy class methods list")
|
||||
if(methods.isEmpty()){
|
||||
showToast("No class methods found in dummy.Dummy")
|
||||
} else {
|
||||
for (m in methods) {
|
||||
showToast("The method is: " + m.toString())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun stopVpn(){
|
||||
|
@ -4,6 +4,7 @@ buildscript {
|
||||
ext.kotlin_version = '1.3.72'
|
||||
repositories {
|
||||
google()
|
||||
mavenCentral()
|
||||
jcenter()
|
||||
}
|
||||
dependencies {
|
||||
|
Loading…
x
Reference in New Issue
Block a user