Why Does TowelRoot Require Internet / Network Access?

Since TowelRoot's code is not publicly available, I resorted to decompile the latest APK, downloaded from the TowelRoot website, in order to investigate the app's need for the INTERNET permission.

Relevant notes

Upon successful decompilation, it turned out that neither the activities nor the code itself be obfuscated. The developer certainly had anticipated that this app would've been investigated, yet he had left the code to be as much transparent as possible.
The most important file we have at this point is TowelRoot.smali, which describes all the workings of this app.

Note: depending on your particular version of ApkTool, the line numbers may vary.

Initial structure

In lines 13-22, the code initializes a field called fingerprint. The relevant code follows:

.field fingerprint:Ljava/util/List;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Ljava/util/List",
            "<",
            "Lorg/apache/http/NameValuePair;",
            ">;"
        }
    .end annotation
.end field

which is a Java list composed of key-value pairs, to be used when collecting the relevant info from the phone.

Data collected

In lines 56-215, the code describes a method called fillInFingerprint, which is responsible for retrieving the appropriate data to be sent to the TowelRoot website, in order to ascertain whether the device can be rooted via the homonymous exploit. This method makes an extensive use of the abovementioned fingerprint field. The collected data follows.

Device model

The visible device model. Lines 70-80:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "model"

sget-object v7, Landroid/os/Build;->MODEL:Ljava/lang/String;

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

Device fingerprint

An unique identifier for the OS build. Lines 83-93:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "fingerprint"

sget-object v7, Landroid/os/Build;->FINGERPRINT:Ljava/lang/String;

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

Device hardware

Likely the processor board. Lines 96-106:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "hardware"

sget-object v7, Landroid/os/Build;->HARDWARE:Ljava/lang/String;

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

Device serial

Device's unique serial number. Lines 109-119:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "serial"

sget-object v7, Landroid/os/Build;->SERIAL:Ljava/lang/String;

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

Device kernel version

Vital since the exploit is likely to have been patched in the recent kernels. Lines 122-134:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "kernel"

invoke-virtual {p0}, Lcom/geohot/towelroot/TowelRoot;->javaSucksAssReadTheKernelVersion()Ljava/lang/String;

move-result-object v7

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

TowelRoot version

Lines 168-180:

iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "appversion"

invoke-direct {p0}, Lcom/geohot/towelroot/TowelRoot;->getSoftwareVersion()Ljava/lang/String;

move-result-object v7

invoke-direct {v5, v6, v7}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

Modstring

The string modstring. Lines 202-211:

.local v1, "modstring":Ljava/lang/String;
iget-object v4, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

new-instance v5, Lorg/apache/http/message/BasicNameValuePair;

const-string v6, "modstring"

invoke-direct {v5, v6, v1}, Lorg/apache/http/message/BasicNameValuePair;-><init>(Ljava/lang/String;Ljava/lang/String;)V

invoke-interface {v4, v5}, Ljava/util/List;->add(Ljava/lang/Object;)Z

The server request

In lines 227-329 the code describes the method queryServer, which queries the server's database in order to find a match with the collected data, and handles the possible exceptions in the code. Such data is transmitted to the URL https://towelroot.appspot.com/report/ via SSL and a POST request (lines 263-275):

.local v2, "httppost":Lorg/apache/http/client/methods/HttpPost;
new-instance v5, Lorg/apache/http/client/entity/UrlEncodedFormEntity;

iget-object v6, p0, Lcom/geohot/towelroot/TowelRoot;->fingerprint:Ljava/util/List;

invoke-direct {v5, v6}, Lorg/apache/http/client/entity/UrlEncodedFormEntity;-><init>(Ljava/util/List;)V

invoke-virtual {v2, v5}, Lorg/apache/http/client/methods/HttpPost;->setEntity(Lorg/apache/http/HttpEntity;)V

.line 88
invoke-interface {v1, v2}, Lorg/apache/http/client/HttpClient;->execute(Lorg/apache/http/client/methods/HttpUriRequest;)Lorg/apache/http/HttpResponse;

move-result-object v3

make it ra1n

The method buttonClicked (lines 333-426) contains the code that makes the app work when you push the button. Amongst others, it calls the methods fillInFingerprint to gather the required info, and queryServer to see if the device can be rooted.

It then proceeds by analyzing the server's response. If said response is empty, TowelRoot prompts you about the necessity of an Internet connection (lines 369-378):

invoke-virtual {v0, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v2

if-eqz v2, :cond_1

.line 115
const-string v2, "Please ensure you are connected to the internet"

invoke-virtual {v1, v2}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

If the response is not empty, then TowelRoot proceeds by checking if the abovementioned equals the string nyet (lines 391-402):

const-string v2, "nyet"

invoke-virtual {v0, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

move-result v2

if-eqz v2, :cond_2

.line 117
const-string v2, "This phone isn\'t currently supported"

invoke-virtual {v1, v2}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

If the response equals nyet, then the phone isn't officially supported.

Finally, if the response is both non-empty and different from nyet, TowelRoot starts the rooting procedure by calling the native method rootTheShit, defined at line 448 and probably contained inside the library libexploit.so.

For the brave ones

TowelRoot includes a special mode for users with unsupported devices. This mode, whose code is defined inside the method titleClicked (lines 451-504), is accessible by tapping the red welcome to towelroot v3 title inside the app, and will allow the user to try different modstrings in order to try to root the device anyway.


In practice, the only way to debug early boot loops is to read the kernel log as follows:
Minimum steps to get log if you have a working adb and TWRP:

When the device is boot looping, press and hold VOLUME UP + HOME until the boot loop repeats and you get blue "RECOVERY" text in top left corner (specific key sequence will differ depending on actual harware but above should correct for Samsung devices). The important part is that you have to enter the TWRP recovery directly after failed boot and exact steps to do this depend on the hardware. The above example should be correct for all Samsung devices with hardware home button.

Attach the phone to computer with an USB cable and wait for TWRP to finish booting (the order to attach the phone and TWRP booting is not important).

Extract the kernel log from failed boot. Run following on the host computer command line:

The required command for linux host:
adb shell cat /proc/last_kmsg > ~/Desktop/boot-loop-kernel-log.txt

The required command for Windows host:
adb shell cat /proc/last_kmsg > %UserProfile%/Desktop/boot-loop-kernel-log.txt

You'll end up with a file called boot-loop-kernel-log.txt on your desktop which contains the kernel log of failed boot.
This works because /proc/last_kmsg contains the memory contents of previous boot kernel log ring (this works because kernel keeps this log in known memory address and next boot saves the contents of that memory area before writing the new log in the same location). Some vendors put the previous boot kernel log ring to file /sys/fs/pstore/console-ramoops or cat /sys/fs/pstore/console-ramoops-0 so you may need to do
adb shell cat '/sys/fs/pstore/console-ramoops*' > ~/Desktop/boot-loop-kernel-log.txt

instead, but the idea is still the same. Obviously, if the hardware overwrites all memory with zeros on boot, this cannot work.
In my specific boot looping case the problem was caused by "Live Display" color correction failing during boot process if its settings had been changed from the default. With that specific problem, the workaround was to boot to recovery and execute following as root
rm /data/vendor/display/.displaymodedefault

Long version of instructions to acquire boot log during a boot loop: https://forum.xda-developers.com/showthread.php?t=1520508


Nexus 7 wont boot after complete discharge

Try pressing the power button for > 30 seconds.
If it does not work, try to alternate power sources (PC/laptop USB port, and AC adapter) while repeating step #1.
Still no go? You may have to remove back cover and reconnect battery.
Warranty case.

(source)


Can't install Lineage OS due to outdated bootloader on Moto G 2013 XT1034 falcon

Use this tool to upgrade your bootloader to a compatible version.

You should also update your TWRP to the latest version, as older versions aren't compatible with the new bootloader either, and will display a moving line across the screen if you insist.

After these steps you are clear to proceed to flashing LOS 14.1.


Can deleted phone contacts visible in WhatsApp able to post chat messages?

Whatsapp has no relation with deleting a contact from your phone. WhatsApp uses your phone book contacts only to find who are on whatsapp, and then it shows their names in its contact tab. That's it. There is no more relation.

This means the person is still able to send you messages. His name may not be shown in the chat, but his number will be shown. This is similar to the fact that, we do receive messages in whatsapp from people who are not in our contacts, and also similar to receiving phone calls or SMS from persons whom we don't know. In whatsapp, only their number is shown in the chat screen, along with profile information, if any.

Only way to stop getting messages is to block the person. Blocking does not show on the phone of the contact you've blocked. Once blocked, the person will see that the messages he is sending, are being sent from his phone, but are not being delivered to your phone, that is, there will be no double tick, only a single tick. You'll not receive any message any calls through whatsapp from him.


How do I create fast backup of camera photos to cloud storage

You can try this app. It can instantly upload taken photos to Google Drive or Dropbox. There is option in settings to upload using cellular data.


SuperSu not at all functional, can't uninstall

Steps:

First, you need to install the SuperSu Zip file from recovery; then,
Install the latest version of SuperSu app from Play Store.

Also, based on my experiences on Cyanogenmod ROMs, these ROMs are rooted before installing. So, you don't need to install any SuperSu file from recovery.


I have htc desire s and it can not access sd card which worked in it for a long time

It might be due to a problem with the seating of the SD card in the slot. If you're sure it's firmly seated in the slot and the problem still exists, then your slot may be broken, per se.

Send it in for repair.


Importing the Telegram contacts into the phone book - Android

After exporting all the contacts with Export Telegram data, I created a Python script that extracted all the contacts from the generated website.
The script, positioned directly inside the Telegram Desktop folder, is the following:

#FIRST FOLDER TO CHANGE
pathToFile = 'DataExport_08_12_2018 (2)/lists/contacts.html'

with open(pathToFile, encoding='utf-8') as f:
    lines = tuple(l for l in f.readlines())
    with open('csvToConvert.csv', "w", encoding="utf-8") as outputFile:
        outputFile.write('nome, telefono\n')
        for i,l in enumerate(lines):
            if l.startswith('
') and lines[i+4].startswith('
'):
                tel = lines[i+5].replace(' ','')
                if not tel.startswith('+39'):
                    if "+" in tel and tel[1] == '3':
                        outputFile.write(lines[i+1].replace('\n','') + ', ' + tel.replace('+', '+39'))
                    else:
                        if tel[0] == '0':
                            outputFile.write(lines[i+1].replace('\n','') + ', ' + tel)
                elif tel.startswith('0039'):
                    outputFile.write(lines[i+1].replace('\n','') + ', ' + tel)
                else:
                    outputFile.write(lines[i+1].replace('\n','') + ', ' + tel)

Note that this script is aimed to the Italian telephone numbers (note the prefixes that are checked in some if clauses)!
However, once the folder is modified and the script is executed, a file called csvToConvert.csv is generated.
Subsequently, this file must be passed to a program called CVS to VCard, which takes care of converting the csv file into a vcard file.
Then, once the vcard file is generated, just enter it on google contacts (https://contacts.google.com/ > more > import), and you're done! Magically you will find all the contacts in the phone book of your android phone!
I hope I have been helpful.


can only access SD card; cant access the internal storage on pc

Try going to the settings and then storage and then files to explore if there are any pictures that you can delete.


Is there a way for a blind user to find the TalkBack tutorial?

In theory when a blind user first starts up the phone they have the option to start talk back.  When it is turned on at start up, the tutorial automatically starts.

This option is available for devices running Android 4.0 and above.
When you first turn on your Android device, you can enable TalkBack from the initial setup screen.
Source

In reality sighted assistance should be considered a requirement for initial start up.
Assuming a blind user, who is key board dependent, with no previous mouse or touch screen experience. I suggest this process.

Sighted assistant completes initial set up, with feedback from blind user on desired options.

Both 'talk back' and 'explore by touch' should be activated. (sighted assistant completes tutorial)

Sighted assistant should become familiar with gestures.  Combining 'talk back' and 'explore by touch' create gesture combinations that are unique and different from neither or only 'talk back' being active.

Many of the gestures on a touch screen are easily grasped by users with mouse experience.  To users with primarily keyboard experience they will be unfamiliar.  Before starting the tutorial, give the blind user time to practice on the home screen, and get used to it.

Once the blind user has a basic grasp of moving around on the touch screen the tutorial can be accessed in the Accessibility menu.

With some experience the blind user will be able to re-access the tutorial without assistance. I think there is a only a small window of time when a blind user can access the the tutorial without assistance and will still get value from it.  For the most part consider sighted assistance for initial training a requirement.


How to update samsung galaxy tab p1000 i.e. 2.2 to 2.3. using ADB?

These are the steps to install/update a custom ROM from stock:

Install a custom recovery (Clockworkmod for example).
Copy the ROM zip to the phone sdcard (you can do this via adb).
Reboot in recovery (it will load the custom recovery).
Use the option to install zip from sdcard to install/update the ROM.


Phone still stuck in a bootloop after flashing official firmware with Odin!

Hoping that you have not wiped your data while flashing firmware using Odin, the process of data retrieval can be variably difficult. The best way I can think of is to flash a custom recovery on your device then mount desired partitions.
PS I have no information whether your phone is rooted or not, so just providing the most workable way.


Whatsapp message not delivered before deleting account

Yes, it'll be delivered, because it's on the server. You cannot control it.


android.hardware.usb.host.xml file - located under /vendor/etc/permissions/ or /system/etc/permissions/ before Treble - contains feature name="android.hardware.usb.host" which indicates that the device can communicate with USB devices as the USB host. This feature is evaluated by PackageManager (along with other software / hardware features) and used by Google Play to filter (in)compatible apps based on the value <uses-feature android:name="android.hardware.usb.host" /> in AndroidManifest.xml. See details here.

Also if the device doesn't support USB host mode, UsbHostManager service is not started, so apps like this which use USB host APIs cannot connect to USB devices. But any connected device is still detected by kernel and appears under /sys and /dev.

To confirm if the device supports USB host mode:

~$ pm list features | grep usb.host
feature:android.hardware.usb.host

~$ dumpsys usb | grep host_manager
  host_manager={

These lines shouldn't appear after you delete android.hardware.usb.host.xml file.

However since Android 6 USB storage devices such as a USB stick are handled by vold, which doesn't depend on the feature discussed above. vold listens to kernel through a netlink socket for block device uevent (1) and matches that with some entry in fstab (2). Then it creates disk and partition nodes in /dev/block/vold/ (3), checks filesystem for errors and mounts in /mnt/media_rw/ (also emulates SD cards in /mnt/runtime/) (4). After that ExternalStorageProvider (a content provider) is triggered which grants apps URI access to OTG storage through SAF or  Scoped Directory Access.

So in order to disable auto-mounting of USB storage devices by vold, you need to remove the corresponding entry from fstab as referenced here:

/devices/*/xhci-hcd.0.auto/usb*    auto    auto    defaults    voldmanaged=usb:auto

fstab is found under /odm/etc/ or /vendor/etc/. Before Treble it was in rootfs (/). See details in this answer.


It happens only when we share location without letting GPS find our exact location, generally before sending location you are supposed to wait until the location is clearly visible to you and its exactly where you're sitting.

You can share your location or where places are located with any of your conversations.
To do so-
On your Android device, open a new or existing Hangout.
Tap Location Insert location.
Type in a location or address: In the top right corner of the map, tap Search .
Find your current location: In the bottom right corner of the map, tap Location Insert location.
Tap Select this location. The location will send immediately.


Yes.  According to this XDA thread, you can unlock the bootloader with fastboot and then flash only a custom recovery.  The custom recovery will allow you to put su on your device.

You could also flash a stock 2.3.3 ROM that has been altered slightly (i.e., pre-rooted).  For example, this one over at XDA.


I believe this issue is caused by using the same chrome login for both desktop and Android and adding a bookmark on desktop. That folder is used for subsequent bookmarks but for some reason, the Android app doesn't know where that is. It could be that it saves a booking folder that was deleted. Anyway, here's what I did to fix this issue on Android:

1) Load an existing bookmark.

2) Press the bookmark star.

3) Change the bookmark's folder to another folder that exists.

4) Change the bookmark back to the original folder.

5) Navigate to the site you were trying to bookmark.

6) Bookmark it. The previously-used folder should now be set correctly.


HTC Desire Phone Storage != Physical size

That is because your phone has several partitions, and some of those are not user-accessible, but they are required by the OS for the proper functioning of the device. This storage is "partitioned" from your physical storage. These partitions are as follows:

1) bootloader or variants thereof: About a few MB. Responsible for booting up your device. You can't normally mess with it, even with root on-device, but even if you can, you shouldn't.

2) /boot: Contains the OS core, the Linux kernel. About 10-25 MB, varies with device.

3) /recovery: The name is pretty self-explanatory. About 10-25 MB. Responsible for doing OTA updates, factory resets and saving your device when it gets into a bootloop. Most rooted users usually flash a custom recovery like CWM or TWRP before going forward with customization.

4) /system: About 1-1.5GB, varies with device. Stores system data and apps. Read-only to normal users, write-capable for root. Most root users mess with this partition on a regular basis.

5) /data: About 1GB- depending on device. On devices with unified storage, this partition holds the internal SD card too as an emulated device. It is not even read-only to normal users, but it can be written to and read with root. It holds user-installed apps, their data, and user-specific data.

6) /cache: App and data cache. From 16-256 MB. A kind of temporary storage provided to apps.

Note: A factory data reset wipes /data and /cache only.

7) radio or variants thereof: A few MB. Again, responsible for handling telephony. Don't mess with this.

8) /storage/sdcard0: On non-unified storage devices, this is the user-available storage as a separate partition. On unified storage devices, this is still there, but is a folder under /data actually, with write permissions for normal users, unlike the rest of /data.

For any more info, a Google search will help. Or you can check this out.

Also, the partition names are the ones I got from fastboot while flashing my HTC Nexus 9 (16GB,WiFi, flounder/volantis) when upgrading Android via factory images.


Why do apps like WhatsApp, Facebook run background services in android even though their apps on iOS without backgroung services

Because they can.

In Android you can create background services and do a lot with them, whereas in iOS Apple does not allow you to do this. Both use push notifications to get your new messages when the app is closed, so the main functionality of the app works fine regardless, however the apps may be doing more processing or monitoring, or whatever Facebook wants it to do in the background while you're not using it.


Your chances for #2 are pretty good – though there might be some caveats. To figure which those are, let's take a look of what a factory-reset does. It...

wipes /data
wipes /cache
wipes the dalvik cache (usually implicitly, as in most cases this resides in /data; I guess with Lollipop it will do the same for ART).

So you see, /system remains untouched. With your app installed in /system/app, it will survice a factory-reset. But its data might not, as /data gets wiped. Which means, all required settings need to be part of the app itself, or of its "default settings" which get deployed on first initalization.

For the second part: That's better asked at a development site (which we are not). Basically, no app gets root access by default AFAIK. They get access to everything their permissions allows (and yes, there are permissions which can be granted to system apps which are not available to "user-space apps") – but for root access, you've got to ask su, which should trigger the corresponding superuser app.

PS: As for the SuperSU popup, you will have to live with that for the first call, I'm afraid.


To manage the system and not give it root access, you neex to use a custom recovery.

A custom recovery will allow you to backup your DATA & SYSTEM Partitions so thst you can restore everything easily and safely.

The most common custom recovery in my opinion is TWRP or Team Win Recovery Project, this would be the newest most common in succession from Clock Work Mod as the most common.

I searched for TWRP for your device, and i got this installation guide... .
Zenfone 3 & 3 Delux TWRP

Once you've successfully flashed TWRP you can do the device clone that you want by going to Backup and performing a full device backup to the External SD Card.

Now install TWRP on Device 2.

Place your SD Card from Device 1 with the new backup into Device 2

Boot into TWRP on Device 2

Go to Restore and select External SD

Select your backup

Restore the backup.

The second device will be entirely replaced with the data from the first device excluding some stuff like IMEI number etc, depending on your TWRP Version....

Locked Bootloader ?

Asus provides an Official unlock tool for your specific device at the Asus website...

Here's a direct link...

  Asus Unlock Tool

Reference ;
www.asus.com/Phone/ZenFone-3....


Samsung Note 4 - Network Locked - But which carrier?

Try to use this page: IMEI INFO

It may tell you the carrier who locked your phone. Good luck!


Android video and audio playback speed is nearly double

Go back to the same video through the same app and hold it again the way you were- perhaps the dialogue will pop up again and you can catch it this time. I imagine you simply long-pressed for an options menu to come up. Just be ready to let go (or not) when you see it. Should fix your prob.


Yes, I Tries SuperOneClick and it worked for my lg l35g AKA lg optimus logic (net 10).


I could have sworn immersive mode was a feature of Termux... You can still use immersive mode via ADB (or root, if you have that).

Hide both status and navigation bar: adb shell settings put global policy_control immersive.full=com.termux

Hide status bar only: adb shell settings put global policy_control immersive.status=com.termux

Hide navigation bar only: adb shell settings put global policy_control immersive.navigation=com.termux

Turn off immersive mode: adb shell settings put global policy_control immersive.off=com.termux


Turn off automatic loading of MMS messages

Nicolas, possible solutions very much depend on how far you will go (and partly, how far your carrier goes along). There is no 100% cure, but a few items you might consider:

Say Goodbye to Hangouts. If you can live without that app, make another one the default SMS/MMS handler and don't use Hangouts – at least not until Google fixed that "autoplay". I'd expect an update there soon where you can at least disable that autoplay feature.
Disable your MMS APN. This of course you can do only if you can live without MMS altogether (I can: didn't get a single MMS in the 20 years I'm using mobiles – and the only one sent to me never reached my device because of carrier policies: to receive, I had first to send an MMS, which I never did). And apart from that, this might or might not work: I know of providers ignoring APNs, at least for the normal Internet connection (which then works even if you have no APN at all configured – they somehow fix that at their end).
Ask your carrier if MMS can at least temporarily "switched off" somehow from their end. They should have those capability: If you e.g. send an MMS to someone having a non-MMS-capable dumbphone, they'd send that person a link to where to read the MMS with a browser. You then could use a web browser at your PC to read the MMS – where Android-specific exploits had a hard time dealing with OSX, Windows, or Linux :)

Afraid only few of us can hope for OS updates to really fix that. Though, when under warranty, one might try pressing them: depending on how one uses the device, this bug might very much "render it unuseable" for daily use without the user's fault – which in my eyes is a case for warranty: fix it or have it back. Enough people with this argument, and some with good lawyers … might make them think twice ;)


I found another method (buried lightyears deep on the net):

http://squidstech.com/2016/11/27/root-z3-23-5-a-1-291-d6603-d6633-d6653/

It flashes the recovery via ADB
(requires a prior kernel change, though, that can be restored after)


Dual Booting a Windows 8 Tablet/Smartphone with Android OS?

You could, but without support it would be difficult.

Android does not 100% support for all apps on intel/amd processors

As well as this, you would have to write a kernal / kernel object to support the specific hardware of the device.

This can be quite difficult if propriety information is unavailable.

You would be better to ask at http://forum.xda-developers.com and ask if someone has ported Android to your device, or a device you would be wanting to buy.


How do I override charging current on Huawei Honor 6?

The path in this answer didn't work, guess it is not the true path.

Here is my own post at XDA forum showing a script running using a macro. The path according to what worked for me and steps involved are explained. It shows a macro based implementation allows the path which works for me.

I am thankful for the earlier post that pointed this file.

To summarize:

Path posted earlier lead me to the file but did not allow me to change values. Probably because this is a sysfs file and the path turned out to be
/sys/devices/amba.0/fdf0a000.i2c/i2c-0/0-006b.
For some reason I could not echo 0 to the file to change it. Only option I could think of was to copy the file when it's not charging into a separate
folder in SD card and paste this into the system at the desired charging level to fool the system into behaving as if it was charged.
To do this, I mounted sys as rw first making SELINUX permissive and copied the file into SD card. Next was writing a script  to copy this into system.

su –c "cp /storage/emulated/legacy/for_testing/enable_charger /sys/devices/amba.0/fdf0a000.i2c/i2c-0/0-006b"

To run the script at appropriate charge automatically I used a macro written using MacroDroid app (far more  easy to learn compared to Tasker)

This whole exercise ran smoothly.

I would be happy if someone can:

suggest a better way
help with file information pertaining to note 2 , my old device and if at all possible to do


Comprehensive list of Android apps that detect and don't work with rooted phones

The most comprehensive list I've seen its available on the RootCloak website, towards the bottom...

http://repo.xposed.info/module/com.devadvance.rootcloak


Is it possible to keep phone plugged in a powerbank when the battery is worn out?

My experience is that the answer is yes.
For some devices, I have completely removed the battery and have them running just from the charger.
Of course, if there is a power outage, the device will immediately turn off without saving anything.  So be aware of that possibility.


Using your smartphone as Laptop and Desktop with a DisplayLink-Setup (with S7 for example)

Not having MHL is not problematic.

Most recent Android phone will be able to act as host and therefore talk with a docking station with DisplayLink technology inside.
You simply need the app and an OTG cable. You are correct that the USB standard, until Type-C, only allows a device to be charged, not the host. However, some phones do charge whilst being host. They are not compliant, but in this case it may help you! It means you can find non-compliant cables to do that, which may not work with your phone model.
Android stock only allows you to have 1 external display in mirror/clone. The mouse is handled on one display properly. Android stock does not allow you to have an extended desktop because the launchers need to be modified to ask where to launch the app, and the mouse pointer also needs to be handled. DisplayLink, my current employer, has shown it is possible by modifying the launcher/OS. It just needs a manufacturer to embed that in their image...

Here are my recommendations on this. If you use it at a desk and not mobile, I would use a USB travel adapter plugged in to a standard monitor. This will allow you to plug to any conference room/hotel TV to display videos, presentations, show photos to family on their TV... directly from your phone.

If you wish to have a mobile office, the mobile monitors are very nice. They are also quite interesting for trade shows as light and not requiring a power adapter. Still, driving the display and the back-light needs juice! Your mobile phone may not be able to provide all that juice directly (and even if it does, you may not want it to :) ). Some of these monitors come with a USB Y-cable. You would plug one to the OTG, the other cable to power bank.

Personally, I use a USB-C to Type-A adapter and a miniRay projector from my Oneplus 3 phone.

I hope this helps you see a bit more clearly what's possible!

Thanks,
Alban


A few to much questions for a single post, though they are mostly related. Let's roll up from the end:

Deep Sleep is a state where the CPU has "nothing to do at all". Depending on the tasks the device has to perform, CPU runs in different "speeds" (frequencies). Say you've got a 1 GHz CPU, that doesn't mean it permanently runs at 1 GHz (and eats your battery); it will only "fully power up to that" if there is demand for it. On average, it will run on much lower frequencies, down to ~50 MHz. If there's really nothing to do, the system will "send it to sleep", and set a timer to wake it up later. This state is called "deep sleep".

Your device goes to Standby only when you've turned the display off, never when the display is turned on. IMHO "Standby" and "Sleep mode" are synonyms. But switching off your display is not the only criterium for entering Standby. Depending on your device's settings and apps currently started/running, e.g. running downloads might continue, as well as other "ongoing calculations". The "locked state" usually has nothing to do with it: that's rather a "security measure" against "unwanted access".

What services are stopped when you switch off the screen is something no generic answer can be given to: this very much differs not only between devices and Android versions, but also depends on what apps you have installed and how they're programmed/configured.

As for your specific example: This again depends. Say you've switched off mobile data, and run your download on WiFi. Your "WiFi Standby Policy" is set to cut the connection when the screen is turned off. Results for your download should be obvious then :)

Note that this answer most likely is incomplete, as the topic is rather complex – and your number of questions don't make it easy to answer in a short manner.


Auto-hide notification bar while apps are open

The feature is called "immersive mode" and was first introduced in Android 4.4 KitKat.

For official method, there is no way to use this in all apps, and only the developers of the app may decide to implement it or not.

However, there are some 3rd-party apps that can force immersive mode in all apps:

GMD Full Screen Immersive Mode (free, Pro version with IAP). Follow the instruction on WonderHowTo to install and customize the app.
Immersive Full-Screen Mode (paid app).
(For the sake of completeness), Xposed Framework with "Immerse Me" module (require ROOT). Follow the instruction on phoneArena.com for step-by-step installation.

Note that by using these apps, your keyboard may not work properly.

From BGR,

  Due to some security features in Android, users will not have access to the keyboard in many apps while in immersive mode.

From WonderHowTo

  Beware that your keyboard may not work in Immersive Mode, which is why having the toggle in the notification shade is so handy.


Try Formatting your phone I am sure there's one there in the recovery


Is there a way to change the cover photo in Gmail app's menu?

Today, as a matter of fact, the image suddenly appeared. I did not do anything special that I hadn't tried before: Switching on and off the phone, reconnecting gmail, disabling and enabling the respective settings.

So it's obviously just a matter of time until all the picture changes take effect in the app.


Edit: Based on OP's clarification in comments and subsequent search - Call Barring refers to both incoming and outgoing calls being blocked whereas Call blocking/Number blocking refers to only incoming calls being blocked.
To answer OP's question

Call barring is not a standard Android OS feature.

Call barring seems to be Samsung OEM specific. See call barring - Samsung community. It also includes roaming calls

Thanks to Andrew's inputs in comments

call barring is usually available on most phones (e.g. OPPO R11
, Huawei P10
, and even on older feature phones), but the service is linked directly to the SIM provider. That's why it also asks for the code before changing the settings.

Section below is retained for reference, just in case this confusion arises again

Number blocking was introduced in Android 7 and it is not depreciated AFAIK. I have been using close to stock devices(Moto, Android One) and found this feature, usually in the SMS & phone apps. I am currently on Android 10 with Oxygen OS which is considered close to stock and this feature is present
Extracts below

The default SMS app, the default phone app, and carrier apps can read from and write to the blocked-number list. The list is not accessible to other apps....
Additionally, carrier app integration through Android means that carriers can read the blocked numbers list on the device and perform service-side blocking for the user in order to stop unwanted calls and texts from reaching the user through any medium, such as a VOIP endpoint or forwarding phones

The article you linked pre-dates Android 7 and mentions specifically that it is not a standard Android feature and goes on to give examples of OEM implementation. See Implementing Block Phone Numbers which says

Before N, Android users had to rely on downloaded apps to restrict calls and texts from bothersome phone numbers. Many of those apps either do not work as desired or provide a less-than ideal experience because there are no proper APIs for blocking calls and messages.


Yes, you should buy a Nexus One or a Nexus S. If you buy another phone like e.g. HTC Wildfire, you can't easily get the "vanilla" Android.


Restoring phone to factory settings is the easiest way. Tough way is to search on net for a valid vold.fstab file, which can be generally found in custom built ROMs.


Android 4.1 unable to connect to Google Play but other wifi functions work - how to fix?

Turns out that the solution for this problem is the one I alluded to above.

The system date/time preceded the certificate's issue date, and I suspect that was causing the problem.

Setting the date to the correct date (or sometime between the certificate's issue and expiration date) seems to have solved the problem.


How to get permission for overwrite files in /system/fonts directory in Android phone

You'll have to root your phone first, and probably set it S-OFF to be able to write to the /system directory while booted.

See this question for information on what rooting is.  S-OFF is the next step that gives you full control all of the time.  Neither are something you should do without understanding the risks.


CM9 skips to the next song, even on short presses

The only recommendation I can give is to upgrade your firmware. You could try a newer version of CM9, as then you don't have to wipe data. If you want a fairly stable newer version, 4.1 works really well, and 4.3 somewhat. Go to quarx2k.ru and select the 2nd-boot folder for them.


Is there no option to turn off cell broadcasting messages in HTC Desire 500?

I am not sure whether this works as I believe broadcast settings are not stored in SIM. I searched and stumbled on this HTC support page where the solution is said as:

  I resolve problem. It is very simple. Just put your sim card in old or
  some other phone and turn off cell broadcast info option. Then return
  your sim in new phone. On my HTC Desire 500 there is no option for
  cell broadcast. After this procedure I do not recives messages.

Then, another search result says with better detail (you may have to search for Cell Broadcast. Though this not deals with your phone (with HTC Desire T327W), I guess this seems to be a common issue with few HTC phones. As per that page:

  26-Sep-2013 - My earlier review talks about Cell Broadcast messages
  problem faced by me while using HTC Desire XDS. After a lot of
  followup with HTC, I have got the steps using which the Cell Broadcast
  messages have got disabled in my Desire XDS. The steps taken by me
  were as follows for each of the two SIM cards:
  a) Find an old phone which has an option to enable/disable Broadcast Channels and Messages
  (in my case its a Samsung D500).

  b) Insert the first SIM in that old
  phone and go to the settings menu for Broadcast messages.

  c) At first
  the Channels and Messages usually appear as disabled. I changed the
  setting for both Channels and Messages to Enabled in the old phone.

  d) Switch-off the old phone and Switch-on

  e) Go to the settings menu
  for Broadcast messages. Change the settings for both Channels and
  Messages to Disabled.

  f) Switch-off the old phone and Switch-on

  g) Switch-off the old phone and remove SIM card

  h) Do the same steps (a-g) for the second SIM

  i) Insert the SIM cards back in HTC Desire
  XDS

  Now I do not get any Broadcast Messages, its such a relief. I hope HTC
  provides a better and elegant solution via a software update in the
  upgrade to Android 4.3.


In my experience, resetting Samsung devices does make them faster, so resetting an Acer device will also likely make it faster.

If you don't have any important data stored, then its definitely worth trying to factory reset your tablet to see if it gets faster.


I've come close but I still can't launch an action at the same time when two keys are pressed in combination like the way we do for taking a screenshot. Anyhow, you would need:

AutoInput (for Android 4.3 and above) with Tasker, both are/have paid/7-day full trial, or
Xposed Additions (needs root access) with Tasker  to make key combination(s).

The inconvenience in this solution is that unlike pressing both keys at the same time you would have to do it in sequence. That is, press/hold Vol Up followed by Power button. The timing between these key-presses is flexible.

Single key-press

Use AutoInput with Tasker if you want to launch your action with single  key presses combination i.e. only press a key one time but don't want to long-press the keys.

In Tasker create an Event based profile from Plugin →  AutoInput →  Key → Configuration:

Keys: Volume Up
Key Action: Key Down

Create a task in it named "AutoInput Volume Up" and create following actions in it:

Variable → Variable Set:

Name: %Kset
To: 1

Task → Wait → Seconds: 1
Variable → Variable Set:

Name: %Kset
To: 0

Explanation: When the single Vol Up press is detected the custom variable %Kset would be initialized to a custom value 1 and then we would wait for one second (under this one second you would've to press the Power key). We're then initializing the variable to 0 because our solution demands it, otherwise, our main task of capturing a photo would be executed just by  a single press of Power key.
Repeat step 1 but select Power key instead of Volume Up key.
Create a task in it named "AutoInput Power" and create following actions in it:

Task → If → Condition: %Kset eq 1
Plugin → AutoInput  → Modes:

Configuration:

Key Suppress: Enable
Keys: Power

Timeout: None

Optional action -- Alert → Flash → Text: Commencing launch
Media → Take Photo → customize it as per your needs.
Repeat sub-step 2 of step 4 but do Key Suppress: Disable.
Optional action -- Task → Else.
Optional action -- Alert → Flash → Text: Psst: You're too late Jim!

Explanation:

In our first action we are checking whether the variable %Kset is set to 1 and if yes then the second action would block Power button press from getting passed to system since normally Power key-press would put the device to sleep and lock the screen.
Optionally flash a custom toast signalling that combination was successful.
Let the Tasker capture the image using the settings provided in that action.
Disable Power key suppress since otherwise, you would never be able to use that button normally, as long as key suppress is not explicitly disabled  or AutoInput's accessibility is running.
Else statement is optional but could come handy since in the beginning your consecutive key-presses may not be in coordination so the custom toast in next action would hint you that the combination wasn't successful.

That's it. Go to Home screen or to any non-Tasker app, press the Vol Up key and then the Power key under a time period of one second (don't worry, you would get a hang of it, or else, change the wait period) and you would see Tasker opening its custom interface, a picture would be captured automatically and you would be taken back to what you're originally doing.

Hurray!

Long key-press

Some people may not like single pressing both the keys since they are not habitual or may feel odd to use them in that coordination. In that case, provided that you've root access and Xposed Framework installed, you can use Xposed Additions to set long key-press actions for your keys.

For custom action to be set to those keys we would need Tasker. Create the two tasks named "AutoInput Volume Up" and "AutoInput Power" explicitly in Tasker, only if you didn't follow Single key-press section.

In that app go to Button → set Long press delay time → Add new key → tap Vol Up key → select the new key entry.
Tap Add new Condition  → Screen On → → select the new entry → check Long Press and tap on that entry  → scroll down to Shortcut → Task Shortcut → AutoInput Volume Up.
Repeat step 1 but do it for Power key.
Repeat step 2 but select AutoInput Power under Task Shortcut.

Whenever Xposed Additions is enabled and activated in Xposed Framework, on any long-press of a button/key set under that app, you would feel a slight vibration. That vibration would help immensely to know when to release the first key and long-press the other key.

Try it because it's fun.


How to properly ENABLE dm-verity and FEC for /system on Motorola X4 with LineageOS 17.1?

Warning! Use at your own risk!
The sense and especially added security of all of this may be disputed. Find some notes about security in the end.
tl;dr:
It took me some days to find a solution to get this:
[    2.251328] init: init first stage started!
[    2.251561] init: Switching root to '/first_stage_ramdisk'
[    2.252614] init: Using Android DT directory /proc/device-tree/firmware/android/
[    2.603025] init: [libfs_mgr]Enabling dm-verity for system (mode 0)
[    2.603181] init: [libfs_mgr]Verity table: updated block device from '/dev/block/platform/soc/c0c4000.sdhci/by-name/system' to '/dev/block/platform/soc/c0c4000.sdhci/by-name/system_b'
[    2.603195] init: [libfs_mgr]Verity table: updated block device from '/dev/block/platform/soc/c0c4000.sdhci/by-name/system' to '/dev/block/platform/soc/c0c4000.sdhci/by-name/system_b'
[    2.753873] device-mapper: verity-fec: 259:33: FEC 0: corrected 22 errors
[    2.830804] device-mapper: verity-fec: 259:33: FEC 4096: corrected 7 errors
[    2.831080] init: [libfs_mgr]superblock s_max_mnt_count:65535,/dev/block/dm-0
[    2.854916] device-mapper: verity-fec: 259:33: FEC 0: corrected 22 errors
[    2.878336] device-mapper: verity-fec: 259:33: FEC 4096: corrected 7 errors
[    3.001281] device-mapper: verity-fec: 259:33: FEC 1052672: corrected 18 errors
[    3.001825] EXT4-fs (dm-0): mounted filesystem without journal. Opts: barrier=1
[    3.001947] init: [libfs_mgr]__mount(source=/dev/block/dm-0,target=/system,type=ext4)=0: Success
[    3.002215] init: Switching root to '/system'
[    3.139199] device-mapper: verity-fec: 259:33: FEC 3133440: corrected 12 errors
[    3.272389] init: [libfs_mgr]Enabling dm-verity for vendor (mode 0)
[    3.272662] init: [libfs_mgr]Verity table: updated block device from '/dev/block/platform/soc/c0c4000.sdhci/by-name/oem' to '/dev/block/platform/soc/c0c4000.sdhci/by-name/oem_b'
[    3.272679] init: [libfs_mgr]Verity table: updated block device from '/dev/block/platform/soc/c0c4000.sdhci/by-name/oem' to '/dev/block/platform/soc/c0c4000.sdhci/by-name/oem_b'
[    3.276744] init: [libfs_mgr]superblock s_max_mnt_count:65535,/dev/block/dm-1
[    3.279830] EXT4-fs (dm-1): mounting with "discard" option, but the device does not support discard
[    3.279845] EXT4-fs (dm-1): mounted filesystem without journal. Opts: barrier=1,discard
[    3.279935] init: [libfs_mgr]__mount(source=/dev/block/dm-1,target=/vendor,type=ext4)=0: Success

Build LOS 17.1 with the reverted commit from the initial question

Place verity_key in ramdisk/first_stage_ramdisk folder

Append the following cmdline options, this is the android testing key:
BOARD_KERNEL_CMDLINE += root=/dev/dm-0 dm=\"system none ro,0 1 android-verity Android:\#7e4333f9bba00adfe0ede979e28ed1920492b40f /dev/block/by-name/system_b\" androidboot.slot_suffix=_b rootwait androidboot.force_normal_boot=1

Add system partition to the DTB fstab and include verify option

There are more caveats here than I thought. I will also try to include all words I was searching for in this text.
Key findings regarding booting and dm-verity about the payton

It seems to be a legacy SAR (system-as-root) device (most important read!). The kernel mounts the root/system filesystem itself, no ramdisk or ramdisk partition involved. Typical cmdline arguments for the kernel are root=/dev/block/mmcblk0p6x, where x is 5 or 6 for the system A/B partition and init=/init.
The original motorola files do not contain a fstab in the ramdisk
There is no system partition defined in the DTB in the motorola files
Therefore the bootloader seems to verify the boot image, most likely with some certificates baked into the bootloader? (strings -a on the bootloader hints at this). Then it sets the appropriate start partition and maybe the command line for verity verification, more on this later.
vendor is called oem on motorola.
Like mentioned the payton is missing fastboot flash avb_custom_key, so no new shiny Android Verified Boot (AVB) 2.0 with vbmeta.img. Most likely because it was initially shipped with Android 7.0 and nobody cared updating the structures.

Some things about building LineageOS 17.1

Build LOS like written in their help
LOS seems to also boot legacy SAR, except when you enter recovery mode.
Using the instructions below will give you something like Android Verified Boot 1.0
The build process prepares the following things for dm-verity integration: Creating boot.img, system.img and vendor.img, adds dm-verity metadata to the end of system.img and vendor.img and signs boot.img. vendor is verified in the default LOS configuration by adding it to fstab and additionally creating a DTB fstab entry for it.

The general build process

Codebase is impressively huge: 190 GB without ccache

Revert the mentioned commit in dm-android-verity.c

Use the following Kernel cmdline.

This circumevenes A/B and slotselect mechanism for selecting the proper system_a or system_b. Without bootloader support I do not know if it is possible to ever reenable A/B.

Also this configuration always skips recovery, even if you try to boot to recovery from bootloader.

This did not work with androidboot.veritykeyid, I do not know why (yet).

You have to escape " and # here!

device/motorola/sdm660-common/BoardConfigCommon.mk:
BOARD_KERNEL_CMDLINE += root=/dev/dm-0 rootwait
BOARD_KERNEL_CMDLINE += dm=\"system none ro,0 1 android-verity Android:\#7e4333f9bba00adfe0ede979e28ed1920492b40f
/dev/block/by-name/system_b\"
BOARD_KERNEL_CMDLINE += androidboot.slot_suffix=_b
BOARD_KERNEL_CMDLINE += androidboot.force_normal_boot=1
BOARD_BUILD_SYSTEM_ROOT_IMAGE := false

without force_normal_boot a "normal" boot goes to recovery.

kernel/motorola/msm8998/arch/arm/boot/dts/qcom/sdm630.dtsi:
system {
compatible = "android,system";
dev = "/dev/block/platform/soc/c0c4000.sdhci/by-name/system";
type = "ext4";
mnt_flags = "ro,barrier=1";
fsmgr_flags = "wait,verify,slotselect"; };

Maybe you can also leave out the DTB change (mounting partitions with DTB will be obsolete in Android 11) and use a fstab file (somewhere, maybe in first_stage_ramdisk).

make sure verity is enabled in ./make/target/product/verity.mk

PRODUCT_SUPPORTS_BOOT_SIGNER := true
PRODUCT_SUPPORTS_VERITY := true
PRODUCT_SUPPORTS_VERITY_FEC := true

When changing the verity key, do not forget to add it to the kernel in kernel/motorola/msm8998/certs and check the certificates in the running system in /proc/keys
You can get the last (failed) boot messages in /sys/fs/pstore/console-ramoops
The resulting system behaves like 2SI ramdisk SAR

Main Question: Does this add security to the device?

You can lock the bootloader afterwards with fastboot flashing lock
The boot partition has to be verified manually with the key ids shown while booting (at least I think it is some signatures of the signed boot.img)
Flashing partitions from bootloader does not work
Entering recovery also does not work
fastboot boot file.img gives an error
fastboot flashing unlock clears userdata, this is good!
In case anything goes wrong with the running system, you have to clear your device.
Updating just got a little bit harder without changes to the updater because the A/B partition is hardcoded
Root needs to be enabled for updates (at least ADB root), so this will stay a userdebug build.
Changes to /system can be executed without messing the dm-verity, just sign the changed system.
dm-verity is in eio mode here, I actually did not try to set it to enforcing.

Open questions

Can you change the kernel cmdline from bootloader?
Maybe you can blankflash (fastboot oem blankflash) the device, I do not know what happens in this case.

Have fun!


If your computer is able to recognize the phone while it's in Fastboot mode, you are half-way there.  You will now need to flash a proper Recovery image, and then use the Recovery mode to flash a compatible ROM.

It doesn't looks like ClockworkMod officially supports your version of LG G2 (d803).  The other well known recovery is TWRP (short for Team Win Recovery Project).  There are two different recovery images for d803 - Bell and Rogers.  Go ahead and download the one appropriate for your carrier, and save it somewhere on your computer.

Now do the following:

Boot up your phone into fastboot mode, and connect it via USB to the PC.
Open Windows Command Prompt, and navigate to wherever the fastboot.exe program is installed (e.g. cd c:\fastboot\)
Issue the following command: fastboot flash recovery [path-to-img] where "[path-to-img]" is the full path to where you downloaded the recovery image (C:\temp\openrecovery-twrp-2.6.3.2-g2bell.img for example)

Turn the phone off, diaconnect it from USB, and boot to recovery by holding the Vol Down+Power buttons, then as soon as the "LG" logo comes up release them and press & hold them again, and then on the screen press the Power button 3 times.

You should be in TWRP recovery.  Re-connect the phone to PC via USB, and now ADB tool should be working.

You can now try to find the CM11 version for your phone, adb push it to your phone's memory while it's in Recovery mode, and then flash it with TWRP.  I would also recommend performing a complete wipe via TWRP to clear out any residual files from your previous flashing attempts.

Currently CyanogenMod does not officially support the Canadian variant (d803) of LG G2, but some people had successfully modified the d802's package.  This involves extracting a file from the official CM11 zip, modifying it to include the d803 model, re-packing it into the zip, and finally flashing it.  A different kernel is also required to be flashed right afterwards, and can be found here (you will need the AOSP based one.)


How to prevent play store from detecting VPN?

One of the most successful methods I use (which you can also use in this case) to bypass VPN detection is using an anonymous or elite proxy.
To implement the proxy on a per-app basis you can use ProxyDroid or any similar application.
After connecting the VPN simply grab an elite/anonymous proxy from paid or free sites like this one: hidemy.name.
Open ProxyDroid and input the elite proxy and filter to use with Google Play (or other apps if desired).
Connect and download.


Being that YouTube is a product of Google, You can report the bug on Google's report security bug, page

From the page:

  If you have found a security bug in a Google product and want to
  report it to us, you've come to the right place. Please fill out the
  following form and we'll be in touch shortly. If this is a valid
  vulnerability report, it might also be eligible for a reward as part
  of our Vulnerability Reward Program. Thanks!


CyanogenMod 11 nightly on Samsung Galaxy Tab 2 10.1 (gt-p5100)

Ok I was able to get it going by using TWRP instead of CWM. TWRP is much better!


Is my phone using LTE if the notification area says 4G?

LTE actually does not meet the original 4G standards, it is neither faster nor more advanced.

I'm pretty sure that it's just an icon change, but if it's not it's almost certainly that your connection is better rather than worse.

I recently saw this on my device as well and used SpeedTest to check how the connection was performing.  My download and especially upload speeds were absurdly high.  You could use it to see whether your speeds align with your expectations as well.


How to download an app from another region/country?

There were two ways I was able to solve this.  I preferred to use the APK method, but the other method was to create a google account in that country and add it.  APK method was cleaner.


What does a single tap on the lock screen do?

It's telling you that you will have to unlock the device before you can access a widget tap's action.

Eg: If I tap on the clock widget on my lock screen, I will have to unlock the phone before it opens the clock screen. If I tap on a Google Now widget on my lock screen, I will have to unlock the phone before it opens Google Search/Now.

The dimming is trying to have you focus on the lock mechanism (where you swipe).


If you are running Android 2.1 or 2.2 you do not want to use app killers. It actually hinders performance and could cause more problems because Android has built in app killing functionality into the OS.

No app currently exists that can do all three of those. You can get an app that can do the first one, there are lots of those but I wouldn't recommend any of them. Or you can get an app that can do those last two...

Native Marketplace
Uninstaller
AppBrain App Market
My Market
App Center - by AndroidPit


This seems like a device specific issue. Some phones will allow the flashlight to be on while the camera is on, others won't.

The phone I'm using, Galaxy S5 has no issue with the flashlight that comes preinstalled, being on while the camera is running.

So if you're anyway buying a phone for this, Galaxy s5 or any other phone that allows it, should be your choice. (In my humble opinion, instead of buying this phone, you're better off buying a security camera with night vision...)

In the screenshot below, I have the manything app in recording mode, and the flashlight on, and I'm facing a mirror.

Using galaxy S5 on AT&T Android 6.0 flashlight widget that comes with the phone.

Note: other flashlight apps didn't work while camera is on.

I wouldn't post this as an answer had there not been a comment from OP saying:

  @Abochur I mean I'm literally going to buy an S5 for this express
  purpose :). Could you help me make sure I get one that'll let me use
  the flash like you can?


Fairphone Open stuck in “optimizing app” loop after OS update

After scouring the Fairphone forums, I found a solution that worked (among many that didn't). So thanks to https://forum.fairphone.com/t/stuck-optimizing-apps-after-updating-on-fp-open-os-16-07-1/21146. The important thing was to reinstall OpenGApps. In more detail:

Yank out the battery to break out of the boot loop, and put it back in.
Ensure that you have a copy of the OpenGApps package on the internal flash or on the SD card. Select Platform=ARM, Android=5.1, Variant=pico (other variants presumably work too). It doesn't necessarily have to be the latest version (it worked for me with a version that was a couple of months old that I still had on the internal flash).
Press and hold the Volume Up and Power buttons for a few seconds, to load the phone's recovery image (TWRP).
From TWRP, choose “Install”, then select the OpenGApps zip and install that.
TWRP prompts to clear the cache partition. I did that, I don't know if it's actually necessary.
Reboot.

freibadschwimmer's update guide suggests doing the same for Xposed Framework, if you have that installed. Other package managers such as F-Droid may also need to be reinstalled; it isn't clear to me whether that's actually necessary.

I recommend keeping zips of extra software such as OpenGApps on the internal flash all the time, in case another update causes the same problem.


android 4.4 phone not charaging and no sync when pluged into computer

Fix this by using the oldest firmware build on sammobile i thought the newer firmware build would be better but flashing an older firmware build fixed all my usb problems.


How use Escape, directional keys on the virtual keyboard?

BTEP has a "Using Better Terminal Emulator Pro" page on their wiki which explains most of the special shortcuts and keys. The basic breakdown of what you're looking for is:

For directional input: Either use a keyboard that supports this or use BTEP's virtual direction pad feature. You can access it by tapping the screen when the keyboard is visible, long-pressing the screen when it isn't, or pressing the Search button. The cursor should change to a > character to indicate you're in VDP mode, and you can swipe your directional input (i.e. swipe up for the up key).

For ESC: This is usually mapped by default to the volume up key, but you can remap it to any of the available programmable shortcut keys. You can also press the Search button then press [, since Search is mapped to the control character on devices that lack a trackball or dpad (as well as activating VDP mode) and ^[ (CTRL-[) is the ESC character.


Treble: How do I check if it is enabled on my device?

Works on unrooted devices also

Install Termux and run getprop ro.treble.enabled

It returns true if your device supports and false if it doesn’t

With adb

adb shell getprop ro.treble.enabled


Contacts missing on new Galaxy Core Prime

Did you select an online/synced account as the location for your contacts?
You can simply login to your former account and synchronize the contacts to your new device.
Did you select SIM card as the location?
I hope you've got that card. Simply put it in your device and your contacts are back. Move them to an online account or do whatever you want with them.
Did you select phone or device as the location?
Well, there are your contacts now. And they won't leave your device any time soon.
Some manufacturers offer you to sync those contacts to their services anyways so maybe you can login to that account and restore your contacts.


connecting android to pc via usb cabe and file transfer

Some device is not working as usual. So you have to enable developer option from your mobile setting.

Developer option comes in different location in different mobile

like

may be show in setting

or

may be in setting >> additional setting

If developer option is not shown in your mobile then you have to follow some step for showing developer option in setting.

Go to Settings > About phone > Tap 5 to 6 times on Build number
now your developer option will show in setting or other relative position.
and then enable your developer option as well as enable usb debugging.

and then try with your cable

hope this will work for you


I have a Samsung Galaxy S4, and Nova is surprisingly snappy on it. You can change how fast the animations / transitions are. In my case, I set it to faster than light. If you're not content with that, you can go further and disable animations / delays via the phone's Developer options settings.


USB Android Debbugging, I've tried everything I can think of

I had a problem with my LG Nexus 4 not being recognised when I connected it to my laptop and in the end this solved the problem for me...

On your mobile:

Go to Settings > Storage > USB Computer Condition (Menu option from Storage Screen)
Change from Media Device (MTP) to Camera (PTP)

After that it was recognised without any issues.


If you're looking specifically at the stable builds of CyanogenMod (CM), then you would be better off rooting Cyanogen OS. Otherwise you would likely be reverting to an older Android version or waiting months for the stable release of the current version of CM to be released. In my experience, the stable release typically comes at the end of the development cycle for a particular Android version, e.g. around when the new version is being released. On the other hand, for the OnePlus One the comparatively stripped out CyanogenOS build would come a few weeks after the release of a new version of Android.

The obvious pro for CM is that it is much more recent and updated. New features are being added constantly, so by the time it reaches a stable release it is much more fully featured than the comparable Cyanogen OS release. The obvious downside is the time that it takes to get to that point.

The obvious pro for Cyanogen OS is that it is built specifically for your device under contract by the manufacturers. It's already on your phone and is supported officially. Being an OEM ROM, it often comes with additional Cyanogen OS-specific apps and themes that aren't available to CM, CM-based ROMs, and AOSP-based ROMs. Although from my experience with the OnePlus One, this point is insignificant.

Between those two options, there isn't likely to be any significant difference in stability. With CyanogenOS, you WILL have to reroot the device every time you flash an official update. You would not have to deal with the steps of the root process that revolve around drivers, which is most of them, but it will also overwrite your recovery so you would have to flash that again as well. With CM the update process involves rebooting to recovery and installing the .zip file. The more I think about this, the more I'd recommend CM. You've changed my mind.

If you are interested in some of the additional features that a custom ROM has to offer, you should browse the lettuce xda page here for custom ROMs. The only people that will be able to answer your stability questions are other people on your same device running these ROMs. A CM 13 build was just released last week so it may be too early to consider that a daily driver but the CM 12.1 build has been around for a while. There are also plenty of other ROMs out there if you want to go down that route.

The rooting process for your device is the same as many others and is very straightforward. Here is a detailed guide. These steps will be common to both rooting CyanogenOS AND installing CM, which is only four additional steps: download ROM zip, reboot to recovery, flash the zip, and wipe cache and dalvik. Reboot.


Straight answer to your problem is

Go to settings and then apps under settings then find google play services and google play services for instant apps clear data for google play services for instant apps and then

Simply click here  it will redirect you to "google play services" in play store. There can be options: 1. To update(you need to update in this case), or 2. To deactive(nothing needed, it is already up-to-date).

Note: Above solution will definitely work but in  case if you don't see option to update the app(written at 2nd point) . Then try restore to factory settings.

Enjoy!


change download folder to external sdcard in ttpod

Press 3 line button beside TTPod to open the menu
Press "Settings"
Press "Downloads"
Press "Audio auto download directory" and select where you want to save your files


Is there a way to set a default volume for different bluetooth connections?

There are two app in the Playstore you can try A2DP Voume and Bluetooth Volume.

A2DP is an app project hosted on code.google.com

Some features of A2DP:

Captures car location automatically when device disconnects. Automatic car locator. (option)
Each device can be independently configured.
Automatically adjusts the media volume on Bluetooth connect and resets on Bluetooth disconnect. Automatically captures location information on disconnect so you can find where you left your car. Read More

Screenshot (Click to enlarge image)

Bluetooth Volume app feature:

This app is perfect for people that always adjusting the volume on their phone immediately after connecting to Bluetooth in the car. This app will do that for you automatically.
Also has an option to launch a Car Home when you connect to Bluetooth.(You need to install Car Home app to use this feature).

So, I think one of the above apps is what you might be looking for.


Downgrade to KitKat on Micromax YU Yureka

I faced the same problem. Follow these steps and your problem will be solved:

Dial this code *#*#7769#*#*. One proximity info will come.
Press start and wait until your phone proximity info is shown on screen
Press exit.


Google Play Services taking more and more storage

What Akas refers to is using the Link2SD app, which is "kind of" App2SD, but much more flexible: You can get the entire app moved out (not just parts), and can even move apps you otherwise couldn't. But Akas missed one important part: your device must be rooted in order to use this special way.

As to the other part of your question: Sure you could uninstall the updates of Google Play Services -- but that wouldn't help you in any way, as the app will automatically update itself again. Furthermore, there might be dependencies, as other apps use this service (e.g. Google Play to access the playstore, and others). So newer versions of those apps might rely on newer versions of the Play Services.

Maybe someone digged (or will dig) a little deeper into all those dependencies and what can be done about them. It might end up in using some "legacy apps" -- like e.g. the Legacy Playstore (original post), while the original ones could be frozen/removed. Maybe all this is possible -- it again would require you to root your device, as these apps need to be installed as system apps.

While we all wish our devices might have a long life: if you look at the specs of your two-years-old, and compare it even with todays low-end devices, you will see the difference. And if you compare app sizes from two years ago ("What? 1 MB app size? Too big!") with todays ("Unfortunately, the play store has a limit of 50 MB app size, were we cannot fit our app into"; with my own words the summary of LibreOffice for Android), you see were it goes. And while I fully agree that core services/apps should be kept slim, there's nothing we can do about that...

Enough theory: if your device is rooted, or rooting it is acceptable (and doable) for you: Akas recommendation seems the best way out for you.


Why is Call Waiting not available on Android 2.3.4 (Gingerbread)?

It may be a Samsung omission rather than an android one as from manuals that Google has provided, Call Waiting is referenced in their documentation.
http://www.google.com/help/hc/pdfs/mobile/AndroidUsersGuide-2.3.4.pdf


The media scanner "indexes" the music, videos, images, etc on the sdcard so other apps don't have to scan the entire sdcard to know about them. another feature that uses this is the ringtones/notifications, if it does not scan, you will only be able to select the ringtones/notifications that are located on the device, not ones that are on the sdcard.

you can prevent media scanner from indexing a specific folder by creating a file called ".nomedia" in the folder you want ignored. I do not believe that this file is recursive though, so if there are sub-folders, and you dont want them scanned, you would have to create it there too.


Disable gmail notifications for certain labels during certain hours

You can use the app Quiet for Gmail, it will enable/disable the synchronization based on your schedule. And you set it up to disable synchronization just for your work email account and leave your personal email always on.

You can find the app here:

https://play.google.com/store/apps/details?id=com.sgarcia.quiet_for_gmail


Go to the cache, and find the file that you want to play. There will be 2 files with the same name, one will be only a few kb, the other will be the video (should be a few MB).

Long press on the file until you get the menu. Then select "open as", then "video", then select a video player.

I used the stock one that comes with the phone even though I have several others I thought I would try that first, and it worked first time (this was on a Galaxy S3).

If they play then copy them where you want, pc etc. You might need to rename the video files (adding the .mp4 file extension).


Will Android shift Google Calendar events when I go to different time zones?

Yes, at least for me. All of my events are stored as GMT and the time of the event is displayed based on the time of the device (my location).

Now, I don't know what happens if you "specify" the timezone like you mentioned, as I have never done that.


Log into your account and click this

https://myaccount.google.com/device-activity

Source

It works for me. I don't think GDPR
 should make a difference, else that would have been widely reported

(Click to enlarge)


Well first i will answer your question. If you want to use a recovery made for a complete Another model for your phone, yes it will brick your phone. Even though another model is very similar to your phone's model, it's not identical! There will always be some differences internally. For such cases you have to port the recovery. Before going for porting, Go to xda forums I'm sure there you will find a recovery for your model. But if you don't find it there, you need to port one from different model to your own.

For recovery porting is not easy and very risky I'll advise you to take help of someone who is well experienced in this. And proceed on your own risk.
Another part i would like to add is flashing recovery and rooting a phone are completely different concepts. Please read thoroughly on xda forums before proceeding.


So, based on the comments above you do need a notification solution.  The obvious one is just to turn off notifications for the email app, or to turn down the volume before you go to bed.  You could also use an app like Tasker to do the latter automatically based on profiles that you set.  For example you can have it mute notifications when plugged in to charge: http://androidforums.com/1207528-post3.html


An app that can give a clear overview of what exactly is eating up my phone space?

Use Disk Usage app. It draws nice graphical diagram with directories and files proportional to their size (similar to WinDir Stat).


Can I edit Swype's user dictionary to remove typos?

There is unfortunately no way to directly edit the dictionary.

You can delete any user-added word by highlighting it and hitting the Swype key.


Does the auto factory reset reset the counting of 15 wrong attempts?

The failed unlock counter will reset when the device is successfully unlocked.


How to find the pathname of the swap partition on SD card?

I installed the Disk Info app and in the options, I enabled Expert mode and Unmounted partitions.  It doesn't say "swap", but it shows clearly that it's the only other partition on the SD card and it's the right size, so /dev/block/mmcblk1p2 must be the one:

Swapper 2 is configured to use /dev/block/mmcblk0p3 by default, so I'm glad I didn't go with the default.


Different wallpaper for portrait and landscape

You can use an automation app here.
Automate
Setup a flow like this:
(Click image to enlarge)

Location of relevant blocks:

Interface → Screen Orientation?
Settings  → Wallpaper image set

After setting it up, make sure to install the permission it asks for - set wallpaper.
This worked in my COS12 and PA build of Android 5.1 but somehow failed in Android 5.1 nightly build of Vanir ROM.

Tasker
Try the trial version, before buying from Play Store.

Profile: State → Display → Display Orientation →Portrait

Task: (Actions): Display → Set Wallpaper → fill the details

For landscape orientation, you can either add an exit task by long pressing the task entry next to linked profile under Profiles tab and choosing "Add exit task", or setup a new profile for landscape orientation and create a new task for it.
For latter approach, make sure to disable Restore Settings  for both the profiles. A profile's properties can be accessed by long-pressing the profile and tapping the settings icon.

Tasker worked in both Android 5.0 and 5.1 ROMs installed in my device.


Unfortunately Creating a Google Account is currently your only option, It's not hard to create a new account and it will probably be beneficial for many other applications you might download.  It's annoying to create a whole new account just to keep things separated but it's necessary to gain access to Google's location features on Android.


Traffic analysis and inconsistent results on Nexus One

After some days of struggling I've come to the understanding that my Nexus One's NIC was corrupted/broken/something_bad_else. My tests were all messed up and with no logical connection.

I've tried with a S II device and results seem to be a little more consistent. By the way, even in this case, I can't achieve a worse throughput increasing the bit rate, actually it's still floating around 90% (from 88 to 95 randomly).

Probably it is dued to wi-fi instability and UDP packets instead of TCP. For my purpose having tried with a different device gave me a suitable answer.


How can I change the default browser on Xiaomi Mi Max phones?

MIUI 9

Go to Settings-> Installed Apps. On top you have three dots, tap on that three dots will pop up a menu, select Default app. Under browser part, set Chrome as default. After this operation, every link you open will be loaded in Chrome browser.

MIUI 8

Go to installed apps as described above. While when you are in Installed apps, you can see an icon written with Defaults. Tap on it, and set required.

Note: MIUI is the user interface of Xiaomi devices. MIUI 9 is the latest now.


Unable to set pattern lock on S4 KitKat 4.4

Try re-flashing the stock NC5 firmware using Odin. See this answer for instructions.

I have no idea why this is happening, but logically, I think that would have to work:

You've already tried clearing the sources of security policies that disable settings (credential cache and device administrators). Also encryption, but you say the device was never encrypted.
The problem persists after a wipe / factory reset, so it can't be caused by any of your apps or settings.
I'm 99.999999999999% sure that this cannot possibly be caused by a hardware issue.
I don't believe in black magic or possession by ghosts or demons.

So there's really nothing else left; whatever the problem is, it pretty much has to be caused by some problem with the firmware. Not only does that seem to be logically necessary, the circumstantial evidence heavily supports this theory: it happened when you upgraded the firmware, without (I infer) making any changes to the configuration or installing any apps.

And since the NC5 firmware isn't supposed to disable these settings, it's probable that either there's something wrong with the firmware you downloaded, or something went wrong with the upgrade process. So re-downloading from a reliable source (I've used the firmware linked above at least a dozen times, and never encountered a problem) and re-flashing should fix it.

One more thought:

Since I'm deducing that the firmware upgrade is the source of the problem, it might have something to do with the fact that you obtained the NC5 firmware from a source other than Verizon's OTA upgrade. I know that Verizon's OTA upgrades do more than just flash the firmware, as proven by this process for rooting an NG6 device (which I've used successfully) by temporarily downgrading to NC5, rooting, and then upgrading to NG6 from a non-OTA source.

Note that the instructions stress that it won't work if you leave out any of the steps, and the first step in the process is to take the OTA upgrade to NG6, then downgrade to NC5, root, and upgrade back to NG6 from a non-OTA source linked from the instructions. The fact that the author is providing his own link to the NG6 firmware, yet instructs you to start by accepting the OTA update and only use the non-OTA NG6 firmware he's providing in a later step, implies that while there's no problem using a non-OTA NG6 after you've done the OTA update, you'll have problems if you never accept the OTA update in the first place.

So, try re-flashing the previous firmware, then see if you can still get the NC5 OTA upgrade (or even the NG6 OTA upgrade). I strongly recommend taking a nandroid backup before trying this, because I've seen cases where downgrading the firmware can cause serious system malfunctions that I've only been able to remedy by doing a factory reset. Also, check whether the screen lock settings are enabled both before the OTA upgrade (but after the downgrade), and after the OTA upgrade.

I'm not 100% certain what the previous firmware was, but I'm pretty sure it was MDK, also available from the GalaxyS4Root page I linked at the top of this post.


Remove option for dual SIM in Sony Xperia C3 Dual

On Mediatek devices, Gravitybox works well to hide the said SIM card notification. However, if this app does not work for your Qualcomm device, then use an alternative app named NotifyClean which can selectively hide notifications including the said one.
See if it helps.
Note:- Device needs to be rooted and Xposed Framework installed.

About Gravitybox

GravityBox is a module which primary goal is to provide the users of AOSP devices
with a tweak box to turn their vanilla AOSP ROM into custom ROM packed with additional features and tweaks
without need to flash anything. Most of the preferences can be changed on-the-fly without rebooting.

About NotifyClean

You could configure which apps are allowed to create notifications in the top left area, the notification area. If an app creates a notification it will be collected and added to the list.
You could deny all notifications of an app or only specific messages - if it's not a customized notification. So I used it to hide "waiting for connection", but not "you are connected".


Is it possible to run applications with different locales (languages)?

This module for Xposed Framework should do the trick if your device is rooted.

Install Xposed Installer.
Run Xposed Installer and use it to install Xposed Framework. It's a two-tap operation followed by a reboot.
Find the App Settings module in Xposed Installer, install and enable it. Reboot device.
Click the module in Xposed Installer to show its GUI. You'll be presented with available features, including changing app locale.


How can I install a CSC code which are not listed on Samsung Galaxy S/S2/S3 CSC app?

If you change CSC, you need to wipe / Factory Reset your phone.

So, you might as well download and flash a stock ROM that is for India. It has Indian CSC.

EDIT #1: You do not need root to flash stock ROM on your phone using Odin.


You can try Donkey Guard the Xposed Framework module from which you can manage permission for apps.
DonkeyGuard allows blocking access for any installed application on your phone to the following data separately:

device_id
phone_number
sim_serial_number
subscriber_id
incoming_call_number
outgoing_call_number
gps_and_network_location
impi_impu
cell_info
accounts
accounts_credentials
read_contacts
read_call_log
call_phone
read_calendar
receive_sms
send_sms
receive_mms
send_mms - not implemented in alpha
record_audio
use_camera
read_bookmarks
wifi_info
switch_mobile_network_state
switch_wifi_state
sim_info
network_info
android_id
access_media
read_external_storage - not implemented in alpha
write_calendar
write_call_log
write_contacts
write_bookmarks
write_external_storage - not implemented in alpha
account_authenticator
read_sms
write_sms
read_mms
write_mms
network_state

Edit:
Alternative Module : Xprivacy (suggested by @beeshyams)


Simple... Samsung devices do not support fastboot, you use Odin or Heimdall to flash what you need.


Nexus 5, I'm getting remote: flash write failure while trying to fix a bootloop

The flash-all.sh script does not take into consideration that your bootloader is locked after each restart.

I opened the shell script and executed each command one by one, re-unlocking with the following after each command:

fastboot oem unlock

I flashed each image with no errors, but it did not seem to write to memory regardless.


Do you have to root an Android device to install Ubuntu?

Yes. See this method or this one, for example.

As per eldarerathis' comment, these are both for running Ubuntu in a chroot environment.


Many people have reported that Plugable's adapter works.


Battery was once swollen, but is now normal

Technically, this is just an update of what happened to my device, but this can also be the answer to my question: "Is it safe to charge and use now?"

We took the device to a repair store. They tried to charge the battery, but the battery won't charge. Also, the battery didn't explode when it is charging.

They opened the back of it, and they saw that the battery is still a little bit swollen.

They said that the cause of this is leaving the device for a long period of time, just like what I said in my question:

  It was swollen many years ago, so I just left it. Now, I just found it and it is now unenlarged.

They also said that we should replace the battery to use it.

So, to answer my question:

1. Is it safe to charge?

Probably yes? They charged it, but nothing happened. I just don't know if it will explode if I charge it for a longer period of time.

2. Is it safe to use now?

Well, this doesn't make any sense as the device doesn't have power for it to run. But, if I already replaced the battery, then yes, it is safe to use.


Developer Options not showing up in LineageOS new build

We have a potential XY problem here...

Instead of trying your utmost to get into developer options, just power off the phone fully, then use the key combo POWER + VOLUME_UP to boot into bootloader, from which you can start tackling the problem in ways you'd like.


How to use your voice to add items to a shopping list?

You can now say "Ok Google" followed by "Add Chicken to my Shopping List" via Google voice recognition app. See a list of Google now voice commands here.


How can I allow my friend to see my screen using a web browser without requiring installation of any app on their or my device?

The W3C spec that covers screen capture for the Media API:

https://www.w3.org/TR/screen-capture/

is in Working Draft and as of May 2020 does appear to have some support on Desktop browsers but is not supported by any of the main Mobile browsers:

https://developer.mozilla.org/en-US/docs/Web/API/Screen_Capture_API


Widget to immediately phone a specific contact?

I'm not sure if this is HTC specific, but this is what I need to do to get a "direct dial" icon on my HTC desire.

Long press on where you want to add the icon
Hit 'Shortcut'
Hit 'Direct Dial'
Select the contact you want to use (if the contact has more than one number, you'll need to pick which one)

There should now be an icon that will have that contact's photo and a small phone symbol on the bottom right. If you hit the icon, you'll immediately dial the contact.


Erase successful, but not automatically formatting. Can't determine partition type - Jelly bean 4.1.2 with Nexus S

I had a similar issue with my Nexus 4 after flashing the factory images

What fixed it for me was going into [stock] recovery and selecting clear cache and doing a factory wipe, that seemed to fix the partition sizes

Oh also check to see that you have the latest bootloader on the device too, check out https://developers.google.com/android/nexus/images for the most recent factory images


Page up and page down in web pages and elsewhere

For the goal to be achieved precisely we need Xposed Additions Pro and Tasker installed, where the former requires  root access and Xposed Framework (stable build) installed.

Once you install the Xposed Additions, you'll be asked to activate its module in Xposed Framework. Activate it.

We'll be using Xposed Addition's ability to intercept a key-press and would provide a condition and action to be performed  for that key-press. We'll use Tasker to circumvent Xposed Addition's limited set of options.

Note: All sections tested on Android 4.4.2 and 5.0.2.

Instructions for Xposed Additions

Launch Xposed Additions → tap Buttons
Tap Add new key
Press the device's button to be used as a keyboard's  ↑    key
I chose Volume Up/+ button
Tap the entry for the button you chose earlier
Tap Add new Condition
Tap Load Applications List
Select the app where you want Volume Up button to simulate a keyboard's  ↑    key
Tap your previously selected app's entry
Check the box to activate Click
Tap Click
Choose DPad Up aka Directional Pad Up -- it's a KeyEvent

(Click image to enlarge; hover to know details)

(Order of images: Follow images from left to right in each row)

Now create an action for Volume Down/- button in aforesaid manner but choose DPad Down at final step.

It is time you launch the app you selected in the said steps and try pressing Volume Up and Volume Down buttons. They will work as a keyboard's  ↑    ↓   directional keys.

Note that contrary to a physical keyboard where if you hold a directional key the system will continue to scroll up/down, this is not the behavior you would observe if you long-press your (aforesaid selected) device's buttons.

Also, in place of choosing DPad Up and DPad Down, choose Page Up and Page Down to simulate a keyboard's Pg Up and Pg Dn key or assign them to a different action listed in step 10.

And, don't bother about ringtone or speaker sound level since they would be managed by long pressing those Volume Up and Volume Down buttons. This behavior is valid when your aforesaid selected app is launched.

I've tested successfully the aforesaid solution on Chrome, Firefox, and some text editors. So far so good!

Nope! The said solution is not good for all applications. We want to cover all applications, so why limit to web browsers and text editors only.

Unfortunately, there are apps on which the said solution doesn't work. The KeyEvents we used there seem to have no effect on apps like Foxit MobilePDF, WPS Office, BetterbatteryStats, and more in the wild.

Let's focus on a new solution now. Android allows sending swipes using input command; Xposed Additions allows using a custom shortcut as an action; Tasker can create a custom shortcut to use input swipe.

Instructions for Tasker and Xposed Additions

We first need the swipe's start and end (X and Y) coordinates to use them in input command.  We can record it using Getevent command.

Setup adb in your PC, plug the device into PC, enable USB debugging in device, launch a shell on PC, and enter:

adb shell su -c 'getevent -l'

It would show some lines and then would wait indefinitely for output.
It is time you decide the length of your swipe as an alternative to DPad Up / Page Up.

E.g. The arrow length measuring a swipe in the two images is an alternative to scrolling length of DPad Up/Down and Page Up/Down respectively.

When you would make a swipe on the screen, the shell on PC would show output like:

/dev/input/event0: EV_ABS       ABS_MT_TRACKING_ID   0000044c
/dev/input/event0: EV_KEY       BTN_TOUCH            DOWN
/dev/input/event0: EV_KEY       BTN_TOOL_FINGER      DOWN
/dev/input/event0: EV_ABS       ABS_MT_POSITION_X    00000300
/dev/input/event0: EV_ABS       ABS_MT_POSITION_Y    000006de
/dev/input/event0: EV_ABS       ABS_MT_PRESSURE      000000c0
/dev/input/event0: EV_ABS       ABS_MT_TOUCH_MINOR   00000004
/dev/input/event0: EV_SYN       SYN_REPORT           00000000
/dev/input/event0: EV_SYN       SYN_REPORT           00000000

...

/dev/input/event0: EV_ABS       ABS_MT_POSITION_X    000002fb
/dev/input/event0: EV_ABS       ABS_MT_POSITION_Y    000004e3
/dev/input/event0: EV_ABS       ABS_MT_PRESSURE      000000cc
/dev/input/event0: EV_SYN       SYN_REPORT           00000000
/dev/input/event0: EV_ABS       ABS_MT_PRESSURE      000000c8

After making an upward swipe of specific length, press Ctrl+C in PC to stop the command.

In its output note the first ABS_MT_POSITION_X (00000300) and ABS_MT_POSITION_Y (000006de), and last ABS_MT_POSITION_X (000002fb) and ABS_MT_POSITION_Y (000004e3) entries. They are the start (X1,Y1) and end (X2,Y2) coordinates in hexadecimal form. Convert them into decimal form (try a converter here).
In the shell, if you enter:

adb shell input touchscreen swipe X1 Y1 X2 Y2

(replace X1, Y1, and X2, Y2 with the now converted decimal coordinates) you would notice an upward swipe on the device effectively simulating scroll down. Manipulate those coordinates until you get your ideal scroll down.

As an alternative of using Getevent, you can try a more friendly approach.

Enable Pointer Location under Developer options. Once you enable it your device's status bar would get covered with a bar showing some coordinates which would change with the movement of your tap/swipe on screen.
Time to record your swipe length. Touch and hold your finger on screen and note X: and Y: shown at the top. Start swiping up the finger to the desired length; stop but don't release the finger and note down the corresponding X: and Y: coordinates.

Those are the X1, Y1 and X2, Y2 coordinates for your up swipe. They are in decimal form, so you can directly use them in input command.

You can choose to disable the Pointer locations now.

Instructions specific to Tasker

We would now create a shortcut to simulate the swipe we manually performed in the last command, for the purpose of automating it.

Launch Tasker and enable it. If its icon above Profiles tab is lit, then it's already active. Note that everything in Tasker is saved by pressing the back button, which would also change the active window.
Create a task under  Tasks via + (at the bottom) → name it (say Scroll Down).
Create an action in it through + →Code → Run Shell, and enter these details:

Command: input touchscreen swipe X1 Y1 X2 Y2

Replace the X1, X2, and Y1, Y2 with the coordinates you noted earlier. E.g. input touchscreen swipe 768 1758 763 1251.
Check Use Root
Store Errors In: %sd_err -- this step is optional.

Create a new task named Scroll Up, and create an action in it by following step 3. For swipe down simulation simply interchange the coordinates, so it would be input swipe X2 Y2 X1 Y1, and optionally use %su_err to store errors, if occur!

Instructions to use Task shortcuts in Xposed Additions

This is the final phase of the solution and would  use those custom shortcuts in Xposed Additions.

Follow the steps 1-11 in the first section dealing with the usage of  Xposed Additions
Choose Shortcut instead of DPad Up or Page Up
Choose Task Shortcut → Scroll Up
Choose 3x3 square boxes icon at the bottom
Choose an icon and come back to Xposed Additions.
Repeat the aforesaid steps 1-5 for Volume Down and select Scroll Down in it. You get the idea by now what to do every time.

I've compiled a video showing the whole answer in action. Here it is. Mind the quality because it is heavily ripped from 100MB to 7.1MB.

Cheers!


Access Android log files for specific periods on android 7

Android does not store the output of logcat in flash memory. Instead logcat uses a ring buffer in RAM of usually 64KB up to 4MB (depends on what is configured). RAM is much faster than flash memory and also flash may fail earlier if constantly logmessages are written onto it.

A ringbuffer means that if the buffer is full the oldest entry will be overwritten by a new entry. Therefore logcat usually only contains the last minutes or hours. And only log messages after the last reboot as the logcat buffer is not saved on shutdown and the RAM memory is also lost on reboot.

Therefore there are no old log messages you can access.


What the APK and exploit do (usually) is as follows:

The APK puts the right files in the right place to run the exploit
The APK runs the exploit
The exploit attempts to attain root access
If it succeeds, the exploit remounts /system as read-write and runs the installer script
The installer script attempts to install the su binary and superuser APK, and reboots

As an example, this page details how the rageagainstthecage exploit attempts to gain elevated privileges.


Destination host unreachable while using WiFi on 2.2

I figured out that if I disable 802.11n mode and just leave b/g enabled, then my phone works on WiFi just fine.  It seems that there was an issue using 802.11n on my phone.

I don't yet know if the issue was my AP or my phone, but I guess I will need to find a way to disable 802.11n on Froyo.


Would I install android studio with 2 GB RAM


Only automatically connect to certain Wi-Fi networks

Go into your Wi-Fi settings. Long press on the networks that you don't want to automatically connect to and tap 'Forget'.