SQlite3 - Vibrant General

greetings, i need SQlite3 to change my android id, since everyone has the same id on the froyo leak. if anybody can provide me with it, its located in
/system/xbin
to be specific i need it to access storm8 games. they identify your account by iphones UDID or android_id. for those interested in changing it just follow the following commands using adb
Code:
su
cd /dbdata/databases/com.android.providers.settings
sqlite3 settings.db
sqlite> insert into secure (’name’, ‘value’ ) values (’android_id’,'what-ever-your-device-id-was-before’);
sqlite> .exit
Reboot
or simply download android id changer, which personally i don't like.
***mods if find find this inappropriate edit the post but keep the request for sqlite3

Related

[Question] Pattern lock - too many attempts

Good day,
I was curious about what would happen if i do to many fail attempts in the pattern lock screen of my magic.
I looked around on google to find the answere and noticed that there were many many pages that talked about andoid having a bug.
If i understood correctly, after x times incorrect pattern inputh you get a login screen for your google account you used for the phone.
The bug seems to make the login impossible.
You will be able to enter the credencials but login will always fail.
I was wondering if anybody is aware about this and can tell me if this bug has been solved now.
Many people talk about performing a hard reset when this happens.
Which is a solution,... but not one i was hoping for.
NOTE- i am not in this situation now, i can access my phone.
But i do have a lot of D**Head friend who love to figure out what happens when they try to many times.
If you try too many times you get a timeout. You have to wait 30 seconds for each attempt.
Don't know bout the loginscreen though, never happened to me.
Lucky for you, I've had the exact same problem recently and found a solution that doesn't require full reset =)
./adb shell
# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite> update system set value=0 where name='lock_pattern_autolock';
sqlite> update system set value=0 where name='lockscreen.lockedoutpermanently';
sqlite> .exit
# exit
originally found on http://www.naschenweng.info/2009/09/17/android-too-many-pattern-attempts-phone-is-locked
good luck!
Hi there!
I have exactly the same problem but when i try the solution using the sqlite3 commande, i got an sqlite3: not found .
Is there any pre-requisite i forgot?
My steps were: fastboot with a modified image then adb shell: didn't work, then normal boot and adb shell: didn't work too.
Any help will we welcome!
Lg eve pattern locked need help!!!
my pattern lock was entered wrong too many times and i dont know how to access the phone even my google account wont work what do I do?
i have an Lg eve .
Here is what i got.
C:\AndroidSDK\tools>adb shell
# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite> update system set value=0 where name='lock_pattern_autolock';
sqlite> update system set value=0 where name='lockscreen.lockedoutpermanently';
sqlite> .exit
# exit# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite> update system set value=0 where name='lock_pattern_autolock';
sqlite> update system set value=0 where name='lockscreen.lockedoutpermanently';
sqlite> .exit
# # sqlite: not found
# sqlite: not found
# sqlite: not found
#
# exit
#
Click to expand...
Click to collapse
Have an idea?
afras said:
Have an idea?
Click to expand...
Click to collapse
Yeah. You did it wrong.
Pay attention:
Type this:
./adb shell
Click to expand...
Click to collapse
You'll get a shell prompt.
Type this:
sqlite3 data/data/com.android.providers.settings/databases/settings.db
Click to expand...
Click to collapse
You'll get the sqlite prompt.
Type these three lines:
update system set value=0 where name='lock_pattern_autolock';
update system set value=0 where name='lockscreen.lockedoutpermanently';
.exit
Click to expand...
Click to collapse
Many thanks to you my friend, it worked
You sir, are a life-saver
lost
ok i am having the exact problem with my lg eve android...but where do i type in these codes is my question?
im getting crazy
sqlite3 is there right?? see screenshot
C:\android-sdk-windows\tools>adb -d shell
$ su
su
# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite3: not found
#
running sqlite3 manually (doubleclicking sqlite3) works perfectly, but it doesnt connect to my android phone
Hi,
I try to unlock my sister's phone (HTC Tattoo), but it doesn't work, I have a problem with sqlite3 : I write in the shell "sqlite3 data/data/com.android.providers.settings/databases/settings.db" and I have this : "sqlite3: permission denied"
I don't know what to do !? The device is recognized (adb devices detects it) and the Debug USB mode is activate.
I'm waiting for your help.
P.S. : excuse me for my bad english : I'm french !
Easier fix!
I just finish talking to rogers and all you have to do 9if your willing to reset your phone and lose all your apps etc) is hold one of your volume buttons the centre menu button and the photo button hold these 3 for about 15-25 seconds and it will ask you to factory reset your phone! problem solved!
I have a Q...
Approximate how many times you have to enter the wrong password/pattern to have it permanently locked?
I don't think it perma locks. If you mess it up, it should just ask for your Google credentials again.
Sent from my T-Mobile myTouch 3G using Tapatalk
yeah... I want to know how many attempts before it asks you for the google credentials.
thx
3-5, can't remember for sure though.
Sqlite3 not found
>20 wrong codes and your locked out.
>I found this out thanks to my darling wife...and of course I had just turned off wireless an hour before to stop kids downloading crap whislt playing >games.
>So now I'm stuck...
C:\android-sdk-windows\tools>adb shell
$ su
su
# sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite3 data/data/com.android.providers.settings/databases/settings.db
sqlite3: not found
#
>Any ideas how to "find" sqlite3? :fingers-crossed:

[How To] Enable Non-Market apps on Captivate (consolidated)

(additional CHOWN notes added below. If you are getting "chown: unknown user/group system:system" read them!
Ok, we do have a WHOLE other thread that was made a sticky already, but you need to read the WHOLE thing to get all the properly interesting parts. I'll make sure I keep this OP up to date.
The following methods enable side loading and installing of apps onto the captivate, without the need of a program on a computer attached via the SDK. There are multiple methods, and for the most part, these methods that have worked flawlessly for many users here on this forum. We're just collecting them all in one post for speed and clarity.
Methods that assist in loading applications, without modification to the settings (a.k.a still need a computer attached) can be found at the collective wiki, http://samsungcaptivate.wikia.com/wiki/How_to_Sideload
ALL METHODS REQUIRE ROOT & BUSYBOX:
Root your phone, see http://forum.xda-developers.com/showthread.php?t=725555
Busybox : http://www.appbrain.com/app/stericson.busybox
Please, save a clean, un-altered backup copy of this file. To be safe. Rarely does corruption occur, but if it does, it won't be good.
Method 1: From Win7x64, Samsung Drivers, Android SDK installed.
This method uses the tools you already have at hand, as part of the SDK. All instances in code blocks are run inside of the command prompt. You will need to know where you installed your SDK, and the tools directory therein.
Once rooted, go install BusyBox installer from the App Market/AppBrain etc and run it. It will download and install the latest version for you.
From my Win7x64, with USB Debugging ON. Ensure that you phone is UNLOCKED as it the SU app will ask for permission for 'UNKOWN' in the following command.
Connect to PC, and Eject/Safely Remove the SD card, and "Turn off USB Storage" on the phone.
open command prompt, follow along:
Code:
> c:
> cd \android\tools
> adb shell
$ su
# cp /dbdata/databases/com.android.providers.settings/settings.db /sdcard/settings.db
# exit
$ exit
mount the SD cards to the pc,
"USB Connected select to... ", Mount
mine mounted as H:
Code:
> copy H:\settings.db settings.db
> sqlite3 settings.db
~> update secure set value="1" where name="install_non_market_apps";
1 row updated
~> .quit
> copy settings.db H:\settings.db
Eject the drive, safely remove, etc.
"Turn off USB storage" etc, to mount it back to the phone
Code:
> adb shell
$ su
# cp /sdcard/settings.db /dbdata/databases/com.android.providers.settings/settings.db
# chmod 660 /dbdata/databases/com.android.providers.settings/settings.db
# chown system.system /dbdata/databases/com.android.providers.settings/settings.db
# exit
$ exit
> adb reboot
Bam. Done.
Method 2: with Root Explorer
(courtesy of kirbo20)
This is a pretty easy process. I went in to Root Explorer - dbdata - databases - com.android.providers.settings, copied settings.db to my sd card, edited it on my pc with a db editor changed 0 to a 1 next to non market apps. Copied it back to the original directory, rebooted and installed a non market app.
(added by gotfolk)
again using FF plug in..
Click Secure on the left pane
click on install_non_market_apps
click edit
number 3 states value click there and type in 1. hit ok
(/gotfolk)
Please use caution. If you want to make sure the db save properly open it on your sd card before you copy and replace the original. It should open up as a readable table. If it opens up in a txt editor its corrupt. This permanently enables non market apps. You can not toggle it on and off.
( This is a sqlite3 database file, you can find many GUI editors that will be able to handle the editing, including a FF plugin. Search "SQLite" )
Method 3: with Root Explorer & Sqlite Editor & Terminal Emulator
(courtesy of ice3186)
- Open Root Explorer
- Browse to /dbdata/databases/com.android.providers.settings/
- copy settings.db to the root of your sd card ( /sdcard/ )
- Click on the newly copied settings.db in /sdcard/, with SQLite Editor installed, you can open and edit it here.
- Select the "secure" table, and update the value of 'install_nonmarket_apps' from 0 to 1, and save.
- close out of SQLite editor
- copy the modified file ( /sdcard/settings.db ), and browse back to /dbdata/databases/com.android.providers.settings/ and paste
- confirm the overwrite if asked and then open again to confirm it's been changed.
- open Terminal Emulator
Code:
$ su
# chmod 660 /dbdata/databases/com.android.providers.settings/settings.db
# chown system.system /dbdata/databases/com.android.providers.settings/settings.db
# reboot
- reboot phone.
No PC, no Mac, no drivers, no SDK. Viola.
Method 4: Mac & Android SDK
You will see "[sdcard]" through this method...I don't own a Mac so I'm guessing a bit.
This method uses the tools you already have at hand, as part of the SDK. All instances in code blocks are run inside of the Terminal. You will need to know where you installed your SDK, and the tools directory therein.
Once rooted, go install BusyBox installer from the App Market/AppDroid etc and run it. It will download and install the latest version for you.
From a Max OS X, with USB Debugging ON. Ensure that you phone is UNLOCKED as it the SU app will ask for permission for 'UNKOWN' in the following command.
Connect to Mac, and Eject/Safely Remove the SD card, and "Turn off USB Storage" on the phone.
open Terminal, follow along:
Code:
> cd /android/tools
> ./adb shell
$ su
# cp /dbdata/databases/com.android.providers.settings/settings.db /sdcard/settings.db
# exit
$ exit
mount the SD cards to the Mac,
"USB Connected select to... ", Mount
mine mounted as [sdcard]
Code:
> cp [sdcard]/settings.db settings.db
> ./sqlite3 settings.db
~> update secure set value="1" where name="install_non_market_apps";
1 row updated
~> .quit
> cp settings.db [sdcard]/settings.db
Eject the drive, safely remove, etc.
"Turn off USB storage" etc, to mount it back to the phone
Code:
> ./adb shell
$ su
# cp /sdcard/settings.db /dbdata/databases/com.android.providers.settings/settings.db
# chmod 660 /dbdata/databases/com.android.providers.settings/settings.db
# chown system.system /dbdata/databases/com.android.providers.settings/settings.db
# exit
$ exit
> ./adb reboot
Method 5: Android SDK only
Of course, this also requires root and BusyBox.
From the android sdk tools folder in a command prompt:
note: all linux/mac should use './adb' in place of just 'adb', and place quotes on the echo statement between echo and |
Code:
adb shell
su
chmod 666 /dbdata/databases/com.android.providers.settings/settings.db
exit
exit
adb pull /dbdata/databases/com.android.providers.settings/settings.db settings.db
echo update secure set value = 1 where name = 'install_non_market_apps';|sqlite3 settings.db
adb push settings.db /dbdata/databases/com.android.providers.settings/settings.db
adb shell
su
chmod 660 /dbdata/databases/com.android.providers.settings/settings.db
chown system.system /dbdata/databases/com.android.providers.settings/settings.db
reboot
NOTICE
You must chown the settings.db file and reboot once it is back in its original location. If you do not, you will not be able to alter settings such as WiFi,GPS, default Ringtones, etc. It's also highly likely that you may wish to chmod to 660 (-rw-rw---), so I've tacked that in here and above.
Code:
> adb shell
$ su
# chmod 660 /dbdata/databases/com.android.providers.settings/settings.db
# chown system.system /dbdata/databases/com.android.providers.settings/settings.db
# exit
$ exit
> adb reboot
Chown Note
In the event that you are getting "chown: unknown user/group system:system" please try 1000.1000 as this has been reported to work on several of the samfirmware-released roms that fail with this message.
Absolutely do not use someone else's settings.db unless you specifially make it a point replace android_id with your android_id!
Special Note
Any of these adb comments can be run from Terminal Emulator (Android Terminal Emulator, free) from the su command. I use the ADB here as it is a lot easier to type into. Terminal Emulator will provide you with a shell that is an exact match of the 'adb shell' command, as they both simply provide the shell to you.
Result:
After completing this process you will be able to load non-market apps directly from the APK files, SDK tools, tools such as DroidExplorer and apps such as APKtor.
You will be able to download the APKs directly, and then install from your favorite file browser (e.g. MyFiles(s), Astro(f), RootExplorer($)...)
Tools
SQLite Administrator (Win, GUI, no FF required) http://sqliteadmin.orbmu2k.de/
SQLite Manager (FF addon, search for it)
Application links
Root Explorer http://www.appbrain.com/app/com.speedsoftware.rootexplorer
SQLite Editor http://www.appbrain.com/app/com.speedsoftware.sqleditor
Terminal Emulator http://www.appbrain.com/app/jackpal.androidterm
BusyBox http://www.appbrain.com/app/stericson.busybox
bump.. settings.db people.. please read the threads!!
good stuff!!!
Ok. I can find settings.db with root explorer. i can copy it and i put it in my sdcard folder but nothing is there when i try to find it on my computer. Im trying to use SQlite editor on firefox. Im also on a powermac g4 if that makes a difference. I did download sqlite editor on my phone and I can find where to change the values for installing non market apps but when I change from a zero to a one it denies me. Please help
Ok, so let me make sure I have your process:
- Rooted
- Installed busybox ?
- Installed Root Explorer
- copied settings.db to /sdcard
-- cant see the file when mounted to Mac, thus can't edit with FF plugin
-- SQLite editor for android wont allow access..
(is this the SQLite Editor you used? http://www.appbrain.com/app/com.speedsoftware.sqleditor)
Try installing "Android Terminal Emulator" from the market (http://www.appbrain.com/app/jackpal.androidterm)
- open Terminal Emulator
$ su
# cd /sdcard
# chmod 777 settings.db
# exit
- Open the sqlite editor, and make the change
- back to Terminal Emulator
$ su
# chmod 660 settings.db
- proceed with rest of instructions.
how many more threads do we need on the same thing? We already have ALL of this info posted, several times.
designgears said:
how many more threads do we need on the same thing? We already have ALL of this info posted, several times.
Click to expand...
Click to collapse
Please read my initial post, first few lines. I explained why, specifically: Consolidation.
Thanks I will give it a try later today.
Sent from my SAMSUNG-SGH-I897 using XDA App
- OP updated to reflect stock ownership settings for 'chown'
Also, which sqlite app are you using? I'll put that up as method 3 if it works out nicely for you.
fixed a typo in the chown command.. bad copy paste.. bad.. doh.
added method 3 courtest of ice3186
added links to Root Explorer ($), SQLite Editor ($) and Android Terminal Emulator (free) and added the chmod/chown commands to method 3, as they were skipped by accident.
bump** for newcomers, sry.
thanks max for adding the third method. this was by far much easier than the first two methods. I have a hard time getting my mac to talk to my phone sometimes and it was good to not have to plug the lil guy in at all. Worked like a charm
myself and ice3186 are glad we could be of help
If I had accidentally deleted the settings.db how should I go about recovering my phone? Now I have the issue that my phone won't boot past the boot animation and I'm notbsure what to do
mkslt4 said:
If I had accidentally deleted the settings.db how should I go about recovering my phone? Now I have the issue that my phone won't boot past the boot animation and I'm notbsure what to do
Click to expand...
Click to collapse
Did you make any kind of backup before hand?
You may have to use someone else's settings.db and then do a factory reset.
Depending on how much you've done with the phone I'd suggest deciding on doing a the reboot process for rooting, but choosing to clear data. This may rebuild it, I am not sure.
my dbdata directory is empty.. My phone is less then 2 hours old and i have some market apps installed..
xetrev said:
my dbdata directory is empty.. My phone is less then 2 hours old and i have some market apps installed..
Click to expand...
Click to collapse
Oh, if it's running, then this folder isn't actually empty.
What are you using to browse this folder?
i followed this guide to a T yesterday when i did this. I used option 1, ADB commands on terminal since i'm a mac and it was super easy, did it in about 5 minutes.
this is just my opinion but i think everyone should try playing with the ADB commands, they're actually really useful and educational to know. and if you should brick your phone, just use clockwork recovery to restore it.
that being said, maybe you should add a disclaimer that when done on a mac, the adb commands require a "./" in front (so adb reboot becomes ./adb reboot). cp, chown, and chmod commands don't need it though (or at least i didn't).

[Q] How to change android ID in some ROMs

Hi Guys,
i want to change my Android ID in /data/data/android.provider.settings/databases/settings.db
Normaly there is only this file in that folder, so i can use "SQlite Database Browser" to change the id.
Now, in some roms there is also a setting.db-wal file in which this id is, but i cant open it with this tool. It seems to be compressed or somethink like this.
If i use "Android ID Changer" the ROM doesnt boot...
So, how i can change the Android ID in these ROMs?
thanks
no input for me?
Hi,
In my Eclair tablet it is in 3 places:
/data/data/com.android.providers.settings/databases/settings.db
table [secure] android_id as a 16 character hex
table [gservices] android_id as a decimal of the hex
/data/data/com.google.android.googleapps/databases/gls.db
table [meta] androidId as a decimal of the hex
I understand that it may be in:
/data/data/com.google.android.gfs/databases/gservices.db
as well but I don't have that database on my tablet.
All the best ...
Nigel.
Make sure and backup your /data/data/com.android.providers.settings/databases/settings.db file
Then in ADB type the following:
su
cd /data/data/com.android.providers.settings/databases
sqlite3 settings.db
sqlite> insert into secure (’name’, ‘value’ ) values (’android_id’,'DEVICE_ID_GOES_HERE’);
sqlite> .exit
Reboot
thanks guys,
thats what i normaly do, i change the value in the database.db, but in some ROMs there are not this information, insteat in database-wal.db, but this db i cant open with the sqlite tool.
e.g. in the actual Cyagenmod ROM there is this database-wal.db file, which i cant change.
paid app tested in that scenario
https://play.google.com/store/apps/details?id=com.vcastroi.changeid
manually
if you copy all 3 files using adb and then open it on your pc using a sqlite utility and then push all 3 file back and fix the files permissions

Automated script for enabling Wifi Hotspot on AT&T Atrix

I can't post this on the original thread because of The Rules about new users being blocked from developer forums(feh), but I wanted to share the script I used to automatically update the telephony database instead of buying the Root Explorer and SQLite Editor apps. Tested on my AT&T Atrix with stock builds 1.8.3 (Android 2.2.2 Froyo) and 4.5.91 (Android 2.3.4 Gingerbread).
Install the Android SDK and the Android Debug Bridge if you haven't already.
Get a copy of the sqlite3 binary for Android (I found one in the SuperOneClick zip file)
Root your phone (one method is here). The important part is to be able to su to root in an ADB shell.
Download the attached shell script, chmod it +x (and change the extension to .sh if you fee like it)
Push the sqlite3 binary and the shell script to a temp dir on the device:
Code:
$ adb push sqlite3 /data/local/tmp
$ adb push telephony.sh /data/local/tmp
Shell into the phone (make sure USB debugging is enabled):
Code:
$ adb shell
su to root:
Code:
$ su root
cd to /data/local/tmp:
Code:
# cd /data/local/tmp
make sure the script is executable:
Code:
# chmod 755 telephony.sh
run it:
Code:
# ./telephony.sh
Select AT&T Tether APN from list (Settings->Wireless & networking->Mobile Networks->Access point names)
Reboot device
Enable WiFi Hotspot
(Optional) Raise your fist in the air as you triumph over bloodsucking corporate greed.
If things get fouled for any reason, the script makes a backup of the files it modifies in the same directory with a "_backup" extension. You can restore the original databases by running the following commands in a root shell on the phone:
Code:
# cp -p /data/data/com.android.providers.telephony/databases/telephony.db_backup /data/data/com.android.providers.telephony/databases/telephony.db
# cp -p /data/data/com.motorola.android.providers.settings/databases/settings.db_backup /data/data/com.motorola.android.providers.settings/databases/settings.db
Make sure to include the -p switch, otherwise the file permissions won't be correct. It doesn't seem to be possible to set file permissions/ownership manually ("chgrp radio" gives an error).
Okay I need help......... I've rooted and I've completely lost the ability to have free wifi tethering.!!! I've been trying to do this procedure all day long and when I try and run the script from a cmd prompt (just like this........ ./telephony.sh) it tell me I do not have permission to do that even though I've already CHMOD'd the file to give SU permission........ GRRRRRRrrrrrrrrrrrrrrrrrrr please help.
Changing the permissions on the script with chmod is just the first step.
Make sure you've shelled into the phone ('adb shell'), and then logged in as root ('su root'). The command prompt should change from a '$' to a '#' when you're logged in as root.
If you're having problems getting the script to work for you, try this method for Wifi/tether enabling, it worked perfect for me on Stock 2.3.4, as well as Ninja Speed Freak
http://forum.xda-developers.com/showthread.php?t=1160452
yes sir
Malibee said:
Changing the permissions on the script with chmod is just the first step.
Make sure you've shelled into the phone ('adb shell'), and then logged in as root ('su root'). The command prompt should change from a '$' to a '#' when you're logged in as root.
Click to expand...
Click to collapse
Iam ssomewhat familiar with linux redhat enterprise. I will try the thread below.
BRILLIANT
Brilliant now that was easy as hell thank very much! I'm posting on the newly enabled Atrix hotspot using my Xoom! THANK YOU AL!
Awesome!
Agreed, worked perfect. Immediately. Now, I'm just having trouble getting my Xoom to connect. Everything else can, except the Xoom.

Installed touchnooter, no "Touch Tools" = impossible to add apps

So I used the touchnooter instructions in the developers forum to root my Simple Touch, everything went smoothly until I went to install programs from the Amazon store and after downloading I received the "For security reasons" message that said my device blocked applications not sourced from the Market. I searched around for how to undo this setting, and it said to open an application called Nook Touch Settings and change the setting to allow outside applications. The problem is that the Settings application is not on my device. Is there something wrong with the ROM or my installation? Is this something that can be fixed without starting all over again?
Thanks.
There are two solutions:
Load Nook Touch Tools from somewhere and use it.
-or-
Get ADB on your desktop and sqlite3 on either your Nook or desktop.
Code:
adb pull /data/data/com.android.providers.settings/databases/settings.db settings.db
sqlite3 settings.db
sqlite> update secure set value=1 where name='install_non_market_apps';
sqlite> .q
adb push settings.db /data/data/com.android.providers.settings/databases/settings.db

Categories

Resources