[Q] Application permissions location help - One (M7) Q&A, Help & Troubleshooting

Guys,
Do you know where i can view the application permission as it is not stored in the database. After, looking i found it is stored in the manifest.xml file after decoding the app, where developer write permission based on the application.
Also, do you know where i can look to find out if any application e.g installed application has more permissions than it should be. Do i have the correct idea compare the permissions using dab against the manifest.xml file.
Any help would be appreciated.
Nickc001

Related

[Q] Questions for experienced cookers.

I'm cooking my own ROM and it is going well. But I'm stuck at setting default settings for applications.
I have tried to decompile the apk's, edit the config and other stuff, compile it again, but the apk doesn't want to install. I've tried to sign them and not sign them, it doesn't seem to fix it.
I have tried apk manager 4.9 both in Windows and Linux, and some other tools too. I have also tried to just replace the config.xml or similar file with WinRAR when editing, the apk still installs, but the settings are not there.
I've also tried to add /data/data/app.name/* folders to the update.zip and have it copy to the internal sd just like /data/app, also did not work.
Can someone please explain to me how I can change the default config of an application? Such as AWDLauncher.
Thank you.
Anyone?

[Q] Where does file created by fopen() resides ?

In Windows Phone 8 Runtime component (C++/CX) we can use fopen or CreateFile2 to create/open a file. For example
Code:
fopen("hello.txt", "w");
You see, I don't explicitly specify any path. And I can't figure out where this hello.txt resides? It can't be in Installed Location, and it isn't in Local Folder. Where is it?
Well, you could try the following:
_fileno() to get the integer file descriptor from the FILE*
_get_osfhandle() to get the Win32 HANDLE from the fd
GetFileInformationByHandleEx() to get the file name from the HANDLE.
I *think* those are even all supported on WP8, though I haven't checked except for the last one.
APIs like GetFullPathName() would make it easy, but may not be supported. CreateFile2 would let you skip the first two APIs in that list, if it works.
I inspected the WP8 .vhd file, and saw that my file was created in the Install folder. It looks like native code does not conform to the rule (Install folder is read-only location)
Whaaaaaat?!? That's... um. Serious. I'll look into it.
onmyway133 said:
I inspected the WP8 .vhd file, and saw that my file was created in the Install folder. It looks like native code does not conform to the rule (Install folder is read-only location)
Click to expand...
Click to collapse
Are you sure it does not create it on the root of the isolated storage space? That's rather unexpected to have the file in a read-only folder...
The install location is read/write to the app.
What
the
hell?
I can send test code if anybody wants, but it's easy enough to check yourself. You don't even need native code to do it, the .NET APIs work well enough.
I am somewhat confused.
mcosmin222 said:
Are you sure it does not create it on the root of the isolated storage space? That's rather unexpected to have the file in a read-only folder...
Click to expand...
Click to collapse
You can create a simple project to test this. In the C++ WP Runtime Component project, just use fopen or CreateFile2
Then use Hyper-V manager and Disk Management to easily inspect the WP .vhd file (I'm using Emulator)
You can use some things like IsoStoreSpy to see that the newly created file does not reside in the Local Folder (in WP8, they rename Isolated Storage to Local Folder)
I wrote a small app to test it; I can share the source if you want. It's really simple. I used the native APIs to create the file and write to it, then used the managed APIs to confirm it was there and read it, then used the native APIs to delete it, and the managed ones to confirm it was gone. Very simple. I then used the managed APIs to create the file myself (await Package.Current.InstalledLocation.CreateFileAsync("hello.txt")) and it worked.
Have you tried to create a xap file in the Install folder and reboot?
My 8X is freezing after creating a xap...
@spikedviper: No, I haven't tried anything like that. I don't seem to have write access from my app to the folder where pre-installed / OEM XAPs reside.
I did try editing the manifest; I was able to edit it with no problems but changing the capabilities didn't *do* anything, so I'm pretty sure it's still only parsed at install time.
hm...so what is the default path if no path specified?
looks like it stores it here: ms-appdata:///Local/ anyway check out "Data for Windows Phone" at msdn

OBB access

Rooted pure. Can't view android/obb folder in any root explorer. I can verify it is there by switch to its directory in terminal emulator. However I can't write to it. "Error permission denied "
Does anyone know how to make it visible and set write permissions?
I am NON ROOTED
I can only add files or overwrite them, by making a obb folder anywhere else, putting the files in it ,then moving this folder inside the Android folder
Sent from my XT1092
Hmm. I can do that. However it say that folder exist so I have to overwrite it. Seeing that I can't view it I'm worried there might be something I need in it.
Holyoblation said:
Rooted pure. Can't view android/obb folder in any root explorer. I can verify it is there by switch to its directory in terminal emulator. However I can't write to it. "Error permission denied "
Does anyone know how to make it visible and set write permissions?
Click to expand...
Click to collapse
Same problem here
I tried changing permissions in terminal but I couldn't make it visible. It wouldn't even let me delete the folder because the device or resource is busy. It would be nice to fix this. Maybe with twrp you could delete the folder and make a new one that would be visible.
Holyoblation said:
Rooted pure. Can't view android/obb folder in any root explorer. I can verify it is there by switch to its directory in terminal emulator. However I can't write to it. "Error permission denied "
Does anyone know how to make it visible and set write permissions?
Click to expand...
Click to collapse
Hi,
I was also facing the same problem and by some hit and trial i was able to see the folder and write to it. This is what i did:-
1) I used ES File Explorer.
2)In it if you search for obb folder using the "search" option you are able to see the obb folder and the files in it.
If you want a step by step guide i have written it in the following page:- http://forum.xda-developers.com/showpost.php?p=57161290&postcount=3
VHNDEV said:
Hi,
I was also facing the same problem and by some hit and trial i was able to see the folder and write to it. This is what i did:-
1) I used ES File Explorer.
2)In it if you search for obb folder using the "search" option you are able to see the obb folder and the files in it.
If you want a step by step guide i have written it in the following page:- http://forum.xda-developers.com/showpost.php?p=57161290&postcount=3
Click to expand...
Click to collapse
I saw that post. Thanks. I can get into the folder and write to it, but I would really like to make it visible. I think its really odd that with root you can view all the other folders, but not to the obb folder. If anyone knows why, that would be helpful.

Deploy example files

Being new to Java, Android OS and Android Studio, I am a bit overwhelmed by all the information and hope I am asking the right questions on the right forum. I am developing an application where the user creates and edits files of a specific format. I want to include example files in my deployment so that the user can play with them right away. Now my questions are:
How do I include those files with Android Studio?
How do I define/create a directory for these files?
What would be standard locations for this directory which allow the user to access the files with a file manager?
frank-floripa said:
Being new to Java, Android OS and Android Studio, I am a bit overwhelmed by all the information and hope I am asking the right questions on the right forum. I am developing an application where the user creates and edits files of a specific format. I want to include example files in my deployment so that the user can play with them right away. Now my questions are:
How do I include those files with Android Studio?
How do I define/create a directory for these files?
What would be standard locations for this directory which allow the user to access the files with a file manager?
Click to expand...
Click to collapse
I've not yet made the transition to Android Studio, but in Eclipse there's a folder called /assets in the project structure. That folder gets built into the root of the APK. You can then access files in the /assets folder with the AssetManager.
Android puts tight controls on your access to devices resources. Each application has a default location for files that it can manage. You can retrieve the default working directory through the app Context. Check out Context.getFilesDir(). The application has the necessary privileges to read and write files to that location.
The crucial thing about internet search is keywords. The one I didn't know is "assets". Together with "android studio" I found a wealth of valuable links. Thanks for the help!

Apk exported from Tasker doesn't show up in the device administrator list

Hi there, i have created a project in Tasker to lock the device as administrator. it works great in Tasker, but when i export the project as apk, the exported apps doesn't show up in device administrator list. so, it no more works standalone.
i decoded the apk with apktool, and checked the manifest.xml. BIND_DEVICE_ADMIN permission presents there.
one more thing, the exported apk shows two package name, first one is which i gave, com.personal.mylockkk . but the second package name is different which i didn't set, net.dinglishch.android.taskerm .
Is this the reason for which it's not working? if so, then how to get ride of second package name. and if that's not the case, then how can I fix it?

Categories

Resources