Here is a simple way to use ADB over wifi with your device. Make sure that ADB can reach your device over the network.
-
Connect device to usb
-
Restart the ADB daemon to listening on TCP port
adb tcpip 5555
private ImageView imageView; | |
// ... | |
public void onDoingSomethingGood() { | |
new Thread(new Runnable() { | |
public void run() { | |
final Bitmap bitmap = loadImageFromOutside("http://mycloud.com/image.png"); | |
imageView.post(new Runnable() { | |
public void run() { | |
imageView.setImageBitmap(bitmap); |
/*https://www.youtube.com/watch?v=_JOapnq8hrs&t=852s | |
video tutorial for consent sdk android | |
*/ | |
/*https://www.youtube.com/watch?v=_JOapnq8hrs&t=852s | |
If you want i do your job you can hair me any time at Upwork.com: https://www.upwork.com/o/profiles/users/_~01cdffbf3d8a9ad74b/ |
#get apks from server? wget -np -e robots=off -m site.com/apk/folder/ | |
#Place all apks in the same dir as py file or change os.listdir parameter | |
#you can get del.js from my repo https://github.com/eybisi/fridaScripts/blob/master/del.js | |
import os | |
from androguard.core.bytecodes import apk | |
import frida | |
import time | |
device = frida.get_usb_device() | |
files = [f for f in os.listdir("./")] | |
for f in files: |
<project xmlns="http://maven.apache.org/POM/4.0.0" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 | |
http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.example.android</groupId> | |
<artifactId>my-android-library</artifactId> | |
<version>0.1</version> | |
<packaging>apklib</packaging> | |
<name>my-android-library</name> |
package com.example | |
import android.view.View | |
import android.view.ViewGroup | |
import androidx.annotation.Px | |
import androidx.core.view.ViewCompat | |
import androidx.core.view.updateLayoutParams | |
import androidx.recyclerview.widget.RecyclerView | |
import androidx.viewpager2.widget.ViewPager2 |
public static float convertPixelsToDp(float px){ | |
DisplayMetrics metrics = Resources.getSystem().getDisplayMetrics(); | |
float dp = px / (metrics.densityDpi / 160f); | |
return Math.round(dp); | |
} | |
public static float convertDpToPixel(float dp){ | |
DisplayMetrics metrics = Resources.getSystem().getDisplayMetrics(); | |
float px = dp * (metrics.densityDpi / 160f); | |
return Math.round(px); |
# Use ADB to find and pull an Android package from device | |
adb shell pm list packages | |
adb shell pm path com.package | |
adb pull /data/app/com.package.app.apk | |
# With APK local, can now adb push to device and run it | |
# Use tcpdump to log traffic to mon.txt | |
sudo tcpdump -A dst port 80 > mon.txt |
public class CustomAdapter extends RecyclerView.Adapter<CustomAdapter.ViewHolder> { | |
private List<CustomObject> objects; | |
private OnItemSelectedListener listener; | |
private final boolean withContextMenu; | |
class ViewHolder extends RecyclerView.ViewHolder | |
implements View.OnClickListener, View.OnCreateContextMenuListener, PopupMenu.OnMenuItemClickListener { | |
@BindView(R.id.custom_name) |
/* | |
This is using the JS port of Google's libphonenumber. | |
As far as I know, though, all of the APIs are the same or similar | |
*/ | |
// I just hardcoded "US" as the country, but of course you can use any country iso code | |
var ctry = 'US'; | |
var exampleNumber = i18n.phonenumbers.PhoneNumberUtil.getInstance() | |
.getExampleNumberForType(ctry, i18n.phonenumbers.PhoneNumberType.MOBILE); // returns PhoneNumber instance |