Automatic OTP verification in iOS?

In iOS 12 Apple has introduced feature called Security Code AutoFill. To use this in your app all you need to do is set UITextField‘s input view’s textContentType property oneTimeCode. otpTextField.textContentType = .oneTimeCode NOTE: Security Code AutoFill will only works with System Keyboard it will not work with custom keyboard. WWDC video When you get … Read more

Send programmatically SMS on jailbreak device

Found out why – (BOOL)sendSMSWithText:(id)arg1 serviceCenter:(id)arg2 toAddress:(id)arg3; is not working since iOS 6. This API is protected by the entitlement com.apple.CommCenter.Messages-send. Just sign your app with this entitlement set to true. It’s much better than my another answer here (XPC method) because of the two main reasons: sendSMSWithText tells you whethere message was sent successfully … Read more

Android 1.5: Reading SMS messages

There is a content provider for accessing SMS messages, but it’s not documented in the public SDK. If you use ContentResolver.query() with a Uri of content://sms you should be able to access these messages. You can find more information on this Google Groups thread or previous questions on stackoverflow.

Get AT command response

If you have not yet read all of chapter 5 in V.250 specification stop reading here and do so immediately, it is an important basis for the rest of this answer, I’ll wait until you’ll come back. Some of the references to alphabets (short version: ignore this/treat it as ASCII) and S-registers might seem cryptic … Read more

Read all SMS from a particular sender

try this way: StringBuilder smsBuilder = new StringBuilder(); final String SMS_URI_INBOX = “content://sms/inbox”; final String SMS_URI_ALL = “content://sms/”; try { Uri uri = Uri.parse(SMS_URI_INBOX); String[] projection = new String[] { “_id”, “address”, “person”, “body”, “date”, “type” }; Cursor cur = getContentResolver().query(uri, projection, “address=”123456789″”, null, “date desc”); if (cur.moveToFirst()) { int index_Address = cur.getColumnIndex(“address”); int index_Person … Read more

Android take screenshot via code

Around the web I found some snippets of code that I was able to get working together. Here is a solution that works well: Setting up your Root layout: View content = findViewById(R.id.layoutroot); content.setDrawingCacheEnabled(true); Function to get the rendered view: private void getScreen() { View content = findViewById(R.id.layoutroot); Bitmap bitmap = content.getDrawingCache(); File file = … Read more

SMS URL on Android

I found the following which may help you: https://www.rfc-editor.org/rfc/rfc5724 You can check sub-section 2.5 or 2.6 of this RFC to give you some additional pointers on formulating a proper SMS URL. Eg. using formal URI-spec as detailed in sub-section 2.2 of rfc5724: <a href=”sms:+19725551212?body=hello%20there”>SMS Me</a> Notice the ‘escaped’ character for the ‘space’ in the example … Read more