The intent does contain the sender of the intent. If you use
intent.getStringExtra("from") you will get the senders jid. If you
only want to process intent from a select group of people you will
need to add a check before processing it.

On Mar 31, 4:35 pm, Peli <[EMAIL PROTECTED]> wrote:
> I have the following conceptual question:
>
> If I look at the GTalkDataMessageReceiver example 
> (http://code.google.com/android/samples/ApiDemos/src/com/google/androi...
> ) the receiver receives an intent that the sender sent. Except for the
> name "GTalk", there is nothing in that class that uses any GTalk
> related API. The intent could therefore either come from a local
> sender or from a remote sender.
>
> Of course, the sender has to be part of the buddy list of the receiver
> for this to work, but if this is the case, it seems the IntentReceiver
> will not obtain any information about who sent this intent (unless the
> sender is kind enough to put this information into the bundle).
>
> I have the following concerns:
> * Once I have rights to send intents to a phone, I could send
> arbitrary intents and trigger arbitrary events on anther person's
> phone.
> * The intent receivers do not know who sent the intent. If this
> information is passed in the bundle, a sender could pretend to be a
> different sender.
>
> There should probably be additional permission settings on the
> receiver's side which determine which intents can be received from
> which sender. So far, I don't see any permission that can handle this.
>
> Or am I missing something here?
>
> Peli
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to