Hello,
I would like to get a list of database names in code. I'm not looking for databases outside my application/package, just those in my /data/data/<my_package>/database folder.
I can easily locate them on the file system and open them using adb and sqlite3,
but I need to dynamically get a list of databases so that I can open and manage them in code.
I currently use a separate database to keep track of database names as they get created/deleted through my application, but I imagine there is a way to get a list of databases directly via SQL query or some sqlite library call.
Can anyone help me with this?
Thanks,
-dj
This should be in the "Android Development" forum.
BTW, I tried to post this question in a more topical "Android Development" forum, but I'm an XDA newb and don't have permissions to post in there.
Maybe these links can help you? I don't do much droid programming anymore and I never worked with databases in droid. Also welcome to XDA
http://www.devx.com/wireless/Article/40842
http://developer.android.com/reference/android/database/sqlite/package-summary.html
solution
The solution turned out to be very simple.
The main application context has a databaseList() function that, conveniently, returns a list of database names associated with the application.
String[] dbList = getApplicationContext().databaseList();
Thanks for the links dbzfanatic. devx looks like a good resource... it's going on my bookmark bar for sure.
Glad I could help and thanks for posting the solution for others who might have the same question. Since it's a string array I'm guessing the function just returns the DB names and not handles to them?
database names
dbzfanatic said:
Glad I could help and thanks for posting the solution for others who might have the same question. Since it's a string array I'm guessing the function just returns the DB names and not handles to them?
Click to expand...
Click to collapse
Correct, just a list of the database names.
I need a few more posts before I'm permitted to post a link, but this is the approximate reference link:
developer.android.com/reference/android/content/Context.html#databaseList()
While I'm not new to the Android scene, I've just recently begun learning coding and development. I have a small background in Java development but obviously never Android. In any case, my first project was developing some code for a friend that would prevent the .apk from being pulled through ADB and then decompiled and uploaded to warez file hosting sites. I believe I have most of my code correct as the compiled .apk will check against the market, but won't notify the user if it's an illegal install. Any help on this matter would be greatly appreciated. Please reply to this thread, or contact me via GTalk at [email protected]. Thanks!
Hello world,
yes, I used the search function.
Background: (you may wish to skip to the question)
I'm a multitasker and I don't like Android killing my browser if I use one or two other applications for a minute or so, because I lose all my tabs content that way. While that isn't bad having a good network connection, it is real bad in subway train where I usally read news by phone and the internet connection is very bad.
So I tried many different things in order to prevent android from killing my browser, and finally I found a solution in the opera forum:
(I really would like to link you there, but: "To prevent spam on the XDA forums, ALL new users prevented from posting outside links in their messages. After approximately 10 posts, you will be able to post outside links. Thank you for understanding!")
knumsole wrote in Opera forum:
Here, take this: (sorry, can't post link, see above)
This is Opera Mobile 11.5.3, (...). I repackaged it with a dummy service which increases the OOM priority of the application. This will very effectively prevent Android from killing it.
Click to expand...
Click to collapse
(google for the complete sentences in that quote will lead you there.)
Adding this dummy service changed the applications oom priority from about 7 to 10 (--> gets killed soon to first) to an oom priority of 2 (which is totally stable for me).
[ooms read by auto memory manager.]
Question:
Is there a relative easy way to add a dummy service to an existing application? Such as "knumsole" did described before? (I tried contacting him, but wasn't successful)
I'd like to be able to do that myself, e.g. if I need a newer version of the browser. With "easy", I mean: I'm not an application developer, and I don't intend to become one. But I am able to extract an .apk file and modify text files in there and so. And if it is necessary, I would also compile that, too.
I use Android 4.1.2 on a rooted Samsung Galaxy S2.
Thank you!
* (more than) 24h bump *
24h bump
*bump*
Hello XDA,
I'm releasing a modified version of Kik to the public. This is version 7.9 - without video playback support. I created this in January after discovering an exploit within Kik Messenger that allowed me to crash other users. This gave birth to what are known as "lag codes", which are long strings that cause instability within Kik.
If you're on kik and people post strings like:
0la.3p.snai7.eo.490.0la.3p.snai7.eo.490.0la.3p.snai7.eo.490.0la.3p.snai7.eo.490.(etc)(shout out to TL1 for his work in this area)
you will lag, ios and android are affected by this.
I have modified the parser within Kik to stop those short lag codes from causing lag.
I issued these Pikik clients to only a handful of individuals (hardcoded their usernames and disabled editing) , typically being used to crash pedophile chatrooms. Someone in this handful decided to leak the file. They attached AndroRat and distributed it under my credibility and name and I don't appreciate that.
The exploit (along with other exploits I've discovered) and suggested fixes have been emailed to Kik without reply.
This is version 7.9 without video support. You can do the same with 8.0+ as I have done but I don't want to distribute that yet. as I'd like to make a menu via smali to add additional features to Kik. (Confirmed fake camera is possible among other things) Hopefully within that time, Kik will patch the exploits I've emailed them about.
Please be respectful to one another with Pikik, it can cause issues for other users without Pikik if you so choose.
I will create additional links if necessary. Happy Easter.
May 6 update:
Added Kik 8.0apk for video playback. Added another layer of lag protection.
-gunther210
Admin note: APK has been removed due to legal complaint from Kik. Do not re-upload. https://github.com/xda/Notices/blob/master/2015/Kik-20150624.md
Warning, I would not recommend trusting. The app was leaked. Gunther stated that he would release the application to the public in the month of July.
424aca said:
Warning, I would not recommend trusting. The app was leaked. Gunther stated that he would release the application to the public in the month of July.
Click to expand...
Click to collapse
Hey mate, that wasn't the case.
I planned to publish the technical details of the xss exploit within kik.com in July but that also leaked.
I encourage anyone to decompile this apk and look for anything malicious or suspicious if they don't trust it. It isn't my style to do that.
I understand you're just looking out for the community.
Take care mate.
Apologies and Results
Yah sorry to come out as aggressive or as if I was pointing fingers. If you are truly gunther, then you are very much aware of the presence of individuals on kik who post links which intercept IP's and I see a new exploit regarding a phishing link "video" with your name on it etc. I just want individuals to be careful. Because I made seemingly false accusations, I have done the task of running a scan on the app in a virtual machine (genymotion) running a various security scans on it. Only avast gave a security warning, but upon rescan it was gone. I have uploaded four images of four different tests. Please, proceed with caution for this application is as wonderful as you anticipate it to be. To those that have root and xposed, i would advise using I believe xprivacy to block any SMS or call log interaction which this app may present if the proof supplied below does not suffice your paranoia which I seem to be having right now.
-424aca
View attachment 3247779
View attachment 3247780
View attachment 3247781
View attachment 3247782
Thx for the tests.
I'm aware of the games being played on Kik. That's not likely to go away but their lack of willingness to correct the problems leaves everyone vulnerable. At least this protects a regular user from another regular user being annoying. The xss exploit needs to be patched immediately. The amount of people getting phished is amazing. I regret sharing info about that exploit.
As I mentioned long ago to anyone on Kik who asks the status quo kik hacker question "can you get ips thru kik?" My response has always been the image handler. The way kik handles their images has been exploitable forever but I'm not yet certain to what degree. After reporting the 2 "main" exploits to Kik, I moved onto checking out my suspicions and getting some confirmation/vindication.
The entire handler for images is a wreck. It's possible to create corrupt image headers (see my pastebin) which will crash Android upon receiving said picture. It's possible to create corrupt image headers to get IP addresses via images (confirmed on iOS by Host 4/6/2015). It's possible to create corrupt image headers to crash Android for lack of associated action.
It's possible to send videos as Gallery, Gallery as Camera, Camera as "Gunther", custom icons, and most likely offsite pngs (apache log taps). It is possible to build a card that exploits these same flaws but with more parameters. The card:// handler is probably only "more secure" because less people use it.
The fact that I can send you a picture that crashes your kik is absurd and it was obvious to me this style of attack would be possible from the first glance at it.
I like Kik but it is a dangerous hangout lately.
424aca said:
Yah sorry to come out as aggressive or as if I was pointing fingers. If you are truly gunther, then you are very much aware of the presence of individuals on kik who post links which intercept IP's and I see a new exploit regarding a phishing link "video" with your name on it etc. I just want individuals to be careful. Because I made seemingly false accusations, I have done the task of running a scan on the app in a virtual machine (genymotion) running a various security scans on it. Only avast gave a security warning, but upon rescan it was gone. I have uploaded four images of four different tests. Please, proceed with caution for this application is as wonderful as you anticipate it to be. To those that have root and xposed, i would advise using I believe xprivacy to block any SMS or call log interaction which this app may present if the proof supplied below does not suffice your paranoia which I seem to be having right now.
-424aca
View attachment 3247779
View attachment 3247780
View attachment 3247781
View attachment 3247782
Click to expand...
Click to collapse
So is it safe or not?
I don't like its dark background. Fix it
PrinceCoc said:
I don't like its dark background. Fix it
Click to expand...
Click to collapse
I changed mine to white.
I recommended you do not try this app. Probably the maker of this modified version add some malicious things. Or something for stealing personal infos
GreekDragon said:
I recommended you do not try this app. Probably the maker of this modified version add some malicious things. Or something for stealing personal infos
Click to expand...
Click to collapse
Damn I've already been using it
GreekDragon said:
I recommended you do not try this app. Probably the maker of this modified version add some malicious things. Or something for stealing personal infos
Click to expand...
Click to collapse
I didn't. Instead of talking dumb ****, why don't you decompile it and check for yourself. I have no desire to take anyone's info.
ODSTZ3RO said:
Damn I've already been using it
Click to expand...
Click to collapse
You're fine mate.
Me Host and Link have been working together on adding several features for pikik2 and their similar releases.
For now pikik2 will be:
Based on 8.1.x
Probable:
Turn off read receipts (Host)
Turn off typing notification (Host)
AntiLagV2 (Gunther)
Fake-Camera Mod (Gunther)
AntiLagv2 secondary check (Link)
(Theme choices by download if below doesn't work)
Possible:
Turning links on/off
AntiLagv2 override by conditional regex by input
Selectable Theme by input
Selectable Image background (Link/Host)*
*This works now but needs some more tweaking.
If you or someone you know is a smali pro, please PM me.
We are hoping to build these ideas as switches from a panel within kik
Also. If you're interested in building an Xposed Module to do these things, please PM me and I will help point to where the above things are taking place.
All credits will be given
If someone wants to reach us on kik. Check in #pikik
Appreciative said:
I didn't. Instead of talking dumb ****, why don't you decompile it and check for yourself. I have no desire to take anyone's info.
You're fine mate.
Me Host and Link have been working together on adding several features for pikik2 and their similar releases.
For now pikik2 will be:
Based on 8.1.x
Probable:
Turn off read receipts (Host)
Turn off typing notification (Host)
AntiLagV2 (Gunther)
Fake-Camera Mod (Gunther)
AntiLagv2 secondary check (Link)
(Theme choices by download if below doesn't work)
Possible:
Turning links on/off
AntiLagv2 override by conditional regex by input
Selectable Theme by input
Selectable Image background (Link)
If you or someone you know is a smali pro, please PM me.
We are hoping to build these ideas as switches from a panel within kik
Also. If you're interested in building an Xposed Module to do these things, please PM me and I will help point to where the above things are taking place.
All credits will be given
If someone wants to reach us on kik. Check in #pikik
Click to expand...
Click to collapse
OK I wasn't going to delete it I just changed its appearance a bit.
NOT working?
I have tried to download the File but i keep getting an error saying I don't have the app installed when I do? Maybe it's because a recent update that I did yesterday April 14, 2016. Any help?
Delete the kik you already have
INTRUTHS said:
I have tried to download the File but i keep getting an error saying I don't have the app installed when I do? Maybe it's because a recent update that I did yesterday April 14, 2016. Any help?
Click to expand...
Click to collapse
Yeah man your in the future, please tell us what its like in 2016
I reeeaally enjoy this app. Buuuut I like the new material design update (8.2.0) more. Pls update.
gallowsArisen said:
I reeeaally enjoy this app. Buuuut I like the new material design update (8.2.0) more. Pls update.
Click to expand...
Click to collapse
Didn't you read the post, their working on it, if you know someone that's good with smali tell them to contact us at #pikik
theattackingdildo said:
Didn't you read the post, their working on it, if you know someone that's good with smali teller them to contact us at #pikik
Click to expand...
Click to collapse
Sorry. I'll look out for anyone with experience. I'm in a few good groups so I'll ask around.
gallowsArisen said:
Sorry. I'll look out for anyone with experience. I'm in a few good groups so I'll ask around.
Click to expand...
Click to collapse
I'll ask some people about it.
First, let me/us say thanks for all the support. It helps keep us motivated to get pikik2 how we want it.
Updates:
We have pretty much narrowed down all the future feature locations.
We are still stuck in the same spot however.
We need a little advice or guidance on how to use toggles and inputs.
We can build the toggles, we can associate them in the places they need to be. But, we aren't sure how to do the following:
We need a generic or simple way to write and read toggle values into the database or preferences. We need to be able to pull these into smali. We are getting progress on Smali knowledge and may be able to import the values ourselves but we need to have a better understanding of how to implement this.
We want to create a check box, no problem. How do we add the value of check box (or inputs) into the db or prefs in the simplest way?
Next, how do we then read the value out of these?
We are reading to use <checkboxprefs but that's not working easy for us so far. We have tried literally hundreds of tests at this point.
My last test was duplicating the widget check box and associating it.
We need help. Someone. Give us a run down of the fastest way to what we need, please. As always, credits will be given.
Thanks mates,
gunther210
I will make a thread asking for more direct help when I have enough posts to do so. Anyone out there who has any advice, we will investigate.
Thanks again.
Hi Everyone !!!
I am creating this as a purely educational guide to accomplish what everyone told me was not possible.
<DISCLAIMER>
This is for educational purposes ONLY,
Neither Myself , Xda, Nor Team_Astr4y4L
Nor ANY FILE HOSTS
are responsible for your actions PERIOD, in some places it's illegal to stream digitally copyrighted materials . WE do not condone Stealing in any FORM!!!
<OK NOW THAT THAT'S OVER:>
So Just the other day my old laptop/linux-box/media-center Had a total meltdown. The Dual Core Died :crying:
Which Sucks , but hey it happens. So left with 3 board kids 2 board adults and a stinky-dog, and no good source of entertainment (Cut-Cable long ago) and only football on the t.v and the other-guys team too...
I said to Myself, "Well could be worse right ? I'll just swap the HDD over and run it on another box."
Well that would have been easy , except I was now at a shortage of 64bit P.C's
and the box I could use was 32 bits....
See 32 bit systems will boot fine on a board with 64bit processors, but 32bit processors make all kinds of weird beeps and noises and Refuse out-right to boot a 64bit system...
OK no problem, I'll install 32bit Ubuntu 16 on the box install Kodi on that AND THEN download my favorite plug-in again and install that. Back in business...
NOPE!!!
So it turns out for what-ever reason the devs of exodus abandoned it and moved on to a new plug-in called " Delorean " thats supposed to be all kinds of better too. OK KOOL!
NOPE.
followed all the on-line guides never could get it to let me just watch a movie.
or even install correctly.
So I ask around and i'm told that since the repo is gone now and everyone's switched over I'll never see the beloved Exodus again ... HOW SAD.
and some-one somewhere mentioned that if I still had the zip file from downloading the plugin I could install using Kodi's install from zip file option.
Well that got me thinking. I had always installed from the repo directly... so didn't have the zip file... So I'll ask around for the file.
NOPE !
No Body Had the Zip file.... I was very sad about it for like a second and then i realized , it's a zip file ...
this means all the parts of the plug-in just zipped in a zip file...
SO I set off to work getting the files,
I connected my old HDD to the computer here in the LAB and mounted it...
I dug through it until I found the Location of my add-ons and the files that make them up.
I zipped up the folders using 7zip but made sure not to encrypt them and that the file extension was ( .zip )
since I didn't have a handy thumb-drive on me , And the files were small in nature.
I just uploaded it to my file host....
Then I went back to the living room and Fired up the New media box.
opened the browser typed in
MOD Edit :- Links Removed
and hit enter, There they were my zipped up files....
so I downloaded everything in that folder (took a time or two to make sure I got all needed plug-ins to make it work) and moved it all to a folder on my desktop that I named Kodi-Stuff.
I then opened up the Kodi app and made sure unknown Sources were enabled in settings
went to file manager and choose add source
then i used the [ Browse] button to open the window to navigate to the folder on my desktop named Kodi-Stuff added the folder as a source exited back to Kodi's home screen and chose add-on's and install and install from zip
there they were my zipped files... well I started at the bottom of the list and started installing them one by one ... [ gotta start from bottom of list and work up for it too work]
To My Delighted Surprise They installed , every one of them worked...
HAHA, so now I have my favorite plug-in back.
but had to think that the best thing to do next is
DISABLE AUTO-UPDATES for these plugins...
because the repo's do not exist anymore BUT some malicious Butt-Hole out there may OWN the URL that the plug-in uses to update,
-------BIG SECURITY RISK--------
SO to mitigate that danger I go to all plug-in's in Kodi's menu and choose the plug-in {Exodus and Exodus Repo} for example and look down for the update setting toggle and just turn it OFF !!!
So now fairly confident that no one except Big-Brother was watching me.
I set-up my proxies again on the new machine and
in about an hour of Krap later My Family an I were watching our favorite Movies and Shows again and Had a nice not-bored week-end !!!
This Method works to retrieve other plug-ins too...
Once again this was for educational purposes ONLY
My team and I have chosen to leave the files in the folder I used at my file host up because it's proven useful for loading the
plugins to everything from windows -Kodi to Android-Kodi and Linux-Kodi I'm sharing this here so that You can learn how to do this with your favorite plug-in's too!!
I truly hope this saves some-one else from dieing from Kodi-withdrawal or Just Plain Boredom .
This thread will be open to anyone with questions or comments about zipping files and installing them to Kodi.
I Ask if you Download My Files linked in this thread more than once or if You feel this Saved your life.
MOD Edit :- Links Removed
We're H4Ck3Rz on a budget around our parts! LOL
THANKS,
Astr4y4L
Team_Astr4y4L
Thread closed.
9. Don't get us into trouble.
Don't post copyrighted materials or do other things which will obviously lead to legal trouble. If you wouldn't do it on your own homepage, you probably shouldn't do it here either. This does not mean that we agree with everything that the software piracy lobby try to impose on us. It simply means that you cannot break any laws here, since we'll end up dealing with the legal hassle caused by you. Please use common sense: respect the forum, its users and those that write great code.
Click to expand...
Click to collapse
6. Do not post or request warez.
If a piece of software requires you to pay to use it, then pay for it. We do not accept warez nor do we permit members to request, post, promote or describe ways in which warez, cracks, serial codes or other means of avoiding payment, can be obtained or used. This is a site of developers, i.e. the sort of people who create such software. When you cheat a software developer, you cheat us as a community
Click to expand...
Click to collapse
Thanks
XDA Staff.