IBM-MIL / Xtify-Android-Auto-Example

This is a basic Android Project that shows how to integrate Xtify with Android Auto
Apache License 2.0
2 stars 0 forks source link

android:permission attribute inside <intent-filter> tag in AndroidManifest.xml file #1

Open HiFromAjay opened 8 years ago

HiFromAjay commented 8 years ago

Android does not support android:permission attribute inside <intent-filter> tag so use of <intent-filter android:permission="com.google.android.c2dm.permission.SEND"> inside AndroidManifest.xml won't protect com.xtify.sdk.c2dm.C2DMBroadcastReceiver receiver component. I have two questions. 1. whats the use of android:permission inside <intent-filter> if it does not do anything and 2. shouldn't the android:permission attribute is declared inside <receiver> tag.

ecompton3 commented 8 years ago

This setup came from the Xtify documentation. I'm not sure why they have it setup this way but it is how they get their service to work. You can see the setup here: Xtify Docs and look at step 3c. You could try raising an issue with them to see why they have it setup in this manner

HiFromAjay commented 8 years ago

yes it will work without any problem because the app is declaring <uses-permission> required to receive the protected broadcast intent from the system. The only issue is security. If I am not missing something specific to Xtify push implementation, the receiver component is not protected at all and any malicious app can access that component without any difficulty. Thanks for your response and suggestion. I couldn't find issue tracker page in Xtify.