Possible to watch all Intents/Broadcasts on the phone - android

Is there an app or another possibility to watch for ALL Intents and Broadcast flowing in an android system?
Maybe another app which uses a special intent (not the standart ones) you want to use or broadcast yourself.

You can't listen to every Intent.
If you are worried that someone else uses your intent use your package name as prefix.
For example if you are willing to have an intent with the action SERVER_UPDATE, use: com.nitromouse.appname.SERVER_UPDATE

why not? Just list all permitted intents in the intent filters section. If you find that intimidating, write a program to write the xml menifest (or may be pay someone for typing)?
Oh.. dont forget to add all required permissions also...

Related

How to configure the android intent actions in android manifest

I have a webview in my app, on trying to do actions like making a call (Tapping call button from results displayed in webview), sending mails and other actions, my webview doesn't perform those actions
I Found a solution to add the intent actions in my web view activity as
Intent intent = new Intent(Intent.ACTION_DIAL, Uri.parse(url));
startActivity(intent)
Instead of doing so is there any way to add in the android manifest file
or Is there any way to turn on all of the intent actions for the webview so that
there wont be further issues in handling the actions
Can someone help me on this pls
Your answer seems to me a bit strange, I think you are a bit confuse about the difference between Intent and manifest permission. The first one are the system used by android to let app communicate with each other, the second one allow you to use some feature of the device like wifi and direct phone call that need the explicit agreement of the user to be used (the prompt that popup when you make the first install of an app).
With this clarification it is clear that if you want to do something that require another app you will have to make an Intent. This Intent, if well formed, will be elaborated by the os that will take care of sending it to the correct application able to accomplish the Intentrequirement.
So the answer to your question, as far as i know, is no, you have to use intent if you have the need of calling external app. It's also a good practice to set in the manifest only the permission really needed by the app, this way the user know what the app really can do and and what it can't do.
Hope i understand your question and answer it.

android - is it possible to use private intents instead of global ones?

background:
i've noticed that for regular activities within, it is possible for any application to open the activities of my app .
question:
is it possible to allow only my own app (or apps , or package) to send and receive intents inside the same scope , so that other application won't be able to receive them or interfere with the flow of the app?
example:
suppose i have a broadcastReceiver that listens to some kind of intent , but this intent is only meant to be used by another service/activity that resides either inside my app , or inside another app that i've created , but i don't want others to be able to use this intent.
please help me.
setPackage()
Set an explicit application package name that limits the components this Intent will resolve to. If left to the default value of null, all components in all applications will considered. If non-null, the Intent can only match the components in the given application package.
or you can use setSelector() , but not both.
suppose i have a broadcastReceiver that listens to some kind of intent , but this intent is only meant to be used by another service/activity that resides either inside my app , or inside another app that i've created , but i don't want others to be able to use this intent.
In addition to Reno's fine answer, for your specific requirement quoted above, use LocalBroadcastManager. Not only do you get the security you seek, but it is more efficient. LocalBroadcastManager is available in the Android Support package and AFAIK should work going back to Android 1.6. Here is a sample project using LocalBroadcastManager.

Android: Proper way to reuse my app's activities?

What's the proper way for other people to reuse my Activities? Should they hard code the intent actions in their app or is it customary to provide them with a jar file enumerating my app's intent actions? Is there a less tightly-coupled way to lookup the intent actions?
First of all, take a look at openintents.org and see if there's any match to what your activity does.
Secondly, documentation is always a good idea.
Having the intent details hardcoded in their applications should work just fine. After all, the intents are part of your public interface and shouldn't change.
Your applications manifest should announce what sorts of things your activity can handle, via intent-filters. Outside users can read the manifest to determine what actions you support, and invoke them via action intents.
See intents and intent filters for more details.

Listing an application's activity and intent-filters?

I am interested in activating another application's activity. I know from reading the Android SDK that it's probably better to do this with an implicit intent. However, this activity doesn't reside in an application I own, so I don't know the action and category and data flags on the intent-filter.
How can I examine an Android applications metadata like the activity classes and the intent-filters for those activities (if declared in the manifest)?
Thanks!
I would try this.
Check on openintents
Contact the developer.
Use android-apktool too see the app's manifest.
It might be illegal to use android-apktool. Use it under your own risk.
There is one more solution: you could run this app and look into logcat. All intents are logged, so you could see what is called up. You won't see extra data though.

Android Override Explicit Intent

My app needs to have a intent-filter that responds to a Intent that has it's component set (a explicit intent.) Here is a example.
Intent i = new Intent();
i.setClassName("com.compareeverywhere","com.compareeverywhere.ScanActivity");
startActivity(i);
Just a simple intent-filter will not do - because the Intent is made for a specific component (Activity,) it just launches that without looking for intents at all. Is there a way to do this?
Thanks, Isaac Waller
P.S: Please don't reply "No."
No.
:) That being said, imagine what would happen if Android allowed people to hijack Intents for specific components. Don't like a competitor's app? Just have yours hijack his main Activity with your own to display porn. Intents can specify specific components specifically because the authors don't want others to be able to replace them.
You have two options. If this is your own code, replace it with a generic intent, or if it belongs to someone else, contact them, and ask nicely for them to change it to a generic intent along with some good reasons why that is necessary.

Categories

Resources